This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Proximity profile on nRF51822 with iOS app. Failed to connect.

I've just flashed the softdevice 5.2.1 and BLE Proximity sample app to my nRF51822. I presume any previous bond state on the device should have been wiped by doing this.

If I now start the nRF Proximity iOS app and try to connect to the device, I get the following error:

Failed to connect The app couldn't connect to Nordic_Prox This usually indicates a previous bond. Go to the settings and clear it before you try again.

Which settings does this error refer to? If I go to the Bluetooth settings in iOS, the device is either not listed at all, or is flickering between two states (not connected and pairing, I think).

Parents
  • It's a little unclear to me exactly what you're seeing, and you don't state whether or not you get the pairing question from iOS. If you do, you should be able to tap the device in Bluetooth settings, and delete bond information. Note that you must tap the small i, not just on the row of the device.

    Also note that removing a device from nRF Proximity itself does not remove bonding information, since that is impossible for the app both to know and do anything about; removing it from the app will only make nRF Proximity not initiate any further connections to it.

    In general, you should be able to avoid this kind of problems by making sure you don't delete bond information unless you really want to. It will often make sense to only delete the bond information for the old Central once you have successfully bonded again with a new Central, or it might make sense to keep bonding information for all devices. If so, you need to make a decision on what to do if your user bonds with too many devices. Either way, I'd recommend you to pass an event handler in the bond_manager_init() function and use those events to behave appropriately.

    Also, you should also consider whether you actually need bonding at all. If you can, you make some things easier by just using an open link.

    For general information on what bonding is and how it works, this guide may be useful.

Reply
  • It's a little unclear to me exactly what you're seeing, and you don't state whether or not you get the pairing question from iOS. If you do, you should be able to tap the device in Bluetooth settings, and delete bond information. Note that you must tap the small i, not just on the row of the device.

    Also note that removing a device from nRF Proximity itself does not remove bonding information, since that is impossible for the app both to know and do anything about; removing it from the app will only make nRF Proximity not initiate any further connections to it.

    In general, you should be able to avoid this kind of problems by making sure you don't delete bond information unless you really want to. It will often make sense to only delete the bond information for the old Central once you have successfully bonded again with a new Central, or it might make sense to keep bonding information for all devices. If so, you need to make a decision on what to do if your user bonds with too many devices. Either way, I'd recommend you to pass an event handler in the bond_manager_init() function and use those events to behave appropriately.

    Also, you should also consider whether you actually need bonding at all. If you can, you make some things easier by just using an open link.

    For general information on what bonding is and how it works, this guide may be useful.

Children
No Data
Related