ESP32 Tasmota OpenTherm Thermostat BLE
Details
  • 3/1/2021
  • OpenTherm, Thermostat, Tasmota, BLE
Share

ESP32 Tasmota OpenTherm Thermostat BLE

In the previous article we have created a simple opentherm enabled thermostat which uses an internal temperature sensor and controls boiler temperature to reach more comfort without indoor overheating and thus reducing gas bill. However you might want to control heating in a room, than does not contain wall unit or wall temperature sensor. For instance you're upgrading heating system in existing house and no new wires can be installed. So let's use one of the Xiaomi's fancy BLE-enabled temperature sensor to help improve your heating automation.

Tasmota preparation


If you have no tasmota based thermostat - please refer to the article on how to prepare one. After initial setup is done please log into your thermostat and navigate to Console menu and execute a command setoption115 1 (paste 'setoption115 1' into the box and hit enter). This will enable a BLE driver and bluetooth sensors scan engine.

Tasmota command execution
After all preparations done you can see nearby Bluetooth Low Energy sensors readings on the main page of your thermostat.

Tasmota opentherm thermostat main page

Automation

Like in the previous article we will use a simple linear curve to drive boiler temperature based on difference between room temp and room target temp.

Rule1
  ON Tele-LYWSD03fd8e0d#Temperature DO Var1 %value% ENDON
  ON DS18B20#Temperature DO Var2=(22.0-%Var1%)*13.0+35.0 ENDON
  ON Var2#State >= 35.0 DO Var3=%Var2% ENDON
  ON Var2#State >= 75.0 DO Var3=75 ENDON
  ON Var2#State < 35.0 DO Var3=35.0 ENDON
  ON Var3#State DO ot_tboiler %Var3% ENDON

Please note a name of the sensor 'Tele-LYWSD03fd8e0d#Temperature', you will need to replace MAC address with your value (last 6 characters) right after 'LYWSD03' and before pound (#) character.

Put all things together

Master OpenTherm Shield Connection OpenTherm Thermostat Shield


Automation rules in action

You can observe a rules in action navigating to Console menu from module's main page
Tasmota OpenTherm rule execution