Author Topic: test for condition: is ESM mode set to ON (Trane tsat)?  (Read 1649 times)

Offline Intrepid

  • Hero Member
  • *****
  • Posts: 536
  • Karma: +4/-0
test for condition: is ESM mode set to ON (Trane tsat)?
« on: July 22, 2011, 06:41:54 am »
What is the luup code to EXIT a scene if ESM mode is on?

I use ESM for extended times away.  I have a wall outlet controlling a window unit which comes on every night at a set time.  I want to bypass this window unit timer if ESM mode is set to on.

Thanks.


Offline oTi@

  • Community Beta
  • Master Member
  • ******
  • Posts: 4041
  • Karma: +32/-6
  • UI what ?!
Re: test for condition: is ESM mode set to ON (Trane tsat)?
« Reply #1 on: July 22, 2011, 08:15:02 am »
What is the luup code to EXIT a scene if ESM mode is on?

Try this in the Luup tab:
Code: [Select]
return (luup.variable_get("urn:upnp-org:serviceId:SwitchPower1","Status",<devID>) == "1")
The scene will _not_ run (i.e. the commands won't be executed) if the t-stat is in ESM.
Dezwaved at the moment...