Arduino ISP bootloader flash

Using an Arduino Uno to flash the USBASP bootloader

I prefer to flash the bootloader on the ATmega328p chip before soldering. It is a lot easier than using the ISP header on the board to flash the chip after already soldered.

There are these cheap ISP shields for sale on Amazon and eBay. You also need an Arduino Uno clone to run the ArduinoISP sketch.

These shields were designed for the ArduinoISP sketch with all the additional status LEDs. The ZIF socket makes it easy to program the ATmega328p without damaging the pins.

The Arduino Uno (clone) needs to be flashed with the ArduinoISP sketch found in the Examples folder. No modifications to the sketch are needed. After it is compiled and uploaded the heartbeat LED should start to pulse.

The bootloader for the Feegle is the same as the Aardvark. It can be found here: https://git.40percent.club/di0ib/Misc/src/branch/master/aardvark/bootloader

To program the ATmega328P with avrdude you need to know the serial port the Arduino Uno shows up as on your computer.

The command to program the bootloader on an ATmega328p with avrdude is:

avrdude -p m328p -c arduino -P COM12 -b 19200 -U lfuse:w:0xD7:m -U hfuse:w:0xD0:m -U efuse:w:0xFC:m -U flash:w:bootloader-atmega328p.hex

With an ATmega328 it would be:

avrdude -p m328 -c arduino -P COM12 -b 19200 -U lfuse:w:0xD7:m -U hfuse:w:0xD0:m -U efuse:w:0xFC:m -U flash:w:bootloader-atmega328p.hex

Replace COM12 with the serial port the Arduino Uno is connected as.

-

For programming the bootloader onto an ATmega328p that has already been soldered I use the Lobot with Pogo Pins. https://www.40percent.club/2020/10/pogo-pin-lobot.html