Ricky Moorhouse

2016

Pi Zero as a desklight

When we set up our office earlier in the year I decided on a standing desk which I put together using the Ikea Algot system.
In order to avoid using up desk space with a light I originally planned on a clip on light but then saw my Pi Zero and Unicorn pHat and thought they could make a good alternative.

Hardware

The Raspberry Pi Zero is in a simple case, mounted onto the underside of the shelf above my working space. Attached is it's power cable, a PiHut wireless adapter connected via USB and of course the Unicorn pHat. The power cable is routed down the side of the shelf to my PowerCube, which will eventually be mounted under my work surface but it's sticky pad wasn't strong enough to hold it on the underside of the desk!

Software

As I've not yet added any switch for my light, it all has to be controllable remotely, so I set up an API to set the colour of the light which I initially controlled via a web browser with urls like:

http://192.168.0.15:8009/colour/<red>/<green>/<blue>

As you can imagine that got a bit tedious - especially to turn off after I'd shut down my laptop! The next step was to add a simpler way to control the light through my phone so I set up iControl Web with buttons to adjust the light settings. Then when I saw the Home app on iOS 10, I researched ways to get my custom light controllable through that and came across Homebridge which I could point to my API via it's Better HTTP RGB plugin, a bit of config and a couple of changes to my API.

All the code for my API is on github and is very much a work in progress!

Hatching chicks at school

At Jessica's school, where I am a governor and Laura works, they've got an incubator of eggs from Living Eggs, so that the school can watch as they hatch into chicks.

On Monday I got a text from Laura wondering if it would be possible to set up a webcam to watch them hatch.  We happened to have a wireless webcam that wasn't being used so that evening I got it out to make sure it was working and configured it with an FTP server to upload photos every minute and if there was motion detected.

The next day I took the webcam into school and got it set up with the help of James who looks after the school computers and network. You can see the latest pictures from the webcam on the school website.

In the early hours of this morning the first egg hatched: