As per the subject.
I’ve modified Sonoff Basic to be able to control Garage, and configured HA according to https://www.youtube.com/watch?v=QMepwpyjMCY
To make sure of the gate position I used magnetic contacts. However probably I did something wrong as icon shows wrong statuses.
- when gate is closed, (magnetic sensor close each other) icon shows - garage is open
- when gate is open/opening, (magentic sensor no connection) icon shows - garage is closed.
I’m still new in HA, thank you in advance for help
Open status
Closed status
configuration.yaml
cover: - platform: mqtt name: "test" state_topic: "cmnd/2/POWER2" command_topic: "cmnd/sonoffst/POWER" payload_open: "ON" payload_close: "ON" payload_stop: "ON" state_open: "ON" state_closed: "OFF" optomistic: false retain: false
automation.yaml
- action: - delay: 00:00:01 - data: payload: 'OFF' topic: cmnd/sonoffst/POWER service: mqtt.publish alias: Turn off Garage after 1 seconds condition: [] id: '12345678901234' trigger: - payload: 'ON' platform: mqtt topic: cmnd/sonoffst/POWER
customize.yaml
cover.test: device_class: garage friendly_name: Garage
groups.yaml
garage_doors: name: Garage Doors view: no control: hidden icon: mdi:garage entities: - cover.test