Hi!
I am able to open and close my garage door with the shelly device and I would like to couple it with a Z-wave door sensor to detect the state of the garage door.
I’ve comb through the forums and it has been suggested I look into cover templates. I however cannot get it to toggle the garage with the cover template. Any suggestions?
Here is the code in my configuration.yaml:
cover:
- platform: template
covers:
garage_door:
friendly_name: "Garage Door"
value_template: "{{ is_states('binary_sensor.garage_door_sensor', 'on') }}"
open_cover:
service: switch.toggle
data:
entity_id: switch.shelly1_e8db84d72d28
close_cover:
service: switch.toggle
data:
entity_id: switch.shelly1_e8db84d72d28
icon_template: >-
{% if is_states('binary_sensor.garage_door_sensor', 'on') %}
mdi:garage-open
{% else %}
mdi:garage
{% endif %}
Thanks!