klausahrenberg / WThermostatBeca

Replaces original Tuya firmware on Beca thermostat with ESP8266 wifi module
395 stars 96 forks source link

Case-insensitive MQTT payload check #174

Closed dimerr closed 3 years ago

dimerr commented 3 years ago

Hello,

by default HomeAssistant sends payload for power_command_topic with capital letter and it isn't possible to customize that. Turns out that:

mosquitto_pub -t warmfloor/thermostat/set/deviceOn -m "True" is not the same as: mosquitto_pub -t warmfloor/thermostat/set/deviceOn -m "true"

warmfloor/thermostat/set/deviceOn True
warmfloor/thermostat/set/deviceOn True
warmfloor/thermostat/set/deviceOn true
warmfloor/thermostat/properties {"idx":"warmfloor","ip":"192.168.1.47","firmware":"1.18","temperature":20.50,"targetTemperature":26.00,"deviceOn":true,"schedulesMode":"off","locked":false,"floorTemperature":0.00,"systemMode":""}

While

warmfloor/thermostat/set/deviceOn False
warmfloor/thermostat/properties {"idx":"warmfloor","ip":"192.168.1.47","firmware":"1.18","temperature":20.50,"targetTemperature":26.00,"deviceOn":false,"schedulesMode":"off","locked":false,"floorTemperature":0.00,"systemMode":"heat"}

works just fine...

pashok2398 commented 3 years ago

Duplicate #160

klausahrenberg commented 3 years ago

This change will com TruE at next version. So far only 'true' values are accepted. Wait to next version 1.20 - then it will be fixed.

klausahrenberg commented 3 years ago

Fixed since 1.20. Notice, the version needs some further testing - still alpha status.

klausahrenberg commented 3 years ago

Fixed since 1.20. Notice, the version needs some further testing - still alpha status.