diff --git a/homeassistant/components/geniushub/climate.py b/homeassistant/components/geniushub/climate.py index 5acc25a36ee..9a19edd9f8b 100644 --- a/homeassistant/components/geniushub/climate.py +++ b/homeassistant/components/geniushub/climate.py @@ -3,6 +3,9 @@ from typing import List, Optional from homeassistant.components.climate import ClimateDevice from homeassistant.components.climate.const import ( + CURRENT_HVAC_HEAT, + CURRENT_HVAC_IDLE, + CURRENT_HVAC_OFF, HVAC_MODE_HEAT, HVAC_MODE_OFF, PRESET_ACTIVITY, @@ -68,6 +71,17 @@ class GeniusClimateZone(GeniusZone, ClimateDevice): """Return the list of available hvac operation modes.""" return list(HA_HVAC_TO_GH) + @property + def hvac_action(self) -> Optional[str]: + """Return the current running hvac operation if supported.""" + if "_state" in self._zone.data: # only for v3 API + if not self._zone.data["_state"].get("bIsActive"): + return CURRENT_HVAC_OFF + if self._zone.data["_state"].get("bOutRequestHeat"): + return CURRENT_HVAC_HEAT + return CURRENT_HVAC_IDLE + return None + @property def preset_mode(self) -> Optional[str]: """Return the current preset mode, e.g., home, away, temp."""