Code: Select all
2019-06-28 15:56:32.024 Error: dzVents: Error: (2.4.23) error loading module 'habridge' from file '/usr/local/domoticz/var/scripts/dzVents/generated_scripts/habridge.lua':
2019-06-28 15:56:32.024 ...oticz/var/scripts/dzVents/generated_scripts/habridge.lua:22: ')' expected near '{'
i really ccan not see where the problem lies
Code: Select all
return {
active = true,
on = {
-- de devices die dit script triggeren
devices = {
'Vitrinekast',
'Plafondspots'
}
},
execute = function(domoticz, device)
local devicename = device.name
local devicestatus = device.state
local devicelevel = device.level
if devicestatus == 'On' then devicestatus ='true'
end
if devicestatus == 'Off' then devicestatus ='false'
end
if (devicename == 'Vitrinekast') then
os.execute('curl -X PUT -d '{"on": true}' "http://192.168.1.50:8082/api/8d84b9c378c94dd6afbf0180b73ecba9/lights/106/bridgeupdatestate"')
end
end
}also when i comment out the os.execute rule the script does not generate errors
Code: Select all
root@DISKSTATION:~# curl -X PUT -d '{"on": true}' http://192.168.1.50:8082/api/8d84b9c378c94dd6afbf0180b73ecba9/lights/106/bridgeupdatestate
[{"success":{"/lights/106/state/on":true}}]root@DISKSTATION:~#