I'm very new to domoticz and dzvents.
I have a Fibaro motion sensor and a Fibaro dimmer.
I'm already able to switch the light on and off after motion during nighttime but I would love to set the level of the dimmer with dzVents
(as you would do with a "level xx %" block in blocky), any ideas? I tried several things but nothing is working
Code: Select all
local LichtHal = domoticz.devices('Licht hal')
if (timeofday['Nighttime']) then
if (switch.state == 'On') then
---> LichtHal set level dimmer
LichtHal.switchOn()
else
LichtHal.switchOff()
end
else
LichtHal.switchOff()
end
Luc