Multiple BlueTooth Devices - How to Identify?

Once I enabled the BlueTooth binding in PaperUI, it detected close to 400 devices. Only few of them (~5) were identified properly, all others were given generic names. I then went and used a couple of iPad apps, and detected around 20 devices only (a factor of 20). There too, only about ~5 were properly identified (whether it’s my Fitbit or a BT speaker), many in there were also given generic/meaningless names. Hence, few questions:

  1. Why does OH detect many more devices than rare really are, or maybe the ‘same’ devices multiple times (those with generic names) ?
  2. Why are the majority of devices not identified properly? Were the people who built those devices being sloppy (not following standards, doing poor coding)?
  3. Is there a way (3rd party App) than can dig ‘deeper’ and identify such devices ?

I can only speculate but my first guess would be that it doesn’t ignore messages that are below a certain signal strength where the app requires a certain signal strength. Other possibilities can be the bluetooth library that is used is more sensitive to noise or the like. Having done just a tiny bit of BT stuff in the past, each packet sent out has a MAC address which should uniquely identify the device. I would be shocked if the BT binding doesn’t use that to uniquely identify devices which means it is seeing packets with 400 different mac addresses.

It is known that most modern phones will spoof their own MAC address so, for example, if you are hoping to use this binding to see when your phone is present you can’t. You can see that an iPhone is present but you can’t tell that a specific iPhone is present because it frequently changes the MAC address it reports in it’s broadcast packets.

BT doesn’t address that in the standard. Just about every device has it’s own way and one unique strings that identify it.

You can mess with Bluez directly from the command line and actually look at the packets that are being received and how they are identified.

Overall, BT is a crazy mixed up mess of a standard in my experience. But like I said, I only messed with it a little bit.

Thank you very much Rich, for your very informative and detailed answers … as always :slight_smile:

There was actually a bug in the bluetooth binding that didn’t purge mac addresses that expired. A fix was just made for it that will show up in the next release. If you are adventurous you can build the latest bluetooth binding code with the fix or if you are interested I can provide you the prebuilt jars with the fixes.