Arduino development with a makefile

A friend of mine asked me today whether it is necessary to use the Arduino IDE for development. It just happened that I did the googling for the exact same thing a week ago, when I started developing Ardulike and missed the convenience of a real text editor.

Getting everything going is actually quite easy, thanks to the Arduino Makefile project:

  1. The arduino IDE is needed (for avr gcc and possibly other things)
  2. python-serial library is required as well (run apt-get install python-serial on debian)
  3. $ mkdir ~/src/ && git clone ~/src/
  4. Check and modify the arduino makefile example, put the makefile into the same directory as the sources (.cpp, .h files).
  5. Run make to compile, make upload to upload the sketch.

For reference, the Arduino Makefile has a really nice README.