iPhone:如何擦除/消除蓝牙4.0数据 [英] iPhone: How to erase/wipe out bluetooth 4.0 data
问题描述
我正在使用蓝牙低功耗的一些重大故障应用程序有时无法连接到我的设备(在线程中描述)。
I am having some major trouble with my Bluetooth Low Energy application sometimes dont manage to connect to my device (described in thread).
我需要在运行我的应用程序之前清除以前连接中的所有存储数据,据我所知,这只能通过重启手机来完成。有没有其他方式,最好以编程方式,这样做?
I need to wipe out all stored data from previous connections before running my application, and as far as I know, this can only be done by rebooting the phone. Is there any other way, preferably programatically, to do this?
谢谢
推荐答案
我遇到同样的问题并且有找到了重现它的步骤。
I am having the same issue and have found the steps to reproduce it.
使用
[peripheral writeValue:x forCharacteristic:y type:CBCharacteristicWriteWithoutResponse];
当外围设备超出范围并断开连接时。发生这种情况后,BLE设备不再返回任何服务,只有重新启动才能解决问题。如果外围设备超出范围并返回而没有向其传输数据或者
while the peripheral goes out of range and disconnects. After this happens no more services are returned by BLE devices, and only a reboot fixes the problem. This doesn't happen if the peripheral goes out of range and comes back in without transmitting data to it or if
[peripheral writeValue:x forCharacteristic:y type:CBCharacteristicWriteWithResponse];
使用...
其他断开连接似乎不会影响它,例如关闭外围设备并在范围内将其重新启动,即使在传输数据时......
Other disconnects don't seem to affect it, such as powering down the peripheral and powering it back up while in range even while transmitting data...
我知道这不是'答案,但看起来我出于某种原因无法评论。
I know this isn't an answer but it looks like I can't comment for some reason.
希望这有助于调试。
这篇关于iPhone:如何擦除/消除蓝牙4.0数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!