World of Cheese

sze 30 december 2015

Thermosflask

Posted by Andy in Tech   

As part of the farm renovations, the central heating thermostat is now in a room which does not have a radiator. This would leave the heater permanently on and isn't a great solution. The raspberrypi has come to the rescue and I've written a python program to control the heating and do a little more- I might publish the code but it is a horrible botch'it job of libraries The program is called thermosflask as flask is the main pythonic component .This post is a bit of an overview of the features of thermosflask and I'm more than happy to share the love about these bit if people are interested The major features are :

  • A raspberry pi with a DS18B20 sensor on a long cable - This sensor gives a digital output of the temperature which can be manipulated nicely The rpi is connect to a relay in the communist thermostat by a long cable through the wall and with a little custom electronics, the pi can override the thermostat control of the relay and turn on the heating.
  • Google Calendar integration - Thermosflask downloads the private ics of a dedicated calendar and processes the calendar including the daily, weekly, monthly repeats. The temperature is set by event's title and the length of the appointment determines the heating period. This enables the rpi to be controlled via the internet but without exposing the machine directly to the internet
  • The main engine of the thermosflask is a python apsheduler program which measure the temperature on a regular schedule and activates heating accordingly.
  • Flask - This is the funky web templating framework which links the python schedule to a webserver and adds interactions
  • Worthy templates - a very nice funky bootstrap template which enables the generated flask html to be viewed on phones/tablets and computers
  • Funky schedule listing
  • Direct html links to recent TV/Podcasts/radio downloads hosted on the media server
  • A funky photo gallery of the most recent photos uploaded to the media server
  • Local weather for today and tomorrow

Here are some screenshots showing the heating/non-heating status and the download page


    
 
 

Comments