Anyone try to build a bed occupancy sensor integrated with Home Assistant? I've looked into load sensors but all of them seem to have pretty small weight limits (low enough to where I don't think it would even support the empty bed).
What devices/sensors have you used for this? And what does your setup look like?
Couldn't find the exact one I ordered a few months ago, but this type of pressure sensor aliexpress link is apparently a common bed occupancy sensor type used when building medical beds for hospitals and care homes so staff can be alerted when a patient gets out of bed. I'm not sure the specific model I linked is quite right specs-wise, but the idea is that it goes on a slat or other surface between the matress and the frame that doesn't necessarily get the full weight of the occupant, but still gets enough to measure on the sensor.
Turn off the lights when 2 people in bed. Turn the lights on really low when only 1 person gets up. Track time you went to bed / time in bed as a low-budget sleep tracker not tied to a big data broker, like a smart watch would be....
@just_another_person Turning on or off nightlights. Changing iOS focus (e.g., sleeping). Activating outside security monitoring… all kinds of interesting use cases.
If I'm in the bedroom, I may want my ceiling lights on if someone is in there if it's dark outside, but if my wife and I are in bed, then only turn on the baseboard lights, at 1% brightness when someone is still in bed. Presence sensors aren't that fine grained, and I certainly don't want to wake up my wife when this old fart gets up to go pee again. She's grumpy when awakened. 🤣
I don’t have one myself, but several of the guys on YouTube use them. See “The Home Automation Guy” or “Smart Home Solver“. I can’t remember the brand they use.
I’ve got this setup: Two of those flat contact sensors that are designed to go under a mat, connected to an ESP32 running ESP Home. Some people use leak sensors with screw terminals instead of the ESP32 and attach the contact sensor that way.
My use case is that we’ve got cats and motion sensors, so when everyone is in bed, the lights don’t react to the motion. Also, alarm system goes into night mode, any reminders before going to bed also fire. There are a set of rules about whether the doorbell can be heard in the bedroom, and also the light comes on in the night if someone gets up.
I have an Aqara FP-2 doing just this thing. It works pretty well after setting up zones. Those get pulled into Home Assistant and then you can tie those to automations to control lamps or what have you.
I built one with an esp32 and some tin foil and foam. link to guide. If you go this route read through this whole thread for improvements to the final product.
I've never done anything like this, but would it be possible to place such a sensor between the mattress and the frame instead? That would result in a fraction of the load due to the distribution of the weight. The challenge would be to set the threshold right.
@bus_factor Some of the #mmWave (Radar) Presence sensors may be able to detect bed presence through the mattress, mounted under frame. I have not tried this yet but I’ve been planning to. The Aqara FP-1 or Aqara FP-2 are candidates, but maybe too pricey for an experiment. The Apollo MTR-1 is far less expensive and excellent for short range. It is also small and with a sturdy enclosure you could easily place it between and mattress. These sensors can pick up very small motions, even the human heartbeat (sometimes through walls). I use both Aqara (easier set up) and Apollo MTR-1 for room and zone presence detection, with #HomeAssistant for integrated automation.
I believe that's how most people do it. It works for me. You can also put two in parallel or just add a resistor across the leads to divide the resistance to make it more sensitive. If you used a potentiometer it would make it easier to adjust to hit the exact threshold.
Use car occupancy sensors and an esp board. That's what I did. I stuck them to corregated cardboard and put one under each side. Aim for the butt area as that seems to apply the most pressure. I would order 4. 2 for each side because you can put them in parallel to divide the resistance and make them easier to trigger.
I'm a bit late to the conversation here, but I bought four of these car seat occupancy sensors - https://www.ebay.co.uk/itm/316523892197 - and installed them between the mattresses, one at butt level and the other at shoulder level on both sides of the bed - and connected them to an ESP32 on ESPHome. Works a treat. They're sensitive enough to momentarily disengage if someone rolls over or shuffles about if you need that, otherwise a generous bounce detection allowance smooths it out.