Domoticz Timer Script

Here is our Timer script 🙂

————————————-
commandArray = {}
local m = os.date(‘%M’)
–if (m % 1 == 0) then
–print(‘The 1minute script interval reached’)
— Call your function here that shall run every 1 minutes
–end
if (m % 5 == 0) then
–print(‘The 5 minute script interval reached’)
— Call your function here that shall run every 5 minutes
end
if (m % 10 == 0) then
— print(‘The 10 minute script interval reached’)
— Call your function here that shall run every 10 minutes
end
if (m % 30 == 0) then
— print(‘The 30 minute script interval reached’)
— Call your function here that shall run every 30 minutes
end
if (m % 60 == 0) then
— print(‘The 60 minute script interval reached’)
— Put your script code here that shall run every 60 minutes
end
return commandArray