ICSP header for bootloader burn

I have been reading the ISP/Bootloader page, which is very helpful. I am attempting to burn the bootloader on an Arduino Uno, using an Arduino Uno as the programming board. I just want to be sure -- can I use the ICSP headers on both the programmer and target boards? I am assuming they are all same-to-same connections (Vcc to Vcc, Gnd to Gnd, MISO to MISO, etc), with the exception of the target Reset, which would be connected to programmer digital 10. Is that correct?

Your supposition is correct. The ICSP pins on a Uno are simply connected to the corresponding pins on the board edges so can be used interchangeably

Note that this is not the case on all Arduino boards

Thank you!

No. The Reset pin on the Target ICSP header should go to Pin 10 or the Arduino UNO acting as a programmer.

When using an UNO with the "Arduino as ISP" sketch, I recommend a 1 to 10 microfarad capacitor between Reset (+) and Ground (-).

As noted in the original post

OK, so I think I wired up the boards correctly, but the burn won't complete. Here is the activity log; I am wondering if there are any telltale signs as to what is going wrong:

Arduino: 1.8.19 (Windows 7), Board: "Arduino Uno"

C:\Users\Robin\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/bin/avrdude -CC:\Users\Robin\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino17/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM8 -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, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch

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

     Using Port                    : COM8
     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.02s

avrdude: Device signature = 0x000000 (retrying)

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

avrdude: Device signature = 0x000000 (retrying)

Error while burning bootloader.

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

avrdude: Device signature = 0x000000

avrdude: Yikes! Invalid device signature.

     Double check connections and try again, or use -F to override

     this check.

avrdude done. Thank you.

Oops. I missed that part. Sorry.

Either a bad connection or the system clock on the target processor isn't running.

A loop-back test on the target board fails. However, the target RCV LED does flash when I use Serial Monitor to send it characters/strings. Does this suggest the problem may be with the return path (at a minimum)? I was hoping the problem was simply a corrupted bootloader, or a failure that could be bypassed using this alternative connection, but I'm now thinking the communication path is ruptured.

On an UNO, the RCV LED is run by the USB-to-Serial chip and does not use the processor at all. If you unplug the ATmega328P you will still see the RCV LED blink when you send serial data to the board.

The fact that RCV flashes but no characters are echoed back to Serial Monitor makes me think that the SND path is broken. It sounds like that would also explain the bootloader failure.

Are you running the ArduinoISP sketch on the programmer?
Check the comments in that sketch, there are instructions for attaching debugging LEDs, also some settings there may be useful.

Yes, that's the sketch I am using. AVRDUDE.exe provides some pretty thorough feedback about its progress (or lack of). Can you tell from what it posted what the issue might be?

The "stk500v1"? Is that right?

Have you tried following the Sparkfun tutorial "Installing an Arduino Bootloader"?
That tutorial seems to say that, instead of using the

-c stk500v1

option, instead you should be using the

-c avrisp

option.

Good luck!

Thanks for this suggestion. I'll give it a try. I have so far failed to see where the command line arguments are stored. I have invoked AVRDUDE.exe only from the IDE. Can I run it from a command prompt? Or can you tell me where I might edit the command line? Thanks.

Oops, I should have followed your Sparkfun link first! I see it answers my question. I will give this a try. Thanks!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.