Mattress sensors do kind of sound like a gimmick — in spite of everything, who cares whether or not somebody is occupying the mattress? But when you concentrate on it, that data is kind of helpful from a home automation standpoint. An individual might do all types of issues on this state, from making certain the overhead lights within the room can’t come on, to turning off different smart units which are possible not getting used whereas each occupants are sleeping.
[The Home Automation Guy] presents a few methods of doing this, however each focus on a reasonably cheap pressure-sensing mat.
Within the first methodology, he connects the strain mat as much as a Zigbee Aqara Leak Sensor, which conveniently has two terminals on the again to just accept the wires from the strain sensor. Then he merely connects it as much as a Zigbee-compatible home assistant just like the Aqara Hub.
In barely more durable mode, he forgoes the Aqara Leak Sensor and connects the strain mat as much as an ESP32 utilizing a nifty screw terminal dev board. Then he units up the sensor and all the specified actions in ESPHome. After all, with an ESP32, it’s straightforward so as to add a second strain mat for [Mrs. The Home Automation Guy]’s facet of the mattress.
Now, as soon as they’ve each gone off to mattress, the home goes into night time mode — all of the smart plugs, Sonos units, and different issues are powered down, and the alarm system is put into night time mode. Make sure you take a look at the construct video after the break.