My desk setup is in the basement, positioned such that I can’t tell when someone comes downstairs. It’s a bit unpleasant for both parties. I get startled, and whoever is trying to get my attention has to hover awkwardly until I notice them. So I wanted something to inform me when someone is on their way down.

I’ve fallen in love with ESP32 boards for these types of projects. They’ve got built-in wifi and easy I/O while still being low power and compact. They’re so standard at this point that I’ve learned recently that most 3d printers are running variants of them too. I’ve also bought a few robotics kits over the years, so I dug through them to see what I had on hand. There was an ultrasound sensor that measures the distance of objects, so I played around with that to see if I could reliably detect someone walking down the stairs. Once I felt like that was dialed in, I needed to figure out how to actually notify me. So I wrote a simple sketch that connects to the wifi, measures the sensor data on a loop, and fires off a http request when the sensor sees motion. I also baked in a little cool down, otherwise it might go completely haywire since the sensor loop runs really fast.

At this point I could probably just wire up a push notification to my desktop, or my phone, but I wanted to have a bit more fun with it! I already have Home Assistant running, and it is able to easily receive webhooks, and I also have Hue lights for my office space. So I threw together a quick automation that briefly flashes my office lights when the webhook fires.

For awhile I just left the dev board and loose wires sitting on the floor since it was a prototype and I wasn’t sure if we’d really enjoy it. But now that it’s been in use for awhile, I decided to pretty it up just a little. I found an existing ESP32 enclosure and a hinge mount for the sonar sensor, and Frankensteined them together in TinkerCAD to make this little guy.

I’m pretty happy with it! I’d love to find a better way to hide the wires and add some weight so it’s less top-heavy, but I’m also considering a magnetic mount plate on the wall, so it might not be worth iterating on right now. A ball joint mount might work better too, so it can sit at exactly the angle I want.

Light Doorbell Device

Here’s a silly little home video of my demoing the original prototype. Enjoy!