[monitor] Reliable, Multi-User, Distributed Bluetooth Occupancy/Presence Detection

Yes, there’s an add-on (linked in this thread). Of course, that assumes your Pi is well placed to cover the whole house…

Tried to find the add-on bit there are 1839 posts… :slight_smile:
Or did you mean this:

I think he means this one: https://github.com/Limych/hassio-addons

Thanks @Tinkerer !!

2 Likes

Thanks also!

Is it possible to install Monitor on same RPi where MQTT Broker is installed?
Im now test Monitor on a RPi3 and have a MQTT Broker running on RPi Zero.

It will be great if I can do whole install of the Monitor on the Zero, Monitor and Broker on same RPI Zero…

Or will it conflict with the install with this part:

7. Install Mosquitto 1.5+  **(important step!)** :

# get repo key 
wget http://repo.mosquitto.org/debian/mosquitto-repo.gpg.key 

#add repo 
sudo apt-key add mosquitto-repo.gpg.key 

#download appropriate lists file
cd /etc/apt/sources.list.d/ sudo 
wget http://repo.mosquitto.org/debian/mosquitto-buster.list 

#update caches and install 
apt-cache search mosquitto 
sudo apt-get update 
sudo apt-get install -f libmosquitto-dev mosquitto mosquitto-clients libmosquitto1

Yes of course you can.

1 Like

EDIT: Removed old MQTT install and reinstall with new one, problems solved.

Tried but gives a error:

root@mqtt-server:~/monitor# apt-cache search mosquitto
bash: clearapt-cache: command not found
root@mqtt-server:~/monitor# apt-cache search mosquitto
libmosquitto1-dbg - debugging symbols for libmosquitto binaries
libmosquittopp-dev - MQTT version 3.1 client C++ library, development files
libmosquittopp1 - MQTT version 3.1/3.1.1 client C++ library
libmosquittopp1-dbg - debugging symbols for libmosquittopp binaries
mosquitto-auth-plugin - Authentication plugin for Mosquitto with multiple back-ends
mosquitto-dbg - debugging symbols for mosquitto binaries
mosquitto-dev - Development files for Mosquitto
libmosquitto-dev - MQTT version 3.1/3.1.1/5.0 client library, development files
libmosquitto1 - MQTT version 3.1/3.1.1/5.0 client library
libmosquitto1-dbgsym - debug symbols for libmosquitto1
libmosquittopp1-dbgsym - debug symbols for libmosquittopp1
mosquitto - MQTT version 3.1/3.1.1/5.0 compatible message broker
mosquitto-clients - Mosquitto command line MQTT clients
mosquitto-clients-dbgsym - debug symbols for mosquitto-clients
mosquitto-dbgsym - debug symbols for mosquitto
root@mqtt-server:~/monitor# sudo apt-get update
Hit:1 http://raspbian.raspberrypi.org/raspbian stretch InRelease
Hit:2 http://archive.raspberrypi.org/debian stretch InRelease
Hit:3 https://repo.mosquitto.org/debian buster InRelease
Reading package lists... Done

root@mqtt-server:~/monitor# sudo apt-get install -f libmosquitto-dev mosquitto mosquitto-clients libmosquitto1
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libmosquitto1 : Depends: libc6 (>= 2.28) but 2.24-11+deb9u4 is to be installed
 mosquitto : Depends: libc6 (>= 2.28) but 2.24-11+deb9u4 is to be installed
E: Unable to correct problems, you have held broken packages.
root@mqtt-server:~/monitor#

Do I need uninstall the current mosquito version and then install this one? the 1.5+ version?

Has anyone had any issues with getting an iPhone to show up? My iPhone is fine and shows up but my wife’s drops off from time to time and the only way to get it back is to restart either Bluetooth or her phone. Anyone else had an issue with this? She has an Apple Watch so was going to try and track this as well as/instead of the phone…

Why are you installing mosquitto 1.5? Who’s instructions are you following? I don’t believe you need to do that.

I followed this github:

Have same issues. I tried this for 2 days on a RPi3B+ on table without problems at all.
Now add the board inside a closet where I have more RPI running, icl my HA server. a MQTT Server near to each other and now monitor is loosing connection with BT of 2 iPhones.

Maybe it will help to use a external BT Dongle with a cable, far away from the RPi. the reduce interference with Wifi?

Thanks, it’s weird that one of the phones still works though. My Rpi3B+ is also running deconz so maybe I need to set up another pi with just monitor but was hoping to consolidate my pis

You kmow I looked there before I posted, and didn’t see that part. I do now.

Are you using buster or stretch?

Using Buster.

Now I have a desperate RPi 3B+ and connect with a 5Ghz Wifi now.
Will run it for a while and see the difference between both
Other one is RPi3B on that one is also MQTT Broker running and on 2.4Ghz

I don’t know what a desperate pi is, but I note a reference to both buster and stretch hete.

root@mqtt-server:~/monitor# sudo apt-get update
Hit:1 http://raspbian.raspberrypi.org/raspbian stretch InRelease
Hit:2 http://archive.raspberrypi.org/debian stretch InRelease
Hit:3 https://repo.mosquitto.org/debian buster InRelease
Reading package lists... Done

which is probably the problem.

I bet he meant disparate.

a different pi… sorry T9 correction… haha, better a “other” pi

As I’m having some troubles with auto detect, I’m going to rely on manual scans, as I know some of you are doing.

Using motion I’m my entryway, and door sensors, I want to activate scans. But how have you people done the setup?

I’m thinking fx doorsensor trigger arrival, after 2 min a departure, and again after 10 min, then after 2 min trigger arrival?

I need to trigger arrival last, to make sure one of my pies catch up the phones if they are moving trough the house

I think best way how to keep everything work … even when your phone is not reachable for a moment but you’re in the house:

  1. continues scan, it will pick up your phone when you at front door
  2. Leave your phone alone for checking if you’re still in house (variable value for example 10min)
  3. Scan for the phone of precent leave it again for 10 min, if not then you’re away

The continues scanning can be turned off when you’re in, and turned on when you’re away

that look for me the best way… maybe that is possible…?

Hi guys

Just wondering - I’m trying to diagnose ESP devices dropping off (then back on) my network like there’s no tomorrow - how can I find out if Monitor is scanning aggressively? I’m only using Beacons so don’t need the constant aggressive scanning, isn’t there a ‘listen’ mode where it just listens out for Beacons? I’m trying to go back to a setup I had before I had to wipe that Pi and I’m just sort of joining dots in my head trying to debug a really flaky WiFi environment which wasn’t flaky before.

(I AM using the -b for beacon flag already)

thanks!!