首页 文章

可以在iOS设置中发现蓝牙低功耗广告

提问于
浏览
0

我有一个iOS应用程序,它使用CBPeripheralManager来实现外围设备 . 我开始用命令做广告:

[self.peripheralManager startAdvertising:@{CBAdvertisementDataLocalNameKey : @"MY_DEVICE_NAME"}];

根据Apple docuentation,https://developer.apple.com/library/ios/documentation/CoreBluetooth/Reference/CBPeripheralManager_Class/index.html#//apple_ref/occ/instm/CBPeripheralManager/startAdvertising

外围管理器对象仅支持两个键:CBAdvertisementDataLocalNameKey和CBAdvertisementDataServiceUUIDsKey

我的问题是我希望在iOS设置的设置 - >蓝牙区域中可以发现此外围设备 . 目前,它只能通过应用程序和CBCentralManager scanForPeripheralsWithServices API调用发现 . 我是否需要添加数据服务才能通过iOS设置将其发现?

1 回答

  • 2

    在设置 - >蓝牙页面中无法发现蓝牙低功耗设备 . 这仅适用于蓝牙2.1 / 3.0设备,如键盘和耳机/免提设备 .

    蓝牙低功耗外设只能由使用Core Bluetooth的应用程序发现 .

相关问题