The items were ordered and then I used public domain software from Github, Adafruit and others for controlling the various hardware interfaces. I designed and wrote the specific code for controlling the visual display elements and user interface. The biggest challenge was selecting fonts that would "fit" into the memory space of the Uno (32kB). I wanted a large font (55pt) for the main time display but it consumed over 5kB of memory just for the "0-9" and ":" characters alone.
Another software issue concerned the support of the different time formats (along with the additional memory demands). I wanted to include UTC format because its commonly used in amateur radio communications when logging a QSO. Since the eastern time zone (where I live) is 5 hours behind UTC time, every time I switched between the two time formats there would be a difference in not only the displayed hour but also potentially the day and month (actually the year could be different as well). When eastern time format was selected, I would need to contend with another problem: daylight savings time. Instead of scratch writing something that might or might not work (might not was the more likely outcome), I decided to search for public domain code that might address these issues. Surely others have had these same concerns at some point? Sure enough I eventually found a "timezone" library that handled the time differential in UTC mode and automatically adjusted the time twice a year when switching between regular and daylight savings time (thanks to Github/JChristensen). I simply extracted the appropriate code sections and pasted them into my code. After a bit of tweaking everything worked as it should.
After struggling with the memory issue for a bit I finally decided to use a platform with greater memory...the Arduino Mega 2560 (256kB). I purchased a cheap clone from China for ~$16.00 (regular price $38.00) and got started on code development. I finally came up with what looked to me like an overall nice layout, color scheme and font selections as seen in the image below:
An added touch (pun intended) is the touch screen feature that allows me to press the screen to select between UTC and eastern time.
No comments:
Post a Comment