Add door opener button

This commit is contained in:
Jakob Lechner 2024-06-23 23:18:26 +02:00
parent 8b83a6a1ef
commit f187754465

View file

@ -44,6 +44,10 @@ output:
output: true
open_drain: true
id: btn_lock
- platform: gpio
pin:
number: GPIO3
id: btn_open
lock:
- platform: template
@ -62,3 +66,14 @@ lock:
- output.turn_off: btn_unlock
- delay: 5s
- lambda: id(tuerschloss).publish_state(LOCK_STATE_UNLOCKED);
button:
- platform: template
name: "Türöffner"
id: tueroeffner
icon: mdi:lock-open
on_press:
- logger.log: "Button pressed"
- output.turn_on: btn_open
- delay: 250ms
- output.turn_off: btn_open