Browse Source

Hysen thermostat: take hvac_mode into account for heating state.

It seems the device itself continues to indicate true for the work_state
even when switched off and the heater cannot possibly be working.  This means
we need to take hvac_mode into account for both states of hvac_action.

Issue #298
Jason Rumney 3 years ago
parent
commit
a7804c6af5

+ 6 - 0
custom_components/tuya_local/devices/hysen_hy08we2_thermostat.yaml

@@ -57,6 +57,12 @@ primary_entity:
       name: hvac_action
       mapping:
         - dps_val: true
+          constraint: hvac_mode
+          conditions:
+            - dps_val: false
+              value: off
+            - dps_val: true
+              value: idle
           value: heating
         - dps_val: false
           constraint: hvac_mode