This Christmas I asked for a digital picture frame, with the vague idea of turning it into a status monitor: in my case,
Project Wonderful status, as seen above! I've now done so and in case you're considering it, here are some friggin' notes!
Here's what the end result looks like:
And here's how we get there!
The general plan of this is as follows: rather than displaying photographs, we'll generate whatever information we want to display in a photographic format, and then pass that off to the frame. The idea is to update these images once in a while (every 10 minutes, say). We generate two identical images, because if we only generated one the frame might try to be clever and just display the one image indefinitely.
First off! You need a digital picture frame. I really recommend getting a wireless one, since we'll be updating images remotely. I got a Kodak W1020 which is an OKAY frame and can do some neat stuff like
download images from Flickr by tag, but also has some really annoying limitations, limitations which could be fixed by a firmware upgrade HINT HINT KODAK MAYBE YOU READ MY INTERNET DIARY??
Here are the really annoying limitations of the Kodak W1020:
- There's a setting to put it in portrait mode (as opposed to landscape mode), but once you turn the screen sideways the menus stay in landscape mode, which is super dumb because you just told it you'll be turning it sideways. So you'll end up reading sideways a lot if you like portrait mode.
- It only displays JPEGs.
- The interface is poorly designed, and slide controls as often as not don't work.
- It only shows the first 15 images on a photo RSS feed.
- It caches these feeds, so when you're doing this fancy Flickr tag thing you actually have to reboot your frame to see anything new, once you've seen the first 15 images. And anyway, once you've seen these 15 images, it just stops and dumps you back to the menu. UM I WANT YOU TO LOOP, PICTURE FRAME, I AM NOT HERE TO BABYSIT YOU
- It's frozen on me a couple of times?
Generally I really wish the firmware was open source, because I could fix these problems and have a really kick-ass screen instead of just a pretty okay screen. KODAK SINCE I CAN'T DO IT PLEASE FIX THESE PROBLEMS, OKAY? But here are some nice features of the screen:
- It has speakers and a physical volume control, so you can play music and also watch movies, which is sorta cool!
- It can turn itself on and off at a set time during the day.
- It doesn't cache images it reads from a remote computer, which allows this whole thing to work!
Okay! So to get this status monitor to work there are two things we need to set up: the frame and the PC.
On the frame (the easy part!): we set the frame to display only the files on our PC's status directory, where there'll be two files. We have it change images once every 10 minutes, and to use a nice fade wipe. The advantage of a fade wipe is that only things that are different will appear to change during the transition, so our status numbers will update AS IF BY MAGIC. This is less visual noise than a slide wipe, which would be distracting you six times every hour with pictures bouncing in or whatever.
On the PC (the harder part!): first we create our image directory, and share it appropriately. Then we need to generate the images! For my purposes I made a PHP script that grabs a few already-existing status charts it needs, and then uses some simple PHP image manipulation to generate the image with these charts together. It then adds some status text (done with a shadow so it'll show up reasonably well on both light and dark backgrounds) and randomly grabs any image file placed in a special "backgrounds" directory to use as our background. Neat!
Then we just set up a cron job to run this PHP file once every 9 minutes (to guarantee that the frame will find an updated image when it refreshes every 10 minutes). If you're on Windows, a good cron substitute I've found is
Pycron. It runs as a service and works just like the real thing!
The script I hacked together is kinda - um, hacky? - but I've released it here in case it's handy.
You can download it here.
You could use this to track the number of emails you have waiting for you over time or whatever - the idea is that when you wake up you can roll over and look at this picture, and then plan your day accordingly. It's worth noting that we could generate video updates as well using this same system, but that is a task for another day! Or another lifetime when I have unlimited free time!
Finally, the results: in real life I display more interesting data, but you can still see how pretty the charts are! If you were really fancy you could automatically grab new photos off Flickr and dump them in, so you'd get a surprising new background with every status refresh. wait that's actually a pretty awesome idea