Burning Bootloader: Expected signature for ATMEGA328P is 1E 95 0F

Hi

I am trying to burn the bootloader on a blank Atmega328p-pu chip with an AVRISP MKii. But when I try to write the bootoader with the arduino IDE it gives the following error:

avrdude: Expected signature for ATMEGA328P is 1E 95 0F Double check chip, or use -F to override this check.

Somtimes it gives the following error:

avrdude: Yikes! Invalid device signature. Double check connections and try again, or use -F to override this check.

I tried to read the signature of the chip in avrstudio and it there it says it matches with 1E 95 0F

What could be the solution to this?

Thanks

Are all your connections correct? Do you have a crystal in the circuit? Are your wires making good contact? Is your reset wires connected properly? How do you have things connected? No one can help you unless you give us more details.

I pulled my good arduino chip out of the board and replaced it with a blank chip. And I used the icsp connecter on the arduino uno board to connect the programmer.

Does it say what the signature IS? Most likely cause: you have an ATmega328-PU chip instead of an ATmega328P-PU chip. They're nearly identical, but the 328 has a signature ending in 0x14

If this is your problem, you can probably temporarily change the "uno.build.mcu" in boards.txt from "atmega328p" to just "atmega328" and burn the bootloader. Then change it back, because the bootloader will happily lie to the Arduino IDE and claim to be a 328p.

No it doesn't say what the signature is. It only gives the errors seen in the OP. I'm sure it is an Atmega328P-PU i checked it. I bought them because they were identical to the chip that came originally on the board.

Nobody knows how to fix this problem?

It could be:

Bent pin on the 328 328 Put into the socket backwards Something else went bad

You wrote that you bought 'them" when you referred to the 328. Did you try another 328?

I bought two atmega 328P-PU's but both don't work. But when I try to write the bootloader on the chip that came with the arduino it goes without a problem.

I had that problem when I didn't have correct connection to the target chip how are you connecting what?

I removed the original arduino chip, placed a blank atmega in the socket. Connected the avrISP mkII with the ICSP connector on the board.

Can you run avrdude in verbose mode? Clicking the "burn bootloader" button while having compile/upload (in options vo 1.0) set to "verbose" should do it.

Usually if you can get as far as an "invalid signature", it means that a fair amount of the chip is actually working, but that's when using ArduinoISP, and the official programmer might behave differently.

I’ve put it in verbose mode and this is the output:

C:\Users\Thomas\Documents\arduino-0022\hardware/tools/avr/bin/avrdude -CC:\Users\Thomas\Documents\arduino-0022\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v2 -Pusb -e -Ulock:w:0x3F:m -Uefuse:w:0x05:m -Uhfuse:w:0xde:m -Ulfuse:w:0xff:m 

avrdude: Version 5.11, compiled on Sep  2 2011 at 19:38:36
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "C:\Users\Thomas\Documents\arduino-0022\hardware/tools/avr/etc/avrdude.conf"

         Using Port                    : usb
         Using Programmer              : stk500v2
avrdude: usbdev_open(): Found AVRISP mkII, serno: 0000B0041068
avrdude: usbdev_open(): using read endpoint 0x82
avrdude: Sent: . [01] 
avrdude: Recv: . [01] . [00] . [0a] A [41] V [56] R [52] I [49] S [53] P [50] _ [5f] M [4d] K [4b] 2 [32] 
avrdude: stk500v2_getsync(): found AVRISP mkII programmer
         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
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : STK500V2
         Description     : Atmel STK500 Version 2.x firmware
         Programmer Model: AVRISP mkII
avrdude: Sent: . [03] . [90] 
avrdude: Recv: . [03] . [00] . [01] 
avrdude: Sent: . [03] . [91] 
avrdude: Recv: . [03] . [00] . [01] 
avrdude: Sent: . [03] . [92] 
avrdude: Recv: . [03] . [00] . [0c] 
         Hardware Version: 1
         Firmware Version Master : 1.12
avrdude: Sent: . [03] . [94] 
avrdude: Recv: . [03] . [00] 0 [30] 
         Vtarget         : 4.8 V
avrdude: Sent: . [03] . [98] 
avrdude: Recv: . [03] . [00] . [02] 
         SCK period      : 0.50 us

