If we’ve met recently you probably already know about my obsession of home automation. If not, just be aware that last Christmas I started to integrate all my smart devices using Home Assistant. I’ve planed to write a post here about my journey but I didn’t manage to do so yet and at this stage I don’t believe I’ll ever do so. On the other hand I would like to put back something to the great community around Home Assistant, so here is this blog post.
Disclaimer: This how-to is provided as is. Use it at your own responsibility.
Based on the Hörmann documentation you can use pins
21 for external switch.
Here is where you can find those in the box.
These two are the ones which will be connected to Shelly’s
O ports. Also you need to connect Shelly1 to some juice. For this purpose you can use pins
5 (+) and
20 (-) which provide 24V. These goes to as follows:
The final wiring should look like this.
Eventually, I used both side adhesive tape and placed Shelly1 on the other side of the electric board next to the engine.
In Home Assistant I use custom integration called Shelly for HASS. After connecting Shelly1 to Wifi, it is automatically discovered and added to Home Assistant. You can use pretty much default configuration in terms of the Shelly1 itself, just make sure that the BUTTON TYPE is configured as Toggle Switch.
Next identify your new Shelly1 device in Home Assistant.
And finally you can start with the automation. I use this script to emulate toggle button. It turns on the switch and then turns it off after 2 seconds.
# Trigger Shelly1 for 2s to open the gate open_gate: alias: Open Gate sequence: - service: switch.turn_on data: entity_id: switch.shelly_shsw_1_98cdac24a80e - delay: seconds: 2 - service: switch.turn_off data: entity_id: switch.shelly_shsw_1_98cdac24a80e
At this moment I’m waiting for Aqara Door Window Sensor, which I’ll use for detection of state (Open/Closed) of the gate. Alternatively, you can use some magnetic switch and connect it to Shelly1 directly.
My use-cases are:
- Automatic gate opening when I arrive home,
- Opening the gate remotely for any case of delivery when I’m not at home,
- Be able to see the status of the gate (using Aqara sensor).
In my case the gate closes automatically after some short period of time (timeout depends on whether the motion through the gate has been detected) so I use this integration only for opening.
Hope you found this one useful.