Skip to content

Latest commit

 

History

History
29 lines (16 loc) · 1.62 KB

README.md

File metadata and controls

29 lines (16 loc) · 1.62 KB

M-THERMO 2.0

This is a very simple firmware for a ESP8266 (WEMOS D1 mini) based thermostat, using the excellent project Homie for ESP8266. The whole firmware was created in less than a day, so don't expect production quality, though I use it without any issues every day on 5 devices in my home.

Hardware

  • WEMOS D1 mini
  • SHT21/HTU21 temperature & humidity sensor
  • WEMOS Relay shield
  • WEMOS OLED shield
  • 220V AC to 5V DC power supply module (not mandatory for the project)

There are no PCB schematics, as its pretty straightforward using the WEMOS shields. Only possible places for mistakes are the buttons and the SHT21/HTU21 sensor. Pins for buttons are defined on lines 76 and 77. And SHT21/HTU21 sensor uses I2C, so it needs to be hooked on SCA and SCL pins of the ESP.

Software

There is a simple Mosca MQTT broker in the "mosca" folder. You can run it by first running npm install (to install node modules) and then node index. It expects MongoDB installed and running.

OTA

Edit update.sh to replace deviceid with the targeted Homie ID. Then run update.sh in console. The update script expects a compiled bin binary file inside M-Thermo folder (esp_firmware/M-Thermo/M-Thermo.ino.d1_mini.bin). You can build & export that file using Arduino IDE: Sketch -> Export compiled Binary.

Shiny video of how I built my thermostats

Because why not?

M-THERMO 2.0 Video