Let's solve occupancy once and for all!

Posted on
Mon Sep 20, 2021 11:23 am
joesan offline
Posts: 98
Joined: Feb 12, 2008

Let's solve occupancy once and for all!

First, the disappointing news - I definitely don't have the answers! But shall we have a brainstorm about what could be done?

The Problem

It seems to me that all attempts to trigger lights etc based on activating a PIR and then messing around with timers etc are doomed to failure. There's just too many situations where it doesn't work well, the timer can go wrong etc. This either results in the lights going off while you're motionless in the room or having the lights stay on too long even when the room becomes unoccupied. Carrying some kind of token, phone or watch etc are okay but not practical for general implementation and probably not rapid-acting enough for general use.

The Solution?

For rooms with a defined entry/exit boundary ie typically a door, it seems to me that the best method is to people count those entering or exiting the room. By maintaining an accurate count of people entering/exiting a room you could truly tell whether a room is occupied or not. Of course for rooms with multiple entry/exit points one would have to link matrix all the counts together to establish a true count. Relatively achievable with software, I'd have thought.

People counting systems are a thing and can be bought off the shelf but they come with a high price tag of 400-500 notes. This does show that this is a solved problem though and the technology and sensors obviously do exist.

Finding the Right Sensor

The real problem I think lies in getting the right sensor. We'd need to trigger on movements into and out of the zone/door boundary. So a dual beam or dual wave sensor is probably necessary to show directionality for entry and exit. PIRs are not really suitable as they lag too much to be accurate. So using two PIRs and then polling them for directional count is probably not accurate enough. It seemed that one company did start making these for the smart home market - http://www.hiome.com - and their web page gives a good idea of how their implementation works including with Homekit. Unfortunately, it seems like they're not responding and they have no stock so perhaps they're no longer in business. A shame as their product looks like it would have been perfect.

Any Ideas?

What do you think? Any ideas for sensors that we could use or possible implementations? If we got this reliably implemented switching logic just got a whole lot simpler and more dependable!

Posted on
Mon Sep 20, 2021 2:49 pm
norcoscia offline
User avatar
Posts: 1206
Joined: Sep 09, 2015

Re: Let's solve occupancy once and for all!

I would be happy if I could just keep the lights on if I’m doing something in a room and don’t move too much, no amount of fussing with timers / motion sensors has solved the issue (let alone of keeping track of who is where). Maybe someone has an idea but not me, sorry….

_______
Norm

Posted on
Thu Sep 23, 2021 11:31 am
joesan offline
Posts: 98
Joined: Feb 12, 2008

Re: Let's solve occupancy once and for all!

Right. That's exactly the problem despite all the contorted logic there are just so many times when it doesn't work, leaving you sitting in a dark room!

I'm not sure why this isn't a fixed problem for the smart home. Judging by how many people try to do it, it seems to be the holy grail of HA. It seems that all(!) that would be needed is a two-trigger sensor, to get direction of entry/exit, then some kind of software count - plus one on enterting a room, minus one on exiting. Inevitably there would be some edge cases, such as people entering side-by-side, but I'd put up with that for the much improved reliability that the solution would offer.

Posted on
Thu Sep 23, 2021 11:52 am
norcoscia offline
User avatar
Posts: 1206
Joined: Sep 09, 2015

Re: Let's solve occupancy once and for all!

I would pay just about anything for that - if you don’t move once in the room no big deal since you would be in the room and lights would stay on. Agree, almost everyone implements something like this. I’m sure there are ways to do it but looking for something that is easy and does not take as much time as the time you save turning on lights manually.

_______
Norm

Posted on
Thu Sep 23, 2021 6:48 pm
kw123 offline
User avatar
Posts: 8332
Joined: May 12, 2013
Location: Dallas, TX

Re: Let's solve occupancy once and for all!

I have used the local circular lidar detector with pibeacon. That detects
A movement
B if the room is not empty.


Sent from my iPhone using Tapatalk

Posted on
Thu Sep 23, 2021 6:56 pm
norcoscia offline
User avatar
Posts: 1206
Joined: Sep 09, 2015

