Replace ATMEGA328P-AU chips

I bought a usbASP programmer from eBay and every Nano I tried to burn a new bootloader, the Nano died. I have a small pile of them now. No more heartbeat when powered on.

Attempts to burn others with Arduino as ISP always failed but i suppose thats another topic.

I bought new 328's to fix them, assuming the usbASP had blown them, replaced the chips but still no heartbeat.

I was under the impression that the ATMEGA chips produce a short heartbeat on startup regardless of whether a bootloader is installed.

Is this correct?

Since I dont have a working method of burning bootloaders yet i cannot test the 'repaired' Nano

Also, do you think the programmer actually blew the chips or just corrupted them?

Thanks

I bought a usbASP programmer from eBay and every Nano I tried to burn a new bootloader, the Nano died. I have a small pile of them now. No more heartbeat when powered on.

I bought new 328's to fix them, assuming the usbASP had blown them, replaced the chips but still no heartbeat.

I was under the impression that the ATMEGA chips produce a short heartbeat on startup regardless of whether a bootloader is installed.

Is this correct?

You are replacing 328P chips on Nano's ?

Arduino or clone?

What happens when you power up the Nano and then push the reset button momentarily?
Some clones do not flash the led when initially powered up.

What message do you get when burning the bootloader?

Yeah ive replaced just the chips.

1 is genuine Arduino, 3 are clones - all killed by the programmer

None of them flash with the reset button no matter what i try.

I cant recall the programmers exact error but I think it was just a generic, abstract error with no detail (I had verbose output enabled in the IDE too)

I only remember the device signature error from the Arduino as ISP unfortunately and i only have genuine Arduinos left that Id rather not sacrifice the reproduce the error

I was under the impression that the ATMEGA chips produce a short heartbeat on startup regardless of whether a bootloader is installed.

Is this correct?

No, that's not correct. The heartbeat is from the bootloader code. An ATmega normally boots up with all the pins set as inputs.
I've never heard of a USBASP blowing up chips. Probably you managed to get an incorrect bootloader or fuses in them, somehow.

Ah, so they might have been salvageable without messing with the heat gun!
I dont know what could have gone wrong in the flashing process though. I simply just plugged them in burned via IDE.

Didnt go near fuse values or the like. I always triple checked the device type in the IDE too

A couple of things to maybe help.
If you have new chips without bootloaders, you will probably have to short Jp3 on your usbasp in order to slow it down enough to program with a 1MHz clock.
Another thing is to connect the usbasp correctly. If you are using a 10pin to 6pin converter there are only two ways to connect it and the right way you get a bright power led. :slight_smile:

It would help to see the error message placed in </>.

Programmer Type : usbasp
         Description     : USBasp, http://www.fischl.de/usbasp/

avrdude: auto set sck period (because given equals null)
avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: erasing chip
avrdude: auto set sck period (because given equals null)
avrdude: reading input file "0x3F"
avrdude: writing lock (1 bytes):

/home/kprims/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14/bin/avrdude -C/home/kprims/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14/etc/avrdude.conf -v -patmega328p -cusbasp -Pusb -Uflash:w:/home/kprims/.arduino15/packages/arduino/hardware/avr/1.6.207/bootloaders/optiboot/optiboot_atmega328.hex:i -Ulock:w:0x0F:m 

avrdude: Version 6.3-20171130
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "/home/kprims/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino14/etc/avrdude.conf"
         User configuration file is "/home/kprims/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : usb
         Using Programmer              : usbasp
         AVR Part                      : ATmega328P
         Chip Erase delay              : 9000 us
         PAGEL                         : PD7
         BS2                           : PC2
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : usbasp
         Description     : USBasp, http://www.fischl.de/usbasp/

avrdude: auto set sck period (because given equals null)
Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of lock written
avrdude: verifying lock memory against 0x3F:
avrdude: load data lock data from input file 0x3F:
avrdude: input file 0x3F contains 1 bytes
avrdude: reading on-chip lock data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of lock verified
avrdude: reading input file "0xFD"
avrdude: writing efuse (1 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of efuse written
avrdude: verifying efuse memory against 0xFD:
avrdude: load data efuse data from input file 0xFD:
avrdude: input file 0xFD contains 1 bytes
avrdude: reading on-chip efuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of efuse verified
avrdude: reading input file "0xDA"
avrdude: writing hfuse (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of hfuse written
avrdude: verifying hfuse memory against 0xDA:
avrdude: load data hfuse data from input file 0xDA:
avrdude: input file 0xDA contains 1 bytes
avrdude: reading on-chip hfuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of hfuse verified
avrdude: reading input file "0xFF"
avrdude: writing lfuse (1 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 1 bytes of lfuse written
avrdude: verifying lfuse memory against 0xFF:
avrdude: load data lfuse data from input file 0xFF:
avrdude: input file 0xFF contains 1 bytes
avrdude: reading on-chip lfuse data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of lfuse verified

avrdude done.  Thank you.

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: auto set sck period (because given equals null)
avrdude: reading input file "/home/kprims/.arduino15/packages/arduino/hardware/avr/1.6.207/bootloaders/optiboot/optiboot_atmega328.hex"
avrdude: writing flash (32768 bytes):

Writing | ################################################## | 100% 0.00s

avrdude: 32768 bytes of flash written
avrdude: verifying flash memory against /home/kprims/.arduino15/packages/arduino/hardware/avr/1.6.207/bootloaders/optiboot/optiboot_atmega328.hex:
avrdude: load data flash data from input file /home/kprims/.arduino15/packages/arduino/hardware/avr/1.6.207/bootloaders/optiboot/optiboot_atmega328.hex:
avrdude: input file /home/kprims/.arduino15/packages/arduino/hardware/avr/1.6.207/bootloaders/optiboot/optiboot_atmega328.hex contains 32768 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 32768 bytes of flash verified
avrdude: reading input file "0x0F"
avrdude: writing lock (1 bytes):

Writing | ################################################## | 100% 0.01s

avrdude: 1 bytes of lock written
avrdude: verifying lock memory against 0x0F:
avrdude: load data lock data from input file 0x0F:
avrdude: input file 0x0F contains 1 bytes
avrdude: reading on-chip lock data:

Reading | ################################################## | 100% 0.00s

avrdude: verifying ...
avrdude: 1 bytes of lock verified

avrdude done.  Thank you.

Found the usbasp problem... It was the firmware. PITA to update it but its burning good Arduino bootloaders now!

It doesnt bring back the dead ones though. (Also wont burn a fresh bootloader on the ones I replaced the chip, even with the J2 jumper shorted)

Here is the log from a clone it killed

avrdude: Version 6.3, compiled on Jan 17 2017 at 12:00:53
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\Users\steph\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino9/etc/avrdude.conf"

         Using Port                    : usb
         Using Programmer              : usbasp
         AVR Part                      : ATmega328P
         Chip Erase delay              : 9000 us
         PAGEL                         : PD7
         BS2                           : PC2
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : usbasp
         Description     : USBasp, http://www.fischl.de/usbasp/

avrdude: auto set sck period (because given equals null)
avrdude: error: program enable: target doesn't answer. 1 
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.


avrdude done.  Thank you.

Error while burning bootloader.

JP3(Slow SCK Jumper) ,not J2.

I thought it was weird having to short J2 for firmware upgrade AND to slow SCK. That makes sense however my unit doesnt have a JP3 or any other jumper for that matter

Sorry about that. I thought I had most models of USbasp and this one I don’t have. :slight_smile:

I don’t know what firmware you loaded , but I have had real good luck with this one. Has Auto SCK.

"“usbasp-v1.06-alpha-2016-04-17-atmega8.hex” from petervh/bperrybap solves all these issues. myself and friends been using it for couple months now. big improvement. more info and other versions: https://github.com/bperrybap/usbasp/tree/1.06-alpha."

I can get the same error with nothing connected to the Usbasp. I guess it is possible the chips are dead, but a simple wiring error will cause the same thing.

Pin 4 and 6 on some Usbasp are TXD and RXD. I notice you might have your Gnd lead on 4.

Would love to know what it's doing to the fuses.

Anyone got a log of a USBAsp with the bad firmware trashing a chip?

Probably recoverable with HVSP, but you'd have to remove the placebo diode between reset and Vcc (I'm convinced that diode protects against a non-existent issue)