Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aqara Smart Light Control #1

Open
RiRomain opened this issue Jan 12, 2018 · 7 comments
Open

Aqara Smart Light Control #1

RiRomain opened this issue Jan 12, 2018 · 7 comments

Comments

@RiRomain
Copy link

To help development, here are the log from the Aqara Smart Light Control (wall switch)

The log are watch is received when I press the key. My switch are the one with the integrated relay, so when I press the button, the light are also turned ON or OFF.

Turn left switch OFF
Turn left switch ON
Turn right switch Off.txt
Turn right switch On.txt

@ISO-B
Copy link
Collaborator

ISO-B commented Jan 12, 2018

That wall switch has lots of endpoints. All my devices only have 1. This is interesting. It seems that both buttons have two endpoints: one providing button state and other to tell that button is pressed.

Could you provide more data? I copied address from logs, so if commands are not working make sure device still has same address.

z.send_data('0042', '3BCF') Node Descriptor (lots of device info)
z.send_data('0043', '3BCF01') Cluster List from endpoint 01 (Common)
z.send_data('0043', '3BCF02') Cluster List from endpoint 02 (Left button: State)
z.send_data('0043', '3BCF03') Cluster List from endpoint 03 (Right button: State)
z.send_data('0043', '3BCF04') Cluster List from endpoint 04 (Left button: Press)
z.send_data('0043', '3BCF05') Cluster List from endpoint 05 (Right button: Press)
z.send_data('0044', '3BCF') Power info
z.send_data('0045', '3BCF') Endpoint listing

@RiRomain
Copy link
Author

RiRomain commented Jan 12, 2018

@ISO-B
Copy link
Collaborator

ISO-B commented Jan 12, 2018

Does these commands do same as pressing left button? With these you should be able to set state to desired.
Left button on: z.send_data('0092', '023BCF010201')
Left button off: z.send_data('0092', '023BCF010200')

Try this if command above didn't do the trick. Running both of these should simulate button press.
Left button pressed down: z.send_data('0092', '023BCF010400')
Left button released: z.send_data('0092', '023BCF010401')

@RiRomain
Copy link
Author

RiRomain commented Jan 12, 2018

Yes, working perfectly with the first command, here are the log of the left switch being turned on and turned off:

Turn_Off_Left_Light.txt
Turn_On_Left_Light.txt

@ISO-B
Copy link
Collaborator

ISO-B commented Jan 12, 2018

Only thing that I am not sure about is attribute id f000 in cluster 0006 in endpoints 02 and 03. It might tell if switch happened by using button or from network. When attribute data is 03030303 it was triggered by button and 07070707 it is triggered by network. Should be easy to confirm by switching it couple times with hand and command and see if attribute id is consistently same.

@RiRomain
Copy link
Author

I tested your theory several time and I can confirm that it is correct.

03030303 when the button is used.
07070707 when ZigBee is used

@biau
Copy link

biau commented May 10, 2018

Is there someone to give me a hint how to replicate the state value in home assistant when I manually turn ON / OFF the switch ?
First I do not have the same endpoint as RiRomain, on my double key wall switch with fireline to turn on / off lights from HA I use endpoint 01 and 02.
I attach logs turning ON / OFF the light using both methods: HA and the switch.
turn_on_ha.log
turn_off_ha.log
turn_on_wall.log
turn_off_wall.log

My config is

switch:
  - platform: zigate
    name: 'Cuisine central'
    address: "84c301"
  - platform: zigate
    name: 'Cuisine table'
    address: "84c302" 

ISO-B pushed a commit that referenced this issue Jun 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants