Problem lua with selector switch Toon
Posted: Thursday 16 November 2017 11:13
Hi,
I have a selector switch of my thermostat, i made a auto program switch containing No, Yes and Temporary.
This is based on the thermostat setpoint. So when the thermostat is following the program it is set to Yes and if i adjust the temp outside the program the selector goes to temporary. Now i want this temporary switch go back to Yes after 30 minutes so i created a new lua.
This doesnt work, does anybody know what im doing wrong? (the 10 sec is just for the test)
I have a selector switch of my thermostat, i made a auto program switch containing No, Yes and Temporary.
This is based on the thermostat setpoint. So when the thermostat is following the program it is set to Yes and if i adjust the temp outside the program the selector goes to temporary. Now i want this temporary switch go back to Yes after 30 minutes so i created a new lua.
Code: Select all
commandArray = {}
-- Command Selector Switch
if (otherdevices['Toon Auto Program'] == 'Set Level: 30')then
commandArray['Toon Auto Program']='Set Level: 20 AFTER 10' -- seconds
print('Toon loopt weer via het programma')
commandArray['SendNotification']='Toon loopt weer via het programma'
end