Code: Select all
watts = eg.event.payload
if watts > 1:
eg.TriggerEvent("Great Room TV Power Usage On")
['83.69']
Am I doing something wrong? Should this payload be converted to a number somehow to compare in the script?
Code: Select all
watts = eg.event.payload
if watts > 1:
eg.TriggerEvent("Great Room TV Power Usage On")
Code: Select all
eg.event.payload[0]
Code: Select all
watts = eg.event.payload[0]
watts = float(watts)