I have a probably simple question about sending a URL when a button is pressed. I have read the documentation but I am afraid programming is not my forte and I can't make heads or tails of it. But I do need this so I can fully use my Shelly 2.5 switches (roller shutter mode) with my Zigbee 2-gang switches.
So I hope you will be able to help me.
I have a dzVents script that triggers my roller shutter on the press of a button. This used to work flawlessly with my Zigbee roller shutter device. I have replaced the Zigbee roller shutter device with a Shelly 2.5. The plugin does not support the "stop" command but I have found out I can send a URL request that stops the roller shutter.
Now I am struggling to get the dzVents script to send the url.
The URL looks like this:
Code: Select all
http://192.168.xxx.yyy/roller/0?go=stopCode: Select all
--Control Zigbee roller shutter module QS-ZIGBEE-C01 with additional switch (Aqara WXKG07LM)
return
{
on =
{
devices =
{
'Schakelaar Keuken 2',
},
},
logging =
{
level = domoticz.LOG_DEBUG,
marker = 'roomSwitcher',
},
execute = function(dz, item)
if item.state == '10' or item.state == 'B1' then
dz.devices(396).open()
elseif item.state == '20' or item.state == 'B2' then
dz.devices(396).close()
elseif item.state == '30' or item.state == 'B3'then
dz.devices(396).stop()
-- domoticz.openURL('http://192.168.xxx.yyy/roller/0?go=stop')
end
dz.log(item.state, dz.LOG_DEBUG)
end
}What do I need to change?
Thanks in advance!