rpiclock
 
rpiclock displaying local time
rpiclock displaying GPS time
Tardis image credit: jeayese   
 
 
The Raspberry Pi is a convenient, inexpensive device for driving a HD display and I thought it would be fun to use one for a time display. So I wrote rpiclock (pronounced with a silent 'r'). It has a few interesting features, most of them configurable via a setup file:
 
  • it shows local, UTC, GPS time and Unix time
  • the format of the time shown can be HH:MM:SS or HH:MM, 12 or 24 hours,and with a blinking/non-blinking separator
  • it can automatically fetch a leap second table so that it can calculate GPS time
  • it shows 23:59:60 when a leap second addition occurs
  • it can power down the display at programmed times to save power and the monitor (works properly with RPi+LCD monitor, not correctly on PCs)
  • you can use a nice background image and a logo on the clock and the font colour can be changed to suit the background image
  • in slideshow mode, the image is randomly chosen from a specified directory
  • there's an event mode, where a picture can be shown on a particular day(s) eg a picture of the boss on her birthday
  • it doesn't show the time if the host is unsynchronised, as determined by querying ntpd
  • the display can dim, according to a number in a file written by another process eg a process measuring the ambient light level 
  • the configuration file is re-reread every time it is changed and (most) changes applied.
There's also a context menu so you can experiment with settings (and quit when in full-screen mode).
 
There are no special tricks to make sure that the clock updates at the correct time - the software just uses a QTimer (usleep() at the bottom?) to wake up at the right time. The latency and jitter are a few milliseconds typically.
 
I've had a rpiclock driving a wall-mounted Dell S2340L since May 2013. I fretted a bit about image burn in at first, but that doesn't seem to be happening; maybe the power save mode (it only runs during working hours) helps with that.
 
You may need to customise the layout of the graphics a bit if you have an oddly-shaped logo that you want to use. The logo I designed for is 300 by 228 pixels. 
 
If you find a bug let me know.
 
Download rpiclock source code  here . There are some instructions and setup hints in the README. Sorry, no binaries.

Be nice. If you copy something, please give credit where it's due. Thank you.