I think there is something wrong, my script does not run, I'm running the latest beta release. I also noticed not all my devices are being refreshed at every start-up, new feature?
return {
on = {
timer = { "every 30 seconds" } -- Test timer trigger
},
logging = {
level = domoticz.LOG_INFO,
marker = "Presence Timer Test"
},
execute = function(dz, item)
if item.isTimer then
dz.log("

TIMER TEST: Presenttest.lua running every 30 seconds!", dz.LOG_STATUS)
-- Check if Presence device exists
local presenceDevice = dz.devices('Presence_at_Home')
if presenceDevice then
dz.log("

PRESENCE: Presence_at_Home device found, state: " .. presenceDevice.state, dz.LOG_STATUS)
else
dz.log("

PRESENCE: Presence_at_Home device NOT found!", dz.LOG_STATUS)
end
end
end
}