Removing faulty onpress/onrelease code from garage.yaml

This commit is contained in:
Jason Williams 2024-04-11 15:55:06 -06:00
parent f1db356421
commit f62e04aef1

View File

@ -63,37 +63,39 @@ binary_sensor:
device_class: door device_class: door
id: garage_door_open id: garage_door_open
filters: filters:
- invert: - invert
on_press: # on_press:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door).current_operation = COVER_OPERATION_IDLE; # //id(garage_door).current_operation = COVER_OPERATION_IDLE;
id(garage_door).position = COVER_OPEN; # //id(garage_door).position = COVER_OPEN;
id(garage_door_state).publish_state("Open"); # //id(garage_door_state).publish_state("Open");
on_release: # on_release:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door).current_operation = COVER_OPERATION_CLOSING; # //id(garage_door).current_operation = COVER_OPERATION_CLOSING;
id(garage_door).publish_state(); # //id(garage_door).publish_state();
id(garage_door_state).publish_state("Moving"); # //id(garage_door_state).publish_state("Moving");
- platform: gpio - platform: gpio
pin: D1 pin: D1
id: garage_door_closed id: garage_door_closed
filters: filters:
- invert: - invert
internal: true internal: true
on_press: # on_press:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door).current_operation = COVER_OPERATION_IDLE; # //id(garage_door).current_operation = COVER_OPERATION_IDLE;
id(garage_door).position = COVER_CLOSED; # //id(garage_door).position = COVER_CLOSED;
id(garage_door_state).publish_state("Closed"); # //id(garage_door_state).publish_state("Closed");
on_release: # on_release:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door).current_operation = COVER_OPERATION_OPENING; # //id(garage_door).current_operation = COVER_OPERATION_OPENING;
id(garage_door).publish_state(); # //id(garage_door).publish_state();
id(garage_door_state).publish_state("Moving"); # //id(garage_door_state).publish_state("Moving");
- platform: gpio - platform: gpio
pin: D2 pin: D2
name: "Side Door" name: "Side Door"