Here's what I get when I try to install the bootloader:
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x14
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x01
avrdude: stk500_initialize(): (a) protocol error, expect=0x14, resp=0x10
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude: stk500_disable(): unknown response=0x12
I've checked the pins (and verified via continuity from point to point with an ohmeter) and it's wired just like the diagram and with no solder bridges. I installed the ArdiunoISP Sketch on the Arduino Uno onto a known good Atmega 328 chip, then Tools >Programer> Arduino as ISP, then clicked "Install Bootloader". The error you see above is what I get. What can I do?
Moderator edit: </mark> <mark>[code]</mark> <mark>
Post verbose output. Check wiring, too, specifically the reset line on the target (with verbose output I could recognize if this was it, or if using a usbasp, where it's unmistakable) - burn bootloader is done in two steps, and if reset doesn't go high between them, the second half fails
Also make sure you have disabled autoreset on the programmer ( the one with arduino isp on it) with a cap from its reset to ground. That will often cause protocol errors.
Just tried it again with a 4.7uF cap across reset and ground on the board with the Arduino ISP uploaded to it and had a better result. The LED's lit up like a Christmas tree and it said done burning bootloader. Unfortunately I still can't load a program onto the chip. I will this time say I used a Nano as the Adruino ISP to load an UNO. I don't know if that'll make a difference.
777funk:
Just tried it again with a 4.7uF cap across reset and ground on the board with the Arduino ISP uploaded to it and had a better result. The LED's lit up like a Christmas tree and it said done burning bootloader. Unfortunately I still can't load a program onto the chip. I will this time say I used a Nano as the Adruino ISP to load an UNO. I don't know if that'll make a difference.
The problem was that I had Nano selected as the board to write to. I needed the UNO since that was the final destination for the bootloader (and the board the freshly bootloaded chip would be programmed in).
Similar problem, need clarification and understanding.
operating system: Debian linux, tried both Buster and Jessie
boards: using new UNO as programmer, UNO R3 with new (bare) ATMEGA328P-PU chip from DigiKey as target.
setup: exactly as in https://www.arduino.cc/en/Tutorial/ArduinoISP is my goal, rechecked many times.
problem: try to install bootloader and receiving multiple protocol errors. My verbose error message is almost identical to the original poster except Arduino 1.8.9 and avrdude Version 6.3-20171130, and I have no lines of send and receive. Errors, expect, and resp values are all identical. I can send my verbose output if it would help, but might as well save bandwidth.
From the above, it looks like a capacitor across reset to gnd on the programmer board should allow me to burn a bootloader, but I'm confused.
4.7 uF or 470 uF?
Is this for sure on the programmer board?
Why does this work? What does it do?
If I can understand the why, then I may learn something about the hardware that will help me in the future. At the moment, I'm a greenhorn trying to get started by reviving a board (the target) that my grandson fried playing around with 12V. I'm assuming, perhaps incorrectly, that the problem was in the chip. The target board shows a solid power-on LED and solid pin-13 LED when connected to the programmer.
Digging around some more, and reading with better understanding, I think I have solved my problem without being able to check it until I buy a capacitor.
The arduinoISP tutorial says:
The capacitor is 10 uF.
Yes, it is clearly shown on the programmer board (MEGA) but not on the circuit diagram for the UNO programmer application.
The capacitor functions to disable the autoreset function of the board and is associated with boards that have an interface between the microcontroller and the computer's USB. Beyond that, I'm still in the dark.
The tutorial applies this additional circuit component to a UNO programmer in the paragraph under the MEGA diagram.
Thanks, forum members, for standing by ready to help, and for the encouragement to not give up but keep searching the resources available. Perhaps we beginners would be helped by including the capacitor in the UNO as programmer circuit drawing in the tutorial.
Yes it would be better if the tutorial was improved.
The capacitor can be any value that is big enough to absorb the reset pulse that comes from the little 0.1uF capacitor that is between the usb-to-serial chip's DTR pin and the ATmega328P's reset pin. A 4.7uF may be enough, the general recommendation is 10uF or bigger. I use whatever I have handy, sometimes a 33uF one. Another way is to cut the Reset-EN jumper pad trace on the programmer UNO with an x-acto knife (carefully). That will disable auto reset at the beginning of sketch upload.
The idea of disabling reset is you only need to reset the Arduino that you are trying to program. When you are using the Arduino as ISP sketch that you have uploaded to the programmer UNO, you don't need to reset it any more. You need to use to to receive instructions from the computer that guide the programmer UNO to make changes to the target UNO.
If you cut the Reset-EN jumper pad trace, that semi-permanently disables the auto reset. So if you want to upload more sketches on that UNO to replace the Arduino as ISP sketch, you'll need to:
tap the reset button manually at just the right time during the compilation and upload process, or
use a solder bridge (small blob of solder) melted across the jumper pad to re-enable the auto reset, or
install a surface mount switch or jumper pins on the pads, and then close the switch or install a jumper on the pins.