Not sure if this should be here or in the Python section......
Little snippet of code I wrote that had me baffled for ages due to case of True and False on Indigo Timers.
Why does the Indigo Timer Device need to be True (as opposed to true) when the states output show all the bool states as false or true (lower case) but to test it needs to be True (Upper case)?
states : States : (dict)
longStatusString : inactive (string)
timeLeftDays : 0 (integer)
timeLeftHours : 0 (string)
timeLeftMinutes : 0 (string)
timeLeftSeconds : 0 (string)
timerStartValueSeconds : 14400 (string)
timerStatus : inactive (string)
timerStatus.active : false (bool)
timerStatus.inactive : true (bool)
timerStatus.paused : false (bool)
varDrier3 = indigo.variables[983248758] # "varDrier3"
dev4HrTimer = indigo.devices[871078152] # "Bedroom 3 Drier 4 Hour Timer"
if varDrier3.value == "true" and (unicode(dev4HrTimer.states["timerStatus.inactive"])) == "True":
indigo.server.log("true and True")
indigo.server.log(str(varDrier3.value))
indigo.server.log(unicode(dev4HrTimer.states["timerStatus.active"]))
else:
indigo.server.log("not true")
indigo.server.log(str(varDrier3.value))
indigo.server.log(unicode(dev4HrTimer.states["timerStatus.active"]))