avrdude: Sent: . [10] . [c8] d [64] . [19]   [20] . [00] S [53] . [03] . [ac] S [53] . [00] . [00] 
avrdude: Recv: . [10] . [00] 
avrdude: AVR device initialized and ready to accept instructions

Reading | avrdude: Sent: . [1d] . [04] . [04] . [00] 0 [30] . [00] . [00] . [00] 
avrdude: Recv: . [1d] . [00] . [00] . [00] . [00] . [00] . [00] 
avrdude: Sent: . [1d] . [04] . [04] . [00] 0 [30] . [00] . [01] . [00] 
avrdude: Recv: . [1d] . [00] . [00] . [00] . [00] . [1f] . [00] 
################avrdude: Sent: . [1d] . [04] . [04] . [00] 0 [30] . [00] . [02] . [00] 
avrdude: Recv: . [1d] . [00] . [ff] . [ff] . [ff] . [ff] . [00] 
################################## | 100% 0.00s

avrdude: Device signature = 0x001fff
avrdude: Expected signature for ATMEGA328P is 1E 95 0F
         Double check chip, or use -F to override this check.
avrdude: Sent: . [11] . [01] . [01] 
avrdude: Recv: . [11] . [00] 

avrdude done.  Thank you.

Would it help if I changed the signature in the config file to 0x001fff?

Where did you buy the chips from?

from conrad.be one of the biggest online elektronics webshop in the BENELUX

Hi guys, I'd been trying to burn my first bootloaders onto a couple of chips with my 'Uno' and was getting the same message. I was starting the wonder if the chips were dodgy, as I'd got them quite cheap on the net. After an hour or two of googling, editing the boards.txt file, checking and rechecking the wiring, adding a capacitor etc... I exactly mirrored the breadboard setup on the other half of the breadboard to try my other chip without moving the first chip and it's wiring...I also pushed the chips more firmly into the breadboard and socket on the 'Uno' (they were originally not so tight to allow easy removal). The burn was successful, so I put chip #1 into the place of chip #2 and it burned successfully too.

I'm not sure what exactly made the difference, but the physical connections seem to be quite important. In the end, it worked as per this instructable with no modifications: http://www.instructables.com/id/2-Arduino-the-ATMEGA328-As-a-Stand-alone-Easy-Chea/?ALLSTEPS

As the knowledgeable lads above have said, check your connections are solid!

Hi all, just posting my case as a reference.

I made a pcb with atmega and got the same error message. I have to triple checked every pins of arduino atmega and problem solved. Check your crystal and capacitor also. Better to check connectivity directly from your target atmega to your AVRmakeII or the Arduino UNO.

Thanks

That error is due for sharing any of the ICSP programing pins with other circuits, wich false communication signals.

Got it working. NOTE: Out of 5 chips, only one was labeled "328PB". The rest were 328P. The problem was only with the "328PB" The rest burned the bootloader find. BTW, I was burning the Nano Opti-bootloader.

My Hack was to edit the avrdude.conf file in the directory (on Win10)

C:\Program Files (x86)\Arduino\hardware\tools\avr\etc

search for m328, then commented out the first occurrence of "m328" and in the second occurrence of "m328" changed:

desc = "ATmega328PB"; to desc = "ATmega328P";

Then Burn the bootloader to the Arduino.

Afterward, revert back to the original avrdude.conf file by removing the changes or if you made a backup of the original file(as you should've !!!) swop them.

So, my changes look like this:

--- Beginning of my Changes ------

part parent "m328"

id = "m328p";

desc = "ATmega328P";

signature = 0x1e 0x95 0x0F;

ocdrev = 1;

;

part parent "m328" id = "m328pb"; desc = "ATmega328P";

add back the B after the 328P

signature = 0x1e 0x95 0x16;

ocdrev = 1; ;

end of Change

Note: After fiddling around some, my error changed. Adding the following for search purposes

"Expected signature for ATmega328 is 1E 95 14"

The ATMega328PB is a different microcontroller, and so you'd expect to see errors when trying to burn a bootloader to it as if it were an ATMega328P. The easiest way to get it working is to use Minicore, which has support for the 328PB.

Add the Minicore to your IDE, then no hacking is needed. https://github.com/MCUdude/MiniCore