Closed DaBs closed 5 years ago
I'm having the same problem. I'm using the echo
example.
The console output is:
peripheralManagerDidAddService: <CBMutableService: 0x102a22680 Primary = YES, UUID = EC00, Included Services = (null), Characteristics = (
"<CBMutableCharacteristic: 0x102a23f10 UUID = EC0E, Value = (null), Properties = 0x1A, Permissions = 0x3, Descriptors = (\n), SubscribedCentrals = (\n)>"
)> (null)
But then LightBlue has my mac with no services advertised.
When I go deeper on my mac, the service doesn't show up under the advertisement info.
Even though the service shows up in the list of services.
@aaronrogers Advertised services and actual services does not necessarily correspond, and it sounds like your problem is a separate one in terms of actual services.
I just encountered this same issue, and threw up a PR that fixes the issue for me. LMK if you think this looks good or want any changes. https://github.com/notjosh/bleno-mac/pull/7
@ankidave I just checked our your branch and it fixes the issues. Thanks for providing the fix! This issue is resolved by PR #7
It seems advertising service UUIDs are not correctly being advertised, even though the log indicates it is.
This is the output from the advertising call:
startAdvertising:SOMEBOX #212222 serviceUUIDs:( "445B9FFB-348F-4E1B-A417-3559B8138390" )
But when I detect it via e.g. nRF Connect on an Android, or Bluecap on iOS, the advertised service IDs turns out to be an empty array. I'm digging some more into it, but it becomes rather problematic.