Main Content

The digital LED clock that your (great-) grandparents would have used without difficulties!

DESCRIPTION
I remember I always had to set all digital clocks for my grandparents in the 80s - these clocks and watches always required some complicated button juggling! So, here it is: a DIY LED alarm clock that my grandparents would have been able to set and use without my help!

An Arduino-based LED clock with 7 individual alarms, highly intuitive user interface, temperature display, and display of days / hours / minutes passed since a special date, e.g., your birthday. An active / ringing alarm can be disabled by making a loud noise, e.g., by clapping your hands. Timer-based PWM sound output for alarm melodies.

The Arduino’s EEPROM is being used to store the alarms of course, and the DS3231 RTC is battery backed up, so it survives a temporary power outage and you won’t be late for work the next morning.

This was put together rather quickly, thanks to off the shelf components, Velcro and existing Arduino libraries for them! The clock can be built for about 30 - 40 $.
DETAILS
These are all off the shelf components. It is inexpensive and easy to assemble; I just soldered things on an Mega 2560 Arduino prototype board. Note that you can also use the Uno R3; but then, some pins change obviously. Just find the right places in the code.

The following ATmega / Arduino pins are being used:

Analog TMP36 Temperature: A0
Strobes for TM1638 modules: 31, 33, 35
Clock for TM1638 modules: 27
Data for TM1638 modules: 29
I2C Clock for DS3231: SCL1 = 50
I2C Data for DS3231: SDA1 = 52
Speaker / toneAC output: 11 (12)
The ino sketch is in the files section of this page. Please make sure you have the corresponding standard Arduino libraries installed; the clock is using:

DS3231.h
toneAC.h
TM1638.h
EEPROM.h
and of course stdio.h

The code is a bit sloppy…. sorry for that. If you want to change the special date which is being used in the clock to show the number of days (hours, minutes) that passed since that special date, e.g., your date of birth, graduation or marriage, just change the hardcoded date in showStatus(), in the call to the “days” function (see the assignment to unsigned long diff in the showStatus() function). That should really be a constant and not be hardcoded - something for you to change and improve in the code ;-)”

Link to article