Not a Nest

Raspberry Pi Wireless Thermostat

As I wrote before, I've been hacking around with my wireless thermostat. Over the weekend I spent a couple of hours throwing together some code to act as a thermostat control loop, running from a Raspberry Pi. I've shared the code on GitHub.

There's two bits: a little C executable using Wiring Pi, that sends the commands to the boiler, and a Go executable that watches the temperature from an attached digital thermometer (a DS18B20) and triggers the thing that sends the commands. (The whole thing was Go for a while, but Go is too unreliable for timing the transmission, so it seemed easiest to move that bit to Wiring Pi in C.)

To put all this on a schedule, I'm using cron to write the desired temperature into a file that's being read every few seconds. If the monitored temperature goes 0.5°C over the desired temperature, the boiler turns off. And if it goes 0.5°C under, it turns on. It's a simple little system, but it's been running for a couple of days now, and hasn't set the house on fire yet.

The thermostat is now marginally less convenient than it was when I started, so the next step is to do what I promised with a shared calendar (not everyone in the family wants to SSH in to turn the heating on).

And it's not done until you've put it in a nice box and it doesn't look like an improvised explosive device. I've always enjoyed watching Tom put things in boxes, so it might be time to get some advice.

For a stretch goal, I'd like to poke around with HomeKit integration: "Hey Siri, turn the heating on", etc. And actually, thinking about it, that's something you can't do with a Nest.