Initial Arduino firmware.

Based on an older version, but (nearly) completely rewritten for this repository.