Skip to content

Commit

Permalink
Set hvac action to idle unless actually set to off
Browse files Browse the repository at this point in the history
Fixes #3
  • Loading branch information
tonyroberts committed Nov 14, 2023
1 parent 728eb23 commit 0690873
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion custom_components/wundasmart/climate.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,8 @@ def __set_hvac_state(self):
self._attr_hvac_action = (
HVACAction.PREHEATING if ((flags & (0x80 | 0x20)) == (0x80 | 0x20))
else HVACAction.HEATING if flags & 0x20
else HVACAction.OFF
else HVACAction.OFF if flags & 0x4
else HVACAction.IDLE
)
except (ValueError, TypeError):
_LOGGER.warning(f"Unexpected 'temp_pre' value '{state['temp_pre']}' for {self._attr_name}")
Expand Down

0 comments on commit 0690873

Please sign in to comment.