Coder Social home page Coder Social logo

thermo's Introduction

Bond's thermo

I had a few raspberries lying around, I refreshed my Python knowledge and made a custom remote controlled thermostat from with a relay.

Consists of two parts

Web Interface

running on my pulbic facing VM

  • simple express api with basicauth
  • running on my VM
  • saves state to local files

Python Thermostat Controller

running on the rPI

  • measures temperature via an Adafruit MCP9808 sensor (I2C bus)
  • handles buttons (pins 12, 20)
  • queries the API for initial settings (REST with basicAuth)
  • sends updates to the API
  • works offline too
  • saves state to local files

Setup

PI

  • Instal a fresh pi
  • check out this repo
  • add users to the users.json file
  • add python startup to crontab
  • create users.json file from example.

Web Interface

  • install node
  • set recommended security measures
  • check out repo
  • run npm i
  • create secrets.js file from example with openWeatherMap api key.
  • add node thermo-api.js to forever

I was at:

  • express api kinda working
    • ✅ trace to log when status is hit.
    • log should be sent even on network error
      • trace last log entry date
      • sync clocks
  • python should start sending api updates to the new service
    • send when:
      • ✅ measured temp changed
      • ✅ button pressed
    • ✅ poll last updated temp setting, see which one is more recent
  • web interface pretty much working

thermo's People

Contributors

symunona avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.