mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-11 11:26:50 +00:00
Adds Xiaomi double button click example (#4468)
* added example for smart button double click * added example for smart button double click
This commit is contained in:
parent
779538064b
commit
4fe223e922
@ -222,6 +222,25 @@ This example plays the sound of a dog barking when the button is held down and s
|
|||||||
gw_mac: xxxxxxxxxxxx
|
gw_mac: xxxxxxxxxxxx
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### {% linkable_title Double Click on Smart Button %}
|
||||||
|
|
||||||
|
This example toggles the living room lamp on a double click of the button.
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
- alias: Double Click to toggle living room lamp
|
||||||
|
trigger:
|
||||||
|
platform: event
|
||||||
|
event_type: click
|
||||||
|
event_data:
|
||||||
|
entity_id: binary_sensor.switch_158d000xxxxxc2
|
||||||
|
click_type: double
|
||||||
|
action:
|
||||||
|
service: light.toggle
|
||||||
|
data:
|
||||||
|
entity_id: light.living_room_lamp
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
## {% linkable_title Troubleshooting %}
|
## {% linkable_title Troubleshooting %}
|
||||||
|
|
||||||
### {% linkable_title Initial setup problem %}
|
### {% linkable_title Initial setup problem %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user