I have a Sonoff mini flash firmware Tasmota. For which I separated the relay from Switch1. When I connect S1 and S2, the relay does not respond but the mini sends me the status of S1 and S2 to HA
and restart Home assistant.
Then add in your front end GUI, a card that will implement the binary sensor with as entity name: binary_sensor.garage_door_switch
The code in the lovelace configuration file should look like this:
You can change the names as you please and select other options for displaying the sensor (icon, color, text, …)
I have simulated it using the MQTT configuration menu which allow to send test messages
If the Sonoff device is flashed with Tasmota, have you considered using the Tasmota integration? It will automatically create all entities needed to represent the device.
unfortunately this binary_sensor does not respond to the s1xs2 state. We are certainly able to change its sending status of configured messages. But not by the physical conductive connection of S1 and S2. I have also studied this mqtt binary_sensor in the documentation. Unsuccessfully.
I have an automation that can respond properly and switch boolean based on the S1xS2 I status.
Its basis is as follows:
I use both integrations. In this case, I didn’t try the Switch1 integration in Tasmota.
Thank you for pointing it out.
This is where the status of switch ON and OFF…
Thank you