Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CoreBluetooth[WARNING] Unknown error: 14 on iPhone 5

I am able to connect to a peripheral device using BLE, but shortly after reading some characteristics, the framework returns:

CoreBluetooth[WARNING] Unknown error: 14

and the peripheral is disconnected.

Looking at the BT Core_V4.0 spec, I am not sure what the error means. Is the 14 a hex value? does it mean the following error according to the spec: (Part D Section 2 - Error Codes)

2.20 REMOTE DEVICE TERMINATED CONNECTION DUE TO LOW RESOURCES (0X14) The Remote Device Terminated Connection due to Low Resources error code indicates that the remote device terminated the connection because of low resources.

I tried changing the battery but did not have a different effect.

Also, I don't know how to catch these CB errors, I only see them logged, but when the device disconnects, it does not provide an error (it is null).

I do not directly control the source code for the peripheral but can ask for a bug fix. So any hints are appreciated it.

Thanks,

like image 221
mikemeli Avatar asked Mar 22 '13 23:03

mikemeli


People also ask

How do I fix Error 14 on my iPhone?

Change USB Port or Cable The most likely reason for the error 14 on the iPhone is a frayed out or faulty Lightning cable. Try changing USB ports or use a different cord (ideally from another iOS device). You can also use a third-party USB Lightning cord. Just make sure that it's MFi (Made for iPhone) certified.

What does an unknown error occurred mean?

© Google/AndroidPIT. The error is simple enough to explain: it's the error code you get when the Play Store is interrupted or otherwise confounded by your attempt to download or update an app.

How do you fix the iPhone could not be restored an unknown error occurred (- 1?

You need to manually download and install the firmware IPSW file to resolve the iPhone could not be restored an unknown error occurred (-1). This way can help you to completely resolve this issue.


1 Answers

You cannot intercept these CB errors, they are just traces from lower layer BLE.

Error 13 for instance is when the length of written data is not as specified in the GATT database. Error 14 means the connection was closed by other side (peripheral). I have seen this several times. Some times I read data too fast (You are not allowed to request next access before previous has been answered, there is only 1 "resource" in BLE per connection. Maybe this is what you also see?

As always it is best to get the TI BTLE USB Dongle with sniffer sw installed and then use the TI RF Sniffer tool in BLE mode with that dongle. You get a lot of information you can debug from in those traces. Like see if there are more than one read or write request without response.

like image 156
henrik Avatar answered Oct 04 '22 13:10

henrik