Arduino 2560 fuse recovery

Hello,

I have accidentally changed the fuse bit SUT_CKSEL of an Arduino mega 2560 from 'Ext. Crystal Osc. 8.0- MHz; Start-up time: 16K CK + 65ms' to 'Ext. Clock; Start-up time: 6 CK + 65ms'. The board has become unresponsive now. (I was programming through AVR ISP programmer, AVR Studio)

I have tried a lot browsing to find the fuse recovery of an arduino board but no solution. Can anyone please help me in recovering the SUT_CKSEL fuse bits ?

Thank you.

Can't you just change the fuses back in AVR Studio?

mega2560.bootloader.low_fuses=0xFF mega2560.bootloader.high_fuses=0xD8 mega2560.bootloader.extended_fuses=0xFD

No. I am not able to change the fuses in AVR studio now. The AVRISPmkII programmer needs a clock signal to operate. But, the clock of the micro controller is wrongly fused as external clock generator instead of external crystal oscillator.

I came across this site, http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=106325 . But, I don't know if the recovery procedure is for an integrated and assembled atmega2560 micro controller as an arduino mega2560 board.

Please suggest what can be done now to recover the fuses ?

Thanks.

If you have an UNO (or 328 chip) around, you may try Nick Gammon's ICSP: http://www.gammon.com.au/forum/?id=11637 See "Alternate clock source"

Ray

Thank you for the suggestion. But, there is one problem with the Nick Gammon's procedure to change the clock source fuse. And that is, it is explaining about the changing the fuses of a "micro controller chip" which is not assembled into a board. But, Arduino mega 2560 has already Atmega2560 16AU assembled on the board. How to recover fuses in this case ?

mahamooda: Thank you for the suggestion. But, there is one problem with the Nick Gammon's procedure to change the clock source fuse. And that is, it is explaining about the changing the fuses of a "micro controller chip" which is not assembled into a board. But, Arduino mega 2560 has already Atmega2560 16AU assembled on the board. How to recover fuses in this case ?

There are two (2) ICSP headers on the Mega2560 board. http://forum.arduino.cc/index.php?topic=125908.msg946731#msg946731

Yes, there are two ICSP interfaces[ICSP and ICSP1]. But, the ICSP1 interface is connected to the Atmega16 U2-MU. I think this unit handles the USB interface as is evident from the schematic http://arduino.cc/en/uploads/Main/arduino-mega2560_R3-schematic.pdf. Usin the ICSP1 interface, we cannot modify the fuses of Atmega2560 16AU. Please correct me if I am wrong ?

just use the icsp near the reset button to reprogram the 2560

I have changed the fuse to "Ext. Clock; Start-up time: 6 CK + 65ms" by using the ICSP interface near the reset button. Now, I am not able to restore the fuse to "Ext. Crystal Osc. 8.0- MHz; Start-up time: 16K CK + 65ms" as the board has become unresponsive. (I was using AVRISPmkII programmer to access the mega2560 board through ICSP interface). Any suggestions please ?

mahamooda: I have changed the fuse to "Ext. Clock; Start-up time: 6 CK + 65ms" by using the ICSP interface near the reset button. Now, I am not able to restore the fuse to "Ext. Crystal Osc. 8.0- MHz; Start-up time: 16K CK + 65ms" as the board has become unresponsive. (I was using AVRISPmkII programmer to access the mega2560 board through ICSP interface). Any suggestions please ?

The Mega2560 board has the external crystal/resonator... Therefore this cannot be the issue with the main uC... Either internal OR external clock should work. The ACRISPmkII is a fine programmer, so either you got the fuses really tangled to the point of requiring an HV programmer or something else is weird. Perhaps one of the guru members will stop by and offer an idea.

Ray

An external crystal/resonator is NOT the same as an external clock (read the data sheet).

If you have set the fuses for an external clock you will need to supply an external clock signal at XTAL1 (pin 34 on the chip). The site you linked to has the information you need.

mahamooda: Hello,

I have accidentally changed the fuse bit SUT_CKSEL of an Arduino mega 2560 from 'Ext. Crystal Osc. 8.0- MHz; Start-up time: 16K CK + 65ms' to 'Ext. Clock; Start-up time: 6 CK + 65ms'. The board has become unresponsive now. (I was programming through AVR ISP programmer, AVR Studio)

I have tried a lot browsing to find the fuse recovery of an arduino board but no solution. Can anyone please help me in recovering the SUT_CKSEL fuse bits ?

Thank you.

I had the same problem quite some time ago. What I did was to temporarily connect a thin wire (a piece of wire-wrap wire) to the 16U2 chip (pin 2) and to the XTAL1 pin of the 2560 (pin 34)

To get at these, the easiest points are:

(1) The 1M resistor (R2) across the crystal for the 16U2 chip, closest to the 2560 chip -- and-- (2) The 1M (R1) resistor across the resonator for the 2560 chip, the side closest to the headers

Carefully tack solder the wire and don't touch it while re-flashing the bootloader (because your finger will load the crystal and may stop it).

What this does is send the XTAL2 (output) from the 16U2 chip to the XTAL1 (input) of the 2560 which will allow re-flashing.

Then, remove the wire and you should be good to go.

Hope this helps.

gripe [/gripe]

mrburnette:
The Mega2560 board has the external crystal/resonator… Therefore this cannot be the issue with the main uC… Either internal OR external clock should work. The ACRISPmkII is a fine programmer, so either you got the fuses really tangled to the point of requiring an HV programmer or something else is weird. Perhaps one of the guru members will stop by and offer an idea.

Ray

It is indeed possible to accidentally set the 2560 fuses to “external clock” which will render the board useless unless an external clock can be provided in order to “run” the chip so that it can be re-flashed correctly.

I’ve already made that mistake and luckily I was able to save the board by “borrowing” the oscillator from the 16U2 (USB interface) chip.

For removable micros like the 328P, these chips can be rescued either by using the “high voltage programming” method along with the appropriate wiring or shield (such as this: http://mightyohm.com/blog/products/hv-rescue-shield-2-x) which, by the way, works very nicely, or else use the Adafruit programmer kit (http://www.adafruit.com/products/462) which very cleverly uses the host Arduino board to generate an 8mhz clock for the micro, allowing it to be programmed even if the clock source is set to “external”.

gripe [/gripe]

It seems to me the very first version of the Uno (and maybe mega2560) had crystal resonators and the story was they couldn't pass FCC standards for emissions tests without changing to the ceramic resonator. Not sure that was fact or conjecture, but I'm pretty sure that story was put out there by someone.

retrolefty:

gripe [/gripe]

It seems to me the very first version of the Uno (and maybe mega2560) had crystal resonators and the story was they couldn't pass FCC standards for emissions tests without changing to the ceramic resonator. Not sure that was fact or conjecture, but I'm pretty sure that story was put out there by someone.

I've heard that story too... and I find it difficult to believe. Maybe the relatively long run required to bring the clock signal across from one chip to the other (i.e. using one crystal for both) could be an RFI problem, but using a separate crystal for each chip shouldn't be.

I think the real reason was to save costs. The 16U2 needs a stable and accurate clock given that it's the USB interface, but the microcontroller doesn't normally need an accurate clock (unless one needs to do accurate timing) so it gets the resonator.

I've actually had to replace the resonator with a crystal on a 2560R3 board for a few projects that required accurate timing.

I would gladly pay an extra dollar for a board to get a crystal instead of a resonator (or at least give me two through-holes to install my own).

Hello Krupski,

I have tried to connect pin 2 of 16U2 to the pin 34 of 2560 chip by soldering the wire to the two 1M resistors mentioned by you. But, still I am not able to change the fuses =(. I have attached the image to show the connections that I have made. Can you please suggest, if I am doing anything wrong ?

From the data sheet.

This Crystal Oscillator is a low power oscillator, with reduced voltage swing on the XTAL2 out- put. It gives the lowest power consumption, but is not capable of driving other clock inputs, and may be more susceptible to noise in noisy environments.

Try pin one?

No success even after connecting to the pin 1 of Mega 16U2 chip. Any other solution friends ?

Do you have another Arduino? You could program one of it's timers to give a useable clock for the Mega.