Hello,
I configured two template covers. One for the garage and one for the driveway gate. But I have the same issue with both. The UI does not toggle to the open state. Only close and stop buttons stay active.
cover:
- platform: template
covers:
# Garage Door Cover
garage_door:
device_class: garage
friendly_name: "Garage Door"
value_template: "{{ states('binary_sensor.garage_door_closed') }}"
open_cover:
- condition: state
entity_id: binary_sensor.garage_door_closed
state: "off"
- service: switch.turn_on
target:
entity_id: switch.shelly1_garagedoor
close_cover:
- condition: state
entity_id: binary_sensor.garage_door_closed
state: "on"
- service: switch.turn_on
target:
entity_id: switch.shelly1_garagedoor
stop_cover:
service: switch.turn_on
target:
entity_id: switch.garage_door
icon_template: >-
{% if is_state('binary_sensor.garage_door_closed', 'on') %}
mdi:garage-open
{% else %}
mdi:garage
{% endif %}
# Driveway Gate Cover
driveway_gate:
device_class: gate
friendly_name: "Driveway Gate"
value_template: "{{ states('binary_sensor.mqtt_driveway_gate_sensor_right') }}"
open_cover:
- condition: state
entity_id: binary_sensor.mqtt_driveway_gate_sensor_right
state: "off"
- service: switch.turn_on
target:
entity_id: switch.shelly1_drivewaygate
close_cover:
- condition: state
entity_id: binary_sensor.mqtt_driveway_gate_sensor_right
state: "on"
- service: switch.turn_on
target:
entity_id: switch.shelly1_drivewaygate
stop_cover:
service: switch.turn_on
target:
entity_id: switch.shelly1_drivewaygate
icon_template: >-
{% if is_state('binary_sensor.mqtt_driveway_gate_sensor_right', 'on') %}
mdi:gate-open
{% else %}
mdi:gate
{% endif %}