Re: Let's solve occupancy once and for all!

Thanks, I’ll look into that HW :-)

_______
Norm

Posted on
Sat Sep 25, 2021 10:41 am
mundmc offline
User avatar
Posts: 1060
Joined: Sep 14, 2012

Re: Let's solve occupancy once and for all!

One option that I am not doing indoors for privacy reasons is using ipcams and Blue Iris’s people recognition with it’s built in Deepstack (Glennnz wrote great plugins for both of these).

I have tinkered around with using opencv on a raspi with a camera so there is no photo data sent over the network, just mqtt payloads, but people are still unnerved by cameras.

The LIDAR approach sounds accurate but cost prohibitive (for me) for now if i wanted to deploy it in every room.

Posted on
Sat Sep 25, 2021 10:47 am
norcoscia offline
User avatar
Posts: 1206
Joined: Sep 09, 2015

Re: Let's solve occupancy once and for all!

Yes, the camera people thing is the best approach but all cameras in my house have tape over them (on tablets) and no camera, cameras in my house, only outside.

_______
Norm

Posted on
Mon Sep 27, 2021 2:56 am
joesan offline
Posts: 98
Joined: Feb 12, 2008

Re: Let's solve occupancy once and for all!

I think for some, indoor cameras are a hard sell, even just for presence. The Lidar option seems worth investigating, so I'll take a look at that.

Really though all that's needed is a simple count of entries into a room and then exits out. That's what makes the Hiome device so appealing (no affiliation, just enthusiastic about the product). It's a shame that they basically seem to have gone out of business because they're not answering any emails etc. But then why leave the website up and keep paying for hosting etc.? Very curious!

Posted on
Mon Sep 27, 2021 9:46 am
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: Let's solve occupancy once and for all!

joesan wrote:
..,Really though all that's needed is a simple count of entries into a room and then exits out….
Except that it may not be that simple. Like when two people leave or enter side-by-side or otherwise confuse the sensor(s). If the count should ever get out of synch, it would have to be manually reset. A means of detecting current occupancy would be self-correcting.

Posted on
Mon Sep 27, 2021 9:54 am
joesan offline
Posts: 98
Joined: Feb 12, 2008

Re: Let's solve occupancy once and for all!

Agreed, but I think that's much more of an edge case. I think it would work well enough in practice to be worth trying... and definitely more precise than the motion sensor and timer starting/resetting hacks!

Posted on
Mon Sep 27, 2021 11:24 am
norcoscia offline
User avatar
Posts: 1206
Joined: Sep 09, 2015

Re: Let's solve occupancy once and for all!

If the new apple air tags had an API it might be another way - need a people detector :-)

_______
Norm

Posted on
Mon Sep 27, 2021 12:33 pm
siclark offline
Posts: 1960
Joined: Jun 13, 2017
Location: UK

Re: Let's solve occupancy once and for all!

kw123 wrote:
I have used the local circular lidar detector with pibeacon. That detects
A movement
B if the room is not empty.


Sent from my iPhone using Tapatalk


I have pibeacons in a lot of room, but they are hidden away in cupboards or behind things. I am not sure how I can a pibeacon sensor in those locations that would meet the wife's aesthetic requirements.

Posted on
Mon Sep 27, 2021 2:09 pm
kw123 offline
User avatar
Posts: 8332
Joined: May 12, 2013
Location: Dallas, TX

Re: Let's solve occupancy once and for all!

You can hide them behind paper. That does not impact Bluetooth strength.

So an origami figure would do.


Sent from my iPhone using Tapatalk

Posted on
Mon Sep 27, 2021 2:34 pm
berkinet offline
User avatar
Posts: 3289
Joined: Nov 18, 2008
Location: Berkeley, CA, USA & Mougins, France

Re: Let's solve occupancy once and for all!

kw123 wrote:
I have used the local circular lidar detector…
Out of curiosity, which particular lidar detectors have you used?

Who is online

Users browsing this forum: No registered users and 1 guest