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

Device in "Limbo" between connection and bonding if BLE_GAP_EVT_SEC_PARAMS_REQUEST does not arrive

Hey,

I am working on NRF51822, S130 softdevice integrating security, I have used the GLS as a reference for security implementation.

I have a use case in which I am starting connection (from a custom test application I have) but don't go further to send BLE_GAP_EVT_SEC_PARAMS_REQUEST, not attempting bonding, in this case it seems that the device is just waiting forever, not disconnecting, and not returning to advertising. 

Is it something that I suppose to take care of from scratch or is there something built-in in the libararies I missed in configuration

Any help would be much appreciated.

Thanks!

  • Hi Eran, 

    There is nothing built in for such situation. There is no description in Bluetooth Spec on how a central node should bond/pair to the peripheral after a certain time. In other word a central device can connect to any peripheral and then do nothing with no idle timeout. Of course it only applies when there is whitelisting. When there is whitelisting, only the node in the list can connect to the peripheral. 

    If you want to force the central to do a pairing/bonding in a limited time after connection, you would need to implement a timer in your application to disconnect after a certain timeout. After that the peripheral can return to advertising. 

Related