atmega328pu -TH smd

hi guys i am having some trouble with burning a bootloader onto a recently made pcb, I get the error

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

I have made sure my connections are perfect so no trouble with that, I will leave a schematic of the way i have my pcb made and hopefully somebody will spot the mistake for it now allowing me to burn the uno bootloader (As ISP).


1K pullup might be too strong for the Programmer to overcome to pull and hold it low while communicating over SPI to bootload it.

It is definitely too strong to use with a 0.1uF cap from DTR (not seen) to create a reset for serial loading via Rx/Tx.

I also don't see any 0.1uF caps on the VCC and AVCC pins. Those are needed.

What are you using to program the bootloader?
Have you successfully loaded bootloaders before?

Can you please post an image of your PCB please so we can see your pinouts.
EXPORT and image from your CAD, rather than screen grab please.

Thanks.. Tom... :slight_smile:

I am using an arduino uno as isp to programme the chip, I have carried out some basic multimeter checks and noticed once i apply power to the pcb MISO has 5volts, I tested the uno MISO pin and this did not have 5 volts so i am guessing something is shorting the MISO pin to high? thanks guys for the response i will upload the rest just now

Thats what i can attach from easy eda...Still no luck burning the bootloader onto the chip so double checked chip against a known good nano and both are the same chip. I have gone wrong somewhere in the schematic for sure(not my strong point), Any help be appreciated thanks.



Have you used a DMM on a bare PCB to check your connections/continuity?

Tom... :slight_smile:

hi tom yes i have checked with a multimeter between programming pins and the chip itself and everything checked out, One thing i did not understand is the MISO pin on 2 of the boards has just under 5 volts and the rest of the boards do not, I have tried programming another board and still have the error.

This is the exact message i am getting on one of the boards

Arduino: 1.8.13 (Windows 10), Board: "Arduino Uno"

C:\Users\RyanA\Downloads\arduino-1.8.13-windows\arduino-1.8.13\hardware\tools\avr/bin/avrdude -CC:\Users\RyanA\Downloads\arduino-1.8.13-windows\arduino-1.8.13\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM5 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0xFD:m -Uhfuse:w:0xDE:m -Ulfuse:w:0xFF:m 

avrdude: Version 6.3-20190619

         Copyright (c) 2000-2005 Brian Dean,

         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "C:\Users\RyanA\Downloads\arduino-1.8.13-windows\arduino-1.8.13\hardware\tools\avr/etc/avrdude.conf"

         Using Port                    : COM5

         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

Error while burning bootloader.

Reading | ################################################## | 100% 0.02s

avrdude: Device signature = 0xff0000

avrdude: Expected signature for ATmega328P is 1E 95 0F

         Double check chip, or use -F to override this check.

avrdude done.  Thank you.

This may help assist in tracing tracks.
Have you made sure the tracks that are VERY close to the pads 2,3,4 and 8 are not shorted to the pads?
Have you checked when you have the programmer plugged in the power is being applied to the correct pins?

Tom... :slight_smile:


I've only done this once, for an AU part, using a Nano as ISP. I wonder about the programmer you're telling AVRdude you're using. I used "-c arduino" in the end to get it to work. Also, using the IDE to burn the bootloader, I needed a big cap (10uF I think) on the Nano's reset pin. Well I'm just guessing here, but suggest you at least check the programmer selection.

hi sherman could you explain abit further about the programmer side of things, I select the arduino as ISP to burn the bootloader but still with no success?:slight_smile:

Your command line includes "-cstk500v1" from which AVRdude concludes you're using the stk500v1 programmer, whatever that is. Here's the Windows command line I used with my Nano as an ISP to burn the stock bootloader to a Pro Mini:

avrdude -C C:\Arduino\hardware\tools\avr\etc\avrdude.conf -c arduino -p m328p -P com4 -b 19200 -U flash:w:ATmegaBOOT_168_atmega328_pro_8MHz.hex

Notice the "c arduino". I don't know if it makes a difference, but it might.

Normally I just use the IDE to flash a new bootloader, and if I've programmed the Nano correctly as ISP, and have selected the right programmer (Arduino as ISP) and the right target (Pro Mini 8Mhz), it works fine. But the command line also works except it leaves the lock bits cleared. (The lock bits are cleared to 0x3F by the AVRdude -e command, but the IDE changes them to 0x0F when burning the bootloader, at least it does for the Pro Mini.)

But whether I'm using the IDE or the AVRdude command line, I need to add a 10uF capacitor on the Nano's Reset pin or it won't work at all. I think this will be the same for your Uno.

I have never used UNO as ISP, don't you have to load the UNO with specific code to use it as an ISP programmer?

Have you previously successfully done any ISP via UNO bootloader programming?

Tom... :slight_smile:

hey tom, Yes you need to upload arduinoisp code then attempt to burn the bootloader, I have done this many times aswell but with this chip it just doesnt want to work, Starting to doubt my schematic now. I even tried minicore on the arduino ide with no joy! Driving me insane lol

What do you use to burn the chips tom?

I use one of these;

google AVR Arduino Programmer
I make the ICSP pins configured on the PCB like the header socket if possible.

Tom.. :slight_smile:

hey tom, Yes you need to upload arduinoisp code then attempt to burn the bootloader, I have done this many times aswell but with this chip it just doesnt want to work, Starting to doubt my schematic now. I even tried minicore on the arduino ide with no joy! Driving me insane lol

Will the Uno work to burn a bootloader to anything else, such as another Arduino? If so, then it would seem your circuit might be the problem. All of my bootloader burning has been to other Arduinos, not to just a chip, but my understanding is that all the chip’s ground pins need to be connected to ground, and all the Vcc pins, and AVcc, to the positive rail, and there have to be capacitors on Vcc - the Mini uses a 10uF and a .1uF, and there’s a .1uF from Aref to ground. The pullup resistor on Reset on the Mini is 10K.

But it seems to me that the first step, if not already done, is to make sure the Uno works to burn a bootloader to something else.

Edit: This is probably a silly question, but on your schematic what should be a pullup resistor on Reset is shown as a coil - L1. It is actually a resistor, right?

0.1uf capacitor was the problem, My silly mistake (THANKS GUYS!)