an arduino blink program written and analyzed in {c, asm, rust}
04f57d50 — jleightcap 11 months ago
Rust building typos, use HEX consistently
3558501e — jleightcap 11 months ago
.asm instead of .s for C; rename delay loop asm


browse  log 



You can also use your local clone with git send-email.

Most Arduino tutorials take the IDE as a given. This makes sense for ease of use, but what is really behind those "Verify" and "Upload" buttons? Instead of building complex software on top of an IDE, this project goes in the opposite direction: how does the simplest possible Arduino program work on a deeper level?

Using 4 languages as examples:

  • Arduino IDE (flavored C++)
  • Bare C
  • AVR Assembly
  • Rust

#Arduino IDE

Just the builitn Basic Examples. Not included here, there's nothing to change.


Adaption of builtin example, build steps come directrly from building in Arduino IDE with verbose output.

#AVR Assembly

Gold mine in this small blog post, adapted from ATmega168 into ATmega328p. This lecture gives more theory, architecture, and timing information.


This is almost entirely avr-rust's blink example, however this example didn't work immediately (for me at least). The missing pieces came from a blog post on creativecoder and brute force.