a) How do I know what time it is?
b) How do I tell the Arduino that, and what other things do I want to tell it?
c) How do I get the Arduino to keep the time, once it has been given a start time?
d) How do I display what the Arduino thinks the time is?
Hi,
i forgot to mention that a DS3231 RTC is used, a very good clock, but with no memory.
A-So Time is checked with use the ds3231 library Here i got it from, and very usefull
[Here it is sold but it is also really, very easy to build your own.
B-Some variables are used to keep time in arduino, such as "hrs", keeps hour value, "dts" as day values, "mnths" as mounth value, and finally "dows" as day of week value.
C-when RTC is attached, I2C is used to get the values in the arduino.
D- to display the values, i use a lcd, which can be downloaded from the Arduino Playground - LCD
Of course you can buy a DCF clock, what you might find usefull.
I am happy with this one, and it works great. Keep in mind that this clock is very, very accurate.
I also used the ds1307 library, this was the first clock i used, and did not change anything in the code to use the DS3231.
The link to the DS3231 code explains all, about how to get the values in arduino and keep time in arduino.