Built-in virtual thermostat doesn't handle emergency heat mode

I am using virtual thermostats to test my code. I just noticed that, when the mode is set to emergency heat, the operating state seems to stay as idle, even when the temperature is less than the heating setpoint. This seems to be incorrect. I would have expected the operating state to be set in the same way as in regular heat mode.

For a regular thermostat, the 24V outputs are sometimes set differently in emergency heat mode than in regular heat mode, but that it obviously not applicable to a virtual thermostat.

Will look into this...

1 Like

Thanks. While you are looking at it, please take a look at how virtual thermostat handles fan mode being set to on. With fan mode on, operating state should go to fan only instead of going to idle.

I don't think this is right. Operating state for a thermostat refers to the HVAC system state (heat, cool, Emergency heat, etc.), while thermostatFanMode changes according to the operation of the fan. These are separate in every thermostat that I'm familiar with, and their drivers. There is no operating state of 'fan only'. Some thermostats support an attribute 'thermostatFanState' that reflects whether the fan is on or not, while the thermostatOperatingState remains 'idle' irrespective.

The shortcoming of the Virtual Thermostat driver wrt Emergency Heat has been found and fixed... Next release.

Generic Zigbee Thermostat driver and a Centralite Pearl

Screenshot 2021-04-07 111128

From the Driver Capability List:


Device Selector


Driver Definition

capability "Thermostat"


coolingSetpoint - NUMBER, unit:°F || °C

heatingSetpoint - NUMBER, unit:°F || °C

schedule - JSON_OBJECT (Deprecated)

supportedThermostatFanModes - JSON_OBJECT

supportedThermostatModes - JSON_OBJECT

temperature - NUMBER, unit:°F || °C

thermostatFanMode - ENUM ["on", "circulate", "auto"]

thermostatMode - ENUM ["auto", "off", "heat", "emergency heat", "cool"]

thermostatOperatingState - ENUM ["heating", "pending cool", "pending heat", "vent economizer", "idle", "cooling", "fan only"]

thermostatSetpoint - NUMBER, unit:°F || °C

Note that one of the options for thermostatOperatingState is "fan only". My understanding of when this operating state should be selected is when thermostatMode is set to "on" and no heating or cooling is required. In contrast, when thermostatMode is set to "auto", thermostatOperatingState should be "idle" when no heating or cooling required. Frankly, I'm not sure what "circulate" should do.

OK, will fix this in Virtual Thermostat also. I.e., if fan is either on or circulate, then when not heating or cooling, it will go into "fan only" operating mode.

1 Like

Thank you.

this was never fixed? we need a few more thermostatOperatingState

in the capablities



Yes, it supports emergencyHeat:

Not part of the thermostat capability: Driver Capability List - Hubitat Documentation

yes i know it is supported there (in thermostatMode) but not in the returned operatingstate as the documentation shows.

i get an error when trying to set the operating state to emergencyheating etc.

It would be usefull so we can add alert notifications when the therm actually turns on emergencyheat to check what is going on. Some thems automatically turn on emergencyHeat and return it in the operationstate (*ie t6) when certain cirumstances occur.

and also i know humidifying is not part of it.. but would like it added. thanks

my t6 is returning this and i was trying to write code to handle it (ie modify driver) but there is no corresponding operatingstate in the capability to set it to..

You should still be able to set it to whatever, it doesn't have to be in the capability (although it should be).

1 Like

ok got ya thanks.