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

Add a new click_type double_both to improve the support of the new Xi… #19578

Merged
merged 1 commit into from
Dec 26, 2018

Conversation

tedsluis
Copy link
Contributor

@tedsluis tedsluis commented Dec 26, 2018

…aomi aqara Wireless Wall Switch (remote.b286acn01)

Description:

The binary_sensor component for xiaomi_qara does not support a click_type double_both for WXKG02LM, model b286acn01. This pull request will add the double_both.

Not sure how to prepare this pull request (first time for me within this project).
Related issue (if applicable):

https://community.home-assistant.io/t/no-xiaomi-aqara-wireless-switch-long-click-both-double-click-and-both-long-click-support/86746/2

Pull request in home-assistant.io with documentation (if applicable): home-assistant/home-assistant.io#7952

Example entry for configuration.yaml (if applicable):

automation:
  - alias: turn off light
    trigger: 
      platform: event
      event_type: xiaomi_aqara.click
      event_data:
        entity_id: binary_sensor.wall_switch_both_158d00027c19e9
        click_type: double_both
    condition:
      - condition: state
        entity_id: light.gateway_light_7c49ebb18b86
        state: 'on'
    action:
      service: light.turn_off
      entity_id: light.gateway_light_7c49ebb18b86

Checklist:

  • [x ] The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass
  • [x ] There is no commented out code in this PR.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • New dependencies have been added to the REQUIREMENTS variable (example).
  • New dependencies are only imported inside functions that use them (example).
  • New or updated dependencies have been added to requirements_all.txt by running script/gen_requirements_all.py.
  • New files were added to .coveragerc.

If the code does not interact with devices:

  • Tests have been added to verify that the new code works.

@syssi
Copy link
Member

syssi commented Dec 26, 2018

Good catch! Please extended the documentation, too!

@tedsluis
Copy link
Contributor Author

Good catch! Please extended the documentation, too!

I tried to do a pull request for the documentation, but I am not sure whether it is okay:

home-assistant/home-assistant.io#7952

@syssi syssi merged commit 54f6cfd into home-assistant:dev Dec 26, 2018
@ghost ghost removed the in progress label Dec 26, 2018
@tedsluis tedsluis deleted the xiaomi_aqara_double_both_click branch December 27, 2018 07:49
@balloob balloob mentioned this pull request Jan 10, 2019
alandtse pushed a commit to alandtse/home-assistant that referenced this pull request Feb 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants