fmartinou / tydom2mqtt

Deltadore Tydom to MQTT Bridge
https://fmartinou.github.io/tydom2mqtt/
MIT License
86 stars 49 forks source link

Feature - add support for sh_hvac device type #118

Closed NathanKun closed 11 months ago

NathanKun commented 11 months ago

Hello, Thanks for your excellent project. I've installed it on my HA and it works great. It is able to connect to my Tydom, and pick up my light and my shutters. But it doesn't support my thermostat heater:

image

After some digging with Charles Proxy, I was able to find out the device type APIs used to read and control this thermostat. The device type is 'sh_hvac', not sure what does the 'sh' means but fine. The API it uses is a bit complicate, it doesn't use the /devices/data endpoint, but it use the /areas/data endpoint instead, maybe the idea is to control multiple thermostats in a room at the same time, but don't have multiple thermostat in a same room, so I can't test this case.

In this PR, I

The feature is tested ONLY on my installation.

Here is an example of the thermostat device added in HA.

image

I'm not a python developper, I tried to do my best, hopping the code quality is acceptable and I didn't break anything :)

fmartinou commented 11 months ago

That's a nice one; thank you very much! 🤩

fmartinou commented 11 months ago

Released as 3.3.0.