I like your idea. I think it could be further simplified to something like:
Code: Select all
on = {
devices = {
'Stairs Motion'
}
},
execute = function(dz)
-- Must be the motion sensor...
domoticz.runInMins(5, function(dz)
-- Execute my 5 minute tasks
)
domoticz.runInMins(10, function(dz)
-- Execute my 10 minute tasks
)
end