feat(doorbell): update pins and toggle chime
This commit is contained in:
parent
4f0e9967a0
commit
2a0ce732dd
1 changed files with 10 additions and 13 deletions
|
@ -8,6 +8,7 @@ esp32:
|
||||||
|
|
||||||
# Enable Home Assistant API
|
# Enable Home Assistant API
|
||||||
api:
|
api:
|
||||||
|
logger:
|
||||||
|
|
||||||
ota:
|
ota:
|
||||||
- platform: esphome
|
- platform: esphome
|
||||||
|
@ -21,7 +22,7 @@ binary_sensor:
|
||||||
- platform: gpio
|
- platform: gpio
|
||||||
id: button
|
id: button
|
||||||
pin:
|
pin:
|
||||||
number: 15
|
number: GPIO15
|
||||||
mode:
|
mode:
|
||||||
input: True
|
input: True
|
||||||
pulldown: True
|
pulldown: True
|
||||||
|
@ -30,27 +31,23 @@ binary_sensor:
|
||||||
- delayed_off: 10ms
|
- delayed_off: 10ms
|
||||||
on_press:
|
on_press:
|
||||||
then:
|
then:
|
||||||
- light.turn_on:
|
- output.turn_on: relay_chime
|
||||||
id: ring
|
on_release:
|
||||||
red: 0
|
then:
|
||||||
green: 0.5
|
- output.turn_off: relay_chime
|
||||||
blue: 1
|
|
||||||
effect: pulse
|
|
||||||
- delay: 5s
|
|
||||||
- light.turn_off: ring
|
|
||||||
|
|
||||||
output:
|
output:
|
||||||
- platform: ledc
|
- platform: ledc
|
||||||
pin: 2
|
pin: GPIO2
|
||||||
id: led_red
|
id: led_red
|
||||||
- platform: ledc
|
- platform: ledc
|
||||||
pin: 4
|
pin: GPIO4
|
||||||
id: led_green
|
id: led_green
|
||||||
- platform: ledc
|
- platform: ledc
|
||||||
pin: 16
|
pin: GPIO16
|
||||||
id: led_blue
|
id: led_blue
|
||||||
- platform: gpio
|
- platform: gpio
|
||||||
pin: 32
|
pin: GPIO12
|
||||||
id: relay_chime
|
id: relay_chime
|
||||||
|
|
||||||
light:
|
light:
|
||||||
|
|
Loading…
Add table
Reference in a new issue