My Garage Door Vacation Lock

So I was looking for a way to lock my garage door using home assistant. That way I could lock it remotely when I wanted to or include it in security automations. Mostly to prevent someone from leaving their car unlocked enabling a would be burglar to just reach inside and open the garage door with the opener. I couldn’t find any threads with someone else doing the same thing so I figured I’d figure it out myself. I knew that my garage opener wall switch had a lock slider on it. When in the locked position it causes the motor to ignore all open commands. Effectively disabling it. I just needed a way to do this remotely.

I purchased a sonoff sv and flashed it with tasmoda. Then added it to my HA and configured it as a lock. (See config below) And finally wired it up to the wall switch. Using some 22 awg wire I soldered the dry relay contacts of the sonoff to the “lock” position terminals on the back of the garage switch circuit board. When the relay is engaged, the lockout circuit on the wall switch engages and the door will not open. When the relay is “unlocked” or in the open position the lockout circuit is bypassed and the door operates as normal.

I put the sonoff in a small enclosure with a clear case so I can see the red LED as a visual lock indicator. And I mounted it right next to the garage door switch. I ran a separate line from the ceiling power outlet to the sonoff with 12v dc to power it.

And here’s a snippet of my configuration.yaml for the mqtt lock

  - platform: mqtt
    name: Garage Door Lock
    state_topic: "stat/garage_lock/POWER"
    command_topic: "cmnd/garage_lock/POWER"
    payload_lock: "ON"
    payload_unlock: "OFF"
    optimistic: false
    qos: 1
    retain: true

And finally, my garage door card in lovelace

Hopefully this will help someone else out there who needs to do the same or something similar.