advertising name between iOS and OSX
advertising name between iOS and OSX
- Subject: advertising name between iOS and OSX
- From: Roland King <email@hidden>
- Date: Fri, 19 Jun 2015 15:53:34 +0800
My testing seems to show the following difference between iOS and OSX, can anyone else confirm these results and/or tell me how to make it more consistent
I have some development code (on a nordic board) which allows me to switch between a long / short or no name at all, in the advertising packet. So I run that and mess with it.
On OSX
1) There’s no name in the advertisementData returned in the didDiscoverPeripheral, ever.
2) The CBPeripheral.name property alway contains the ‘best’ name. ie if no name has been seen, it contains nil, if a shortname has been seen, it’s that, if a full name has been seen, it contains that. Even if you change the name from long to short, or missing in the advertising packet, OSX continues to report the same name. Only if you give it a ‘better' name does it update.
3) Even though I’ve asked *not* to have duplicate notifications, I get constant callbacks for the same devices, every second or so
On iOS
1) There’s always a name in the advertisementData packet, as long as you’ve provided one in the actual advertising packet
2) The CBPeripheral.name updates when you change the name in the advertising packet between long/short/missing. However, once it’s seen a name, it never goes back to having nil, but if you switch from a long to a short and vice-versa, it will update
3) I only get the one callback each time the device is ‘seen’ unless I change the advertising data, at which point I get another one.
Seems odd to me they have such different behaviour.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Bluetooth-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden