aqara wall switch selector switch
Moderator: leecollings
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
aqara wall switch selector switch
Hi!
i have an Aqara zigbee wireless wall switch with 2 buttons, in domoticz it shows an an selector switch, in the device manager it shows as only one switch, my plan was to use this aqara switch to control 2 diferent lights but with only one selector switch in domoticz i really dont know how i can use it in blocky.
do you have any suggestions?
i have an Aqara zigbee wireless wall switch with 2 buttons, in domoticz it shows an an selector switch, in the device manager it shows as only one switch, my plan was to use this aqara switch to control 2 diferent lights but with only one selector switch in domoticz i really dont know how i can use it in blocky.
do you have any suggestions?
-
- Posts: 99
- Joined: Monday 17 August 2015 23:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Hi
Aqara wall swich uses 4 states; off, switch 1, switch 2, BothClick
I dont use blocky but dzevents. the script looks something like this:
Hopes this helps
Greets Gijs (noob but trying to contribute to the community)
Aqara wall swich uses 4 states; off, switch 1, switch 2, BothClick
I dont use blocky but dzevents. the script looks something like this:
Code: Select all
return {
on = {
devices = {
'wallswitch'
}
},
execute = function(domoticz, switch)
if (switch.state == 'Switch 2') then
domoticz.devices('lamp').toggleSwitch()
end
end
}
Greets Gijs (noob but trying to contribute to the community)
Raspberry Pi3, RFlink, PiZigate, Yeelight, klikaanklikuit, Kodi, harmony hub, Zwave, ThermoSmart, XiaomiGateway (Aqara), Google home hub, roomba,
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
thanks, but i dont use script, i really dont know how to use it, im stuck with blocky, is it possible to do all in blocky?
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
Hi Tjabas,
This is an example of a blocky with using a selector switch. I hope this is what you are searching for.
Just place a variable in domosettings --> uservariables.
this is the xml to import it:
This is an example of a blocky with using a selector switch. I hope this is what you are searching for.
Just place a variable in domosettings --> uservariables.
this is the xml to import it:
- Attachments
-
- blockly.JPG (73.75 KiB) Viewed 4131 times
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Thank you, that is exactly what im looking for
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
You're welcome, if I can save you the research time it is great.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
sorry but i didnt have any luck with this blocky, i made an user variable, like this: 6 toggle switch String [0,1,2] 2019-08-30 23:08:28
i dont know if its right.
but i cant seem to understand where i should ad the light buld that i want to turn on by this aqara switch. in blocky i mean
i dont know if its right.
but i cant seem to understand where i should ad the light buld that i want to turn on by this aqara switch. in blocky i mean
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
You have to replace the url part with the light name and add status on or of.
You can use json url to dim a bulb.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
You can use json url to dim a bulb.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
i found this: http://127.0.0.1:8080/json.htm?type=com ... cmd=Toggle
works great , thank you all for the help
works great , thank you all for the help
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
Yes indeed, did not know about the json toggle version. Thanks for sharing. But nowadays I start dzvents which has a toggling option in it.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
-
- Posts: 1
- Joined: Sunday 27 December 2020 14:31
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Thanks for the xml! I was looking for a way to use the aqara switch as a dimmer. Is this the right blocky script to do this?gerbenvanasselt wrote: ↑Friday 30 August 2019 22:10 This is an example of a blocky with using a selector switch. I hope this is what you are searching for.
Just place a variable in domosettings --> uservariables.
this is the xml to import it:
Blocklyxml.txt
I don't get the togglecount though... where do you use this for? This is not a value in my domoticz? Do I need something to do first in order to get this?
Thanks in advance!
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
The toggle count is used for creating a circle which will take it off state when highest number is reached.
This way you can use one button to do more actions. Every toggle count number is another action with one button.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
This way you can use one button to do more actions. Every toggle count number is another action with one button.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
-
- Posts: 564
- Joined: Sunday 11 December 2016 13:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
can i use this switch to dim up or down a light?
-
- Posts: 74
- Joined: Friday 07 September 2018 14:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta 4.1
- Location: Netherlands
- Contact:
Re: aqara wall switch selector switch
I think you can do a cycle with dimming from minimal bright to bright in the number off steps you want and then ending with off.
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
Verstuurd vanaf mijn ONEPLUS A6003 met Tapatalk
-
- Posts: 13
- Joined: Thursday 17 February 2022 0:48
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Hello,
Sorry to dig this, but I'm facing an issue with my dual wallswitch Aqara model WXKG02LM.
I'm on rPi4 + ZigateDin.
When I add the switch, it's defined as a selector with switch 1, switch 2, BothClick. Off is hidden by default.
The problem I'm facing is that the switch stay un position.
So when I click on left (Switch 1), it stays on Left even if I release. That mean the blockly script given upper is rolling in infinte loop because the Switch value is always equal to the last button you push.
Do you know I can "park" the switch value when not pressing?
EDIT: physically, the switch is not broken, the blue light is off when I release and is blue when I press, so I believe it's only on domoticz side, or Zigate plugin side maybe?
Sorry to dig this, but I'm facing an issue with my dual wallswitch Aqara model WXKG02LM.
I'm on rPi4 + ZigateDin.
When I add the switch, it's defined as a selector with switch 1, switch 2, BothClick. Off is hidden by default.
The problem I'm facing is that the switch stay un position.
So when I click on left (Switch 1), it stays on Left even if I release. That mean the blockly script given upper is rolling in infinte loop because the Switch value is always equal to the last button you push.
Do you know I can "park" the switch value when not pressing?
EDIT: physically, the switch is not broken, the blue light is off when I release and is blue when I press, so I believe it's only on domoticz side, or Zigate plugin side maybe?
- waltervl
- Posts: 5149
- Joined: Monday 28 January 2019 18:48
- Target OS: Linux
- Domoticz version: 2024.7
- Location: NL
- Contact:
Re: aqara wall switch selector switch
In zigate there is a advanced setting about the off value related to Domoticz issue #4143. You can try to switch on the setting and restart plugin.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
-
- Posts: 13
- Joined: Thursday 17 February 2022 0:48
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Hello!
That still doesn't work, the selector stays on "Switch 1" for like 2-4 seconds, and during this time, the light blink because there are 2 actions on the button: on and off
That still doesn't work, the selector stays on "Switch 1" for like 2-4 seconds, and during this time, the light blink because there are 2 actions on the button: on and off
-
- Posts: 13
- Joined: Thursday 17 February 2022 0:48
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: aqara wall switch selector switch
Nevermind...
A simple "http://IP_DOMO:PORT_DOMO/json.htm?type=command¶m=switchlight&idx=IDX_OF_LIGHT&switchcmd=Toggle" did the trick.
Now each of my switch on my 2 gangs Aqara work like and old fashioned dual light switch and that's exactly what I wanted
If light is off, a push put light on, and vice versa
A simple "http://IP_DOMO:PORT_DOMO/json.htm?type=command¶m=switchlight&idx=IDX_OF_LIGHT&switchcmd=Toggle" did the trick.
Now each of my switch on my 2 gangs Aqara work like and old fashioned dual light switch and that's exactly what I wanted
If light is off, a push put light on, and vice versa
Who is online
Users browsing this forum: No registered users and 1 guest