flutter_reactive_ble icon indicating copy to clipboard operation
flutter_reactive_ble copied to clipboard

Error Domain=CBErrorDomain Code=6 "The connection has timed out unexpectedly." UserInfo={NSLocalizedDescription=The connection has timed out unexpectedly.}

Open samnbd opened this issue 1 year ago • 6 comments

Describe the bug Getting an error when trying to pair to BLE device on iOS: Error Domain=CBErrorDomain Code=6 "The connection has timed out unexpectedly." UserInfo={NSLocalizedDescription=The connection has timed out unexpectedly.}

To Reproduce Steps to reproduce the behavior:

  1. Connect to one devices using connectTo()

Expected behavior Expected to pair to our device.

Smartphone / tablet

  • Device: iPhone
  • OS: iOS 13 and above
  • Package version: 5.2.0

Peripheral device

  • Vendor, model: Pavlok 3
  • Does it run a custom firmware / software: yes

Additional context So, the device pairs without issues on my iPhone but in production it fails to pair on most iOS device with the error mentioned above. PS: This issue is only happening on iOS

samnbd avatar Sep 23 '23 11:09 samnbd

this means your ble device stopped working

chipweinberger avatar Nov 06 '23 21:11 chipweinberger

well no, we have a lot of users having the same problem and the device isn't stopping at all. In fact when they attempt to pair again, it connects correctly. This is is randomly happening to most of our iOS users

samnbd avatar Nov 06 '23 21:11 samnbd

sure that may be true, but from the perspective of iOS, the device stopped working.

Your device is constantly responding to the platform with its current status.

If those status updates do not happen quickly enough (timeout), iOS will assume your device is malfunctioning.

The problem is with your device's ble stack. it is not responding quickly enough, causing iOS to claim that it has malfunctioned.

chipweinberger avatar Nov 06 '23 21:11 chipweinberger

just fyi, we have an old app that uses native iOS code (Swift) to connect to the device and we never had this issue before

samnbd avatar Nov 06 '23 21:11 samnbd

Having the same issue here. I have a custom device which uses a NINA b302-00b for BLE connection and an iPhone XR, 11 and 15, all with iOS 17.3.1 (tho the issue happened to previous versions too). Every time I try a new connection it ends in time out, I also tested using nRF Connect app, not successful. Any news?

Gufdoor avatar Feb 23 '24 21:02 Gufdoor

This is not library issue but ble device issues, I will close this

Taym95 avatar May 22 '24 09:05 Taym95