Presence detection using Bluetooth trackers with Raspberry Pi


(Scott Chapman) #21

Just a quick update. I am working to make this a ton simpler to deploy/manage. I’m basically going to be creating three NodeRed nodes (I’ve been looking for an excuse to write my first NR nodes anyway) that can easily be configured/run on your own devices. They basically would be:

  1. A configuration node - where you specify your device mapping (BTLE UUID -> SmartThings Presence Device)
  2. Scanner
  3. Processor

All of them would need to be configured to use the same MQTT broker, and only the configuration node would require the BLTE/Device map.

You would generally want all 3 on your primary device, and just 2 on any satellite devices you want to include to provide better coverage.

Make sense?

(Glen King) #22

Wow, sounds simple! /s

Sorry, but any time you start talking about multiple nodes and MQTT brokers you’re still nowhere near simple. And then you are still faced with the need of occupants to carry Bluetooth devices with them wherever they go.

Don’t get me wrong. This is cool from a geek-project standpoint. I just can’t see it as a practical thing.

(Scott Chapman) #23

I think of it as a bit of an intelligence test… :grin:

Seriously though, it can be installed on a single node. Plus one could make pre-installed images (only need two) that could be flashed to Pis.

It is kinda fun; if you’re into that sort of thing…


Hi Scott, how much do you estimate that the project might cost with one node only?
Also if I have an always running linux server, can your script run on it or it absolutely requires an RPi?
And what BT tracker did you use / buy? Can you share with us?


My intention is to do the following: keep the BT tracking device at my key chain, and when I come back home within range, before entering the house, to trigger my arrived-at-home pistons. As simple as this (I don’t need room presence or other complications).
I don’t want to use my phone, because it happens quite often to leave my phone home.
Do you think it is feasable?
For when I leave home I have a simple Alexa routine that triggers the leave-home pistons with a delay.

(Scott Chapman) #26

Yea, I think that should work OK.

So, I’ve really designed this to work on raspberry pis, but you do really only need one. In fact a cheap Pi Zero W (if you need help knowing what to get I can probably help).

I’ve greatly simplified the project to minimize what you need to run it, for example it doesn’t require node-red. It is now just simply two different scripts that can be run on the same device. I’ve been running this configuration for a few weeks, making sure it is solid and that the logging is meaningful.

I can post the update this weekend at some point.