diff --git a/content/blog/2022-01-09_garage-door-opener.rst b/content/blog/2022-01-09_garage-door-opener.rst index 51bc94c..146c27f 100644 --- a/content/blog/2022-01-09_garage-door-opener.rst +++ b/content/blog/2022-01-09_garage-door-opener.rst @@ -26,7 +26,7 @@ I knew I would need some sort of relay (domain purchased from is gone) and `reed Home Assistant has a plugin called ESPHome where you can write yaml files to configure an esp8266 module. This then builds a binary which you need to flash onto the esp8266 at least once via usb. From then on you can then on you can upload from a web form and drop the bin file in manually, or just press the UPLOAD button from ESPHome. I set my relay up on pin 19/D1 for the digital pin, and 16/GND,10/3v3 for the power. The Reed switch I tossed on 15/D7 and 11/GND but that could have been anywhere. See Schematic below. It still doesn't have an enclosure. -.. figure:: https://thumbnails-photos.amazon.com/v1/thumbnail/ipyyo6AWROe1t6_LDvhs-w?viewBox=1742%2C1306&ownerId=A2XF3XCOUKGXAO +.. figure:: {static}/images/2022/01/09_relay.jpg :alt: Relay in blue, and wires going to the NodeMCU Relay in blue, and wires going to the NodeMCU @@ -90,6 +90,22 @@ Once the door was opening and closing, I was able to add more yaml to set anothe All together this is shown on my Home Assistant Lovelace dashboard using two cards, one that shows a closed door, and one with an open door (both actual pictures of the door!) with a button to open it. Once it opens or closes the other card switches into place, Home Assistant at least at the time didn't have good conditional cards like I wanted. +.. code:: yaml + + type: conditional + conditions: + - entity: binary_sensor.garage_door_closed + state: 'on' + card: + type: picture-glance + title: Garage (Closed) + image: 'https://tyrel.dev/house/garage_door.jpeg' + entities: + - entity: switch.garage_remote + hold_action: + action: none + + .. figure:: {static}/images/2022/01/garage-Lovelace_garage_door_closed.png :alt: Closed door state and button @@ -97,6 +113,12 @@ All together this is shown on my Home Assistant Lovelace dashboard using two car Happy with the state of my Garage Door opening button, I can now yell at my phone to open the garage door (it's a "secure" switch so it requires the phone to to be open before OK Google will trigger the door). -There's a couple more pictures in my `Instagram post `__ about it, and another `write up on my wiki. `__ +There's a couple more pictures in my `Instagram post `__ about it. I know I could have bought a device to do this myself, but this is fully mine, my code, and my experiment with learning how to automate things at home, I gained way more out of this project than I did if I just bought a MyQ or what ever is popular these days. + + +Notes +~~~~~ + +This is no longer in service, as I replaced the door and have a Chamberlain MyQ system now. Less fun, but at least it's serviceable. diff --git a/content/images/2022/01/09_relay.jpg b/content/images/2022/01/09_relay.jpg new file mode 100644 index 0000000..fb8ef3c Binary files /dev/null and b/content/images/2022/01/09_relay.jpg differ diff --git a/themes/solarized/static/css/main.css b/themes/solarized/static/css/main.css index be0bee0..db6e3b4 100644 --- a/themes/solarized/static/css/main.css +++ b/themes/solarized/static/css/main.css @@ -227,3 +227,9 @@ ul ul { margin-right:1rem; } + +.caption { + padding-left: 5rem; + font-style: italic; +} +