简体   繁体   English

BLE Bond表iOS

[英]BLE Bond table iOS

Have two questions in BLE. 在BLE中有两个问题。

  1. How to get all the paired BLE peripherals from the device and how to know whether my discoveredPeripheral is already paired or not? 如何从设备中获取所有配对的BLE外设,以及如何知道我的DiscoveredPeripheral是否已经配对?

  2. If the discoveredPeripheral is already paired, How to remove the pairing ie to delete the pairing from the device? 如果discoveredPeripheral已经配对,如何删除配对,即从设备中删除配对?

Thanks. 谢谢。

1: You can use: 1:您可以使用:

retrievePeripheralsWithIdentifiers RetrievePeripheralsWithIdentifiers

But you will need to know the peripheral UUID, 但是您将需要了解外围UUID,

or you can retrieve connected peripherals which has the provided services: 或者,您可以检索提供了以下服务的已连接外围设备:

retrieveConnectedPeripheralsWithServices RetrieveConnectedPeripheralsWithServices

But there isn't any good ways of detecting whether or not a peripheral is bonded or not. 但是,没有任何好的方法可以检测外围设备是否已绑定。

2: You can not remove the pairing using code. 2:无法使用代码删除配对。 The user will have to do this manually through the iOS system settings. 用户将必须通过iOS系统设置手动执行此操作。 (Settings -> Bluetooth -> Peripheral -> Forget device) (设置->蓝牙->外围设备->忘记设备)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM