This is a scratchpad of sorts for me to resharpen my skills in bare metal embedded programming. No promises about how pretty this code it, but I hope it will become so (and keep its functionality.)
My main goals are to be able to run basic arduino sketches using just C (and some headers...) and compile it with Cmake and flash using the terminal. Wish me luck!
sudo apt install gcc-avr binutils-avr avr-libc avrdude
# Unplug Arduino
ls /dev/tty*
# Plug in Arduino
ls /dev/tty*
# The difference is the Arduino target!
Navigate to the proper directory.
make # This will compile the code.
make flash # This will compile and flash the Arduino.
Big thanks to the following resources:
- https://create.arduino.cc/projecthub/milanistef/introduction-to-bare-metal-programming-in-arduino-uno-f3e2b4
- https://fabacademy.org/2022/labs/charlotte/students/aaron-logan/images/week09/Bare%20Metal%20Programming%20.pdf
- http:https://www.florentflament.com/blog/arduino-hello-world-without-ide.html
- https://maumagnaguagno.github.io/baremetal