Binary metric clock using Arduino
This is a very odd kind of clock, which can easily be made with simple supplies.
To begin the explanation, I would like to say that I have always wanted time to be metric. 5 o’clock would be mid-day, 7:5 would be three quarters (6:00 pm), and so on. This prototype tells deci-days, centi-days, and milli-days, in that order. For those that are unfamiliar, ten deci-days are in a day, ten centi-days are in a deci-day, and ten milli-days are in a centi-day. For comparison, a milli-day is 86.4 seconds.
With my limited supplies, I had to make it read in binary, but that’s alright with me!
I am a beginner at Arduino. And a beginner at instructables. So at times it may not be perfect, and I hope you have some understanding!
Step 2: Building it
Step 3: Code & explanation
The complete code is available as binarymetricclock.ino. I will now proceed to explain the code:
int deci = 0, centi = 0, milli = 0, micro = 0;
These are the variables that keep track of the time. 0, 0, 0, 0 means midnight. These should be set to the time when you upload the code, or power it on for the first time.
void setup ()
This code is fairly self explanatory. I could have used a loop or something, but I chose not to.
For more detail: Binary metric clock using Arduino