Skip to content

avrdude benchmark for Flash and EEPROM programming

mcuee edited this page Feb 29, 2024 · 25 revisions

Note

  • Speed is usually not the most important factor when choosing a programmer or bootloader. Stability may be more important. In terms of programmer, budget may play a key role in selecting the programmer. In terms of bootloaders, code size may be an important factor to consider.
  • This page will focus on the programmer and bootloader mentioned in the FAQ.

Methodolody

tools/test-avrdude -b generates an output for which benchmark tables can be filtered. For example,

./test-avrdude -e ./avrdude.exe -b -d 0 -t .\
 -p "-c urclock -P COM20 -p ATmega328P -b 2000000" \
 -p "-c urclock -P COM20 -p ATmega328P -b 1000000" \
 -p "-c urclock -P COM20 -p ATmega328P -b 500000" \
 -p "-c urclock -P COM20 -p ATmega328P -b 250000" \
 -p "-c urclock -P COM20 -p ATmega328P -b 115200" | grep -v ^'[^T |]'

Results

The benchmark shows the wall clock time of avrdude carrying out the following tasks

  • Fl-ewv: erase flash, then write a sketch with three sections separated by holes to flash and verify
  • Fl-r: read the full flash memory and write to file
  • EE-wv: write data with two data sections separated by a hole to EEPROM and verify
  • EE-r: read the full EEPROM memory and write to file

The sketch and data payload is roughly one sixth of the respective memory size

avrdude 7.3 MSVC64 binary under Windows, Arduino Uno Rev 3 clone using ATmega16U2 as the USB to Serial chip

-c pgm -p part Fl-ewv Fl-r EE-wv EE-r Comments
urclock ATmega328P 1.73 s 0.62 s 1.25 s 0.45 s -b 2000000 urboot u7.7 -eu-jPrac
urclock ATmega328P 1.79 s 0.80 s 1.25 s 0.46 s -b 1000000 urboot u7.7 -eu-jPrac
urclock ATmega328P 1.92 s 1.15 s 1.25 s 0.50 s -b 500000 urboot u7.7 -eu-jPrac
urclock ATmega328P 2.17 s 1.86 s 1.28 s 0.58 s -b 250000 urboot u7.7 -eu-jPrac
urclock ATmega328P 2.76 s 3.49 s 1.34 s 0.81 s -b 115200 urboot u7.7 -eu-jPrac

avrdude 7.3 MSVC64 binary, Arduino Mega2560 Clone with CH340 USB to Serial CHip

-c pgm -p part Fl-ewv Fl-r EE-wv EE-r Comments
urclock m2560 7.78 s 4.83 s 4.08 s 1.44 s -b 1000000
urclock m2560 8.68 s 7.56 s 4.11 s 1.37 s -b 500000
urclock m2560 10.51 s 13.13 s 4.13 s 1.59 s -b 250000
urclock m2560 14.73 s 25.41 s 4.25 s 2.05 s -b 115200

avrdude 7.3 MSVC64 binary under Windows, USBAsp (ATmega8A based)

-c pgm -p part Fl-ewv Fl-r EE-wv EE-r Comments
usbasp ATmega328P 2.53 s 5.43 s 3.03 s 0.69 s -B 0.25
usbasp ATmega328P 2.49 s 5.40 s 3.03 s 0.64 s -B 0.5
usbasp ATmega328P 3.10 s 6.72 s 3.03 s 0.68 s -B 1
usbasp ATmega328P 3.81 s 8.77 s 3.10 s 0.78 s -B 2
usbasp ATmega328P 4.80 s 9.82 s 3.12 s 0.85 s -B 4

avrdude 7.3 MSVC64 binary under Windows, USBtinyISP (ATtiny2313A based)

-c pgm -p part Fl-ewv Fl-r EE-wv EE-r Comments
usbtiny m328p 3.54 s 8.97 s 1.38 s 0.56 s -B 0.25
usbtiny m328p 3.56 s 8.73 s 1.36 s 0.56 s -B 0.5
usbtiny m328p 3.53 s 8.98 s 1.39 s 0.57 s -B 1