Hi all - I have a sectional garage door, that I’m currently automating with a relay to trigger button press on the garage door motor, and a simple reed switch for open/closed state, using esphome on a Wemos D1 mini.
Lately, I’ve been thinking about finding/building a door position sensor, instead of the reed switch.
If I had position data being sent reliably, I could very easily determine if the door is opening, as well as open/close state. I have a number of automations in mind that would benefit from such data.
So far, my searches for “garage door position sensor”, and variations thereof, aren’t bearing much fruit. I’ve been pondering of couple of home-brewed approaches:
-
A series of reed switches on a track that a magnet on the door will trip as it moves along.
I guess it’s theoretically doable, but they’d have to be sensitive enough to be tripped by a moving magnet, but not so sensitive that too many of them are tripped at the same time, which might confuse my “moving mathematics” to determine door movement direction.
-
An ultrasonic sensor could possibly do the job.
I’m mulling over exact placement of it so it has a reliable surface to reflect off, to give me an accurate read on position. Nothing (yet) comes to mind on that front.
It’s not that I wouldn’t enjoy going down the very enjoyable rabbit hole of prototyping something, but I thought I’d just ask first.
Is anyone aware of an off-the shelf sensor that might give me what I’m looking for, please? If it needs something beefier than an ESP board, I’ve got a couple of RasPis lying around doing nothing.
Cheers in advance for any suggestions.
I’ve been thinking about this recently too!
I kind of have a very crude version of this, by simply mounting my garage door tilt sensor as high up on the door as I could. Since it would go horizontal along with the very first section of the door, it triggers as soon as the door is open about 1/5 of the way.
Response isn’t very fast, though, so if I wanted more precise control I was thinking about building 3 ESP distance/ultrasonic sensors mounted to the ceiling pointed downwards, one at the end of the track, one about 1/4 of the way from the end of the track, and one at the start (where the top of the door stops when it’s completely open).
So the sensors would detect in order of sensors triggered, “closed -> cracked -> slightly open/ing -> open”.
Tracking the previous state of the door in a variable would let me know the direction the door is moving as the sensors get triggered too.
That’s sorta where I was thinking with the ultrasonic sensor, but the other comment here has me thinking about a hall effect sensor now.
Cool, I’ve never used hall effect sensors but I’ll look into them too. Let us know how it works 😁