The AVR Alarm Clock is Complete

After a long pause, I finally took the time to complete my AVR-based alarm clock project this weekend. I redesigned many parts of it in order to simplify the design, maximize robustness and minimize the amount of work required. As such, I decided to use off-the-shelf components where possible. I had a billion ideas for cool features to add to this alarm clock, but since I have a tendency to get carried away, I decided to keep the plan simple: my initial goal is to complete a basic, usable alarm clock. No more, no less.

The completed clock incorporates the following modules and parts:

The modules are connected together using simple pin headers and dupont jumper cables. These cables are inexpensive and come pre-assembled, saving me the time and effort of crimping my own connectors. The ATMega64 board is very much overkill for this project, but the board in question is only a few dollars than weaker alternatives and has many I/O pins, leaving room for future expansion.

The source code for the alarm clock is written entirely in C and compiled with avr-gcc. I used an I2C master library written by Peter Fleury to interface with the clock module, but wrote custom drivers for the LCD and DS1307 chip, which fortunately wasn't very difficult. I used an usbasp programmer with the avrdude software to flash the microcontroller. The tools worked perfectly on my Linux machines and I would recommend these to anyone who wants a cheaper (or more portable) alternative to the Arduino.

The clock, as it is now, is very basic. It does, however, have a several advantages over commonly available alarm clocks, such as:

There are of course many possibilities for future improvement, such as supporting different alarm times on different days of the week and automatically taking holidays into account. I installed an in-system-programming port on the back of the alarm clock so that I can upgrade its firmware without needing a screwdriver. I can even reprogram it while it's running.

If you'd like to take a peek, the source code for the AVR alarm clock is available on github.