This project uses a TinyCircuits TinyScreen.
I'm still working on an enclosure for it, but here's the app for your enjoyment!
Build Journal
I sit, laptop in front of me, left hand ready to trigger a switch, right hand poised to shove a battery home. The atomic clock is loaded up, and I'm waiting for midnight to start my little microcontroller timers. On my right is the Hypnos pendant, and on my left is this new experiment, the Chronos Ke. If this goes well, they will both be synchronized and give me a new window onto time.
They both use ke, a Chinese unit of time that was traditionally equivalent to 1/100 of a day – about 14.4 minutes.
It's my first project with the TinyScreen, a fantastic little 96x64 display, which is super bright and super tiny. My code is built from the demo sketch. It uses the millis function, which gives you the current uptime of the program in milliseconds.
-- Ooh! They just flashed 2 ke. :)
There are 86400 seconds in a day, which means 864 seconds per ke, i.e., 864000 milliseconds. So, you start with the current uptime, which we'll assume to be midnight. Take the uptime and divide it by 864000 and you get present time in ke. Display this in vaguely centered text, and you have a ke watch!
Now, I need to figure out a housing. So much to 3D print, so little time!
Mounting is a little tricky with this one, because you can either deal with a pretty thick shield stack (TinyDuino's gift and curse) or remove the USB shield. This means you have to dis-/reassemble the thing, and reset the clock, every time you want to charge it.
For now, I'm gonna go to sleep and see if they still keep good time in the morning! They definitely seem synced to each other – it's just gone 3 ke and they're still in tune. :)
•••••
So, of course, constantly showing the time caused it to run out of battery by morning. I tuned up the code – adding a button press to wake the display, at Ken's suggestion. Now, the screen is off unless you push one of the four buttons on the sides of the screen. Plus, I formatted it to be a little prettier, with simple blue and yellow text. You can download my app and upload it directly to your TinyDuino from CodeBender:
Comments