I seek your expert help to find the root cause to a mysterious problem I keep having recently.
I have a custom Arduino board based on the Atmega328 controller. I burn the bootloader myself to these boards (using the Optiboot) and already made a few hundreds of them.
But recently about 10% of my boards cannot be bootloaded, I get the error message:
avrdude: Device signature = 0x1e00f0 avrdude: Expected signature for ATmega328P is 1E 95 0F Double check chip, or use -F to override this check. avrdude done. Thank you. Error while burning bootloader.
I used to mount the TQFP package version of the controller earlier, and with those guys I did not have this problem at all. Subsequently I changed to QFN due to its size and since I keep having this issue. No idea if it has to do with the new package though, as of course the board layout itself also changed.
I only have one Nano-based breadboard I use to burn the bootloader and did it several hundred times. Therefore that cannot be the issue. I tried burning the bootloader of other types like Nano, Micro, MiniCore etc., to no avail (not that I expected). All boards I can bootload can be bootloaded reproducably. Same is true unfortunately for those I cannot. :confused:
I checked the affected boards, they are recognized, therefore the FTDI chip is OK (I know it has nothing to do with the bootloader). I checked voltages, all OK. Caps, especially the one between reset/DTR is OK. Current consumption of affected boards are inside the spec, no obvious sign of short/board damage, except maybe that the Rx/Tx LEDs sometimes flash or stay lit when connecting the ICSP header.
I had the Atmega328P swapped on all of the affected boards, no change. Therefore it cannot be the chip itself, I anyway only buy from DigiKey and 10% is way more than the 100ppm I expect from chips for the consumer electronics ...
This is the full verbose log I get for one of such a board.
I noticed however that the differing signature complained about by the IDE is not always the same even for the same device...
What could be the problem? Is there any way to detect if the controllers are still OK? How to use that -F override function? Haven't found anything on that...
C:\Users\MunkaGep\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.0.1-arduino2/bin/avrdude -CC:\Users\MunkaGep\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.0.1-arduino2/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM7 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0xFD:m -Uhfuse:w:0xDE:m -Ulfuse:w:0xFF:m avrdude: Version 6.0.1, compiled on Mar 19 2015 at 14:43:01 Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/ Copyright (c) 2007-2009 Joerg Wunsch System wide configuration file is "C:\Users\MunkaGep\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.0.1-arduino2/etc/avrdude.conf" Using Port : COM7 Using Programmer : stk500v1 Overriding Baud Rate : 19200 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 : STK500 Description : Atmel STK500 Version 1.x firmware Hardware Version: 2 Firmware Version: 1.18 Topcard : Unknown Vtarget : 0.0 V Varef : 0.0 V Oscillator : Off SCK period : 0.1 us avrdude: AVR device initialized and ready to accept instructions Reading | ################################################## | 100% 0.06s avrdude: Device signature = 0x1e00f0 avrdude: Expected signature for ATmega328P is 1E 95 0F Double check chip, or use -F to override this check. avrdude done. Thank you. Error while burning bootloader.