On 01/12/16 21:35, David G. Simmons wrote:



Rather than go through every Bluetooth device within range, connect to it, and see if it's offering the right service, I simply check the name of the device and, if it's not a mynewt device, move on. This is faster than connecting to each device.

Normally you would include a specific service UUID in the advertising packet to solve this problem, and when you collect the advertising data you can determine if the service you care about is present, which might be less arbitrary than relying on a device name? 128-bit UUIDs do cause a problem, but you can still fit one in the main adv. packet, or you can optionally use the scan response for a second payload.

Just a suggestion about a fairly standard way to solve this problem without having to connect to every device in range. :)

Kevin

Reply via email to