SANdood/Ecobee-Suite

Hubitat Thermostat template - sending incorrect data - work around...

Closed this issue · 2 comments

if (value == "fanOn" || value == "on" ) { value = 'on'; setValue = "on" }

Found that the Hubitat Thermostat tile is sending

setThermostatFanMode( on)

Note the 'space' character in front of 'on' ---> causing a failure to set the ecobee fan modes and throwing an error.

Starting at L2939, you have a work-around for other misbehaving calls to setThermostatFanMode(). I have tested on my Hubitat by adding an additional || condition to look for the " on" string. It fixes the badly behaving call...

if (value == "fanOn" || value == "on" || value == " on") { value = "on" }

I suggest adding this condition (with the leading space character) as part of each 'if' statement L2939-L2942...

Thanks. I'm going to fix it in a different manner to cover both fanMode and thermostatMode, just in case this occurs elsewhere. I'm just going to insert value = value.trim() before the checks at L2939, and in a similar location in setThermostatMode() up above it.

I expect to post later today - after my chores :)

Fixed in 1.8.16, but in a different manner (as noted above).