diff --git a/devicetypes/stelpro/stelpro-ki-zigbee-thermostat.src/stelpro-ki-zigbee-thermostat.groovy b/devicetypes/stelpro/stelpro-ki-zigbee-thermostat.src/stelpro-ki-zigbee-thermostat.groovy index d5b4b1b4635..551ef5546e6 100644 --- a/devicetypes/stelpro/stelpro-ki-zigbee-thermostat.src/stelpro-ki-zigbee-thermostat.groovy +++ b/devicetypes/stelpro/stelpro-ki-zigbee-thermostat.src/stelpro-ki-zigbee-thermostat.groovy @@ -418,7 +418,7 @@ def validateOperatingStateBugfix(map) { if (state.rawSetpoint != null && state.rawTemp != null) { def oldVal = map.value - if (state.rawSetpoint <= state.rawTemp) { + if (state.rawSetpoint <= state.rawTemp || device.currentValue("thermostatMode") == "off") { map.value = "idle" } else { map.value = "heating" @@ -429,6 +429,7 @@ def validateOperatingStateBugfix(map) { map.data = [correctedValue: true] } } + map }