nitaybz / homebridge-sensibo-ac

Homebridge plugin for Sensibo - Smart AC Control
GNU General Public License v3.0
70 stars 15 forks source link

Bug: Setting AC to OFF and Rotation Speed to value > 0% results in inconsistent behavior #108

Open seidnerj opened 1 year ago

seidnerj commented 1 year ago

I have a scene that's meant to turn off the AC. This scene was set-up via the Home app with the only action of setting the AC to OFF. When looking at the actual definition of this scene via the Eve app, one can see that this scene sets multiple values for the AC, not only OFF but also Rotation Speed etc.

When Rotation Speed is set to value that is greater than 0% and mode is set to OFF, every time the scene runs something different can happen. Sometimes it turns the AC off, sometimes it turns the AC on, it is not consistent. It could be that 4 times in a row the AC is turned OFF and then in the 5th try the AC will turn ON. It seems to me like a conflict/race condition between these two settings.

I suspect that setting Rotation Speed to >0% value results in the AC setting its mode to the last non-OFF mode, depending on who wins the race, a different value may be set for the AC's mode.

I suggest making sure that setting AC mode to OFF trumps any other setting that could set the mode to a non-OFF mode.

benwebbbenwebb commented 1 year ago

Thanks for the info @seidner, I think this has crossover with another issue I’ve been looking in to. When I get some time I’ll take a look for race conditions as you suggested.