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

Reconnect Automatically after bonding

Hi,

In my application,for the first time device (nrf52832)will start advertising and on nrfconnect for mobile application side we make it get connected and bonded.It may get disconnected, after certain functionality or due to bluetooth disable or battery down.for the next time when i try to connect, if device is advertising as it is already bonded then I must be able to connect automatically  from nrfconnect for mobile app.

For my requirement ,development to be done on application side(device) or nrfconnect for mobile?If it is to be done on application side please let me know how it can be implemented?Is there any example already present is SDK15.3.0 serving the above purpose?If yes, please let me know in which example it is done?

My attempts to solve above involved trying CTS example where it is using whitelisting for the next connection.But there user has to manually connect. Whitelisting provides chance of skipping scanning functionality in CTS example.Did I understand it right?If yes,along with skipping scanning functionality after once getting bonded I always want to get connected automatically if device is advertising.

Thank you.

Parents Reply Children
  • Hi, 

    Thanks for your clear explanation.Present my implementation part is on automatic reconnection if device is once bonded, my question is not about how to get bonded to device.Iam able to bond ,I already followed the same steps you mentioned inorder to get bonded.Thats not the issue.

    In Heart Rate Collector Example it is clearly mentioned that device gets automatically connected even after disconnection but it can be tested using 2 DK's.In order to test similar functionality using 1 DK and one mobile As per your suggestion  I tried testing heart rate example but I am stuck at finding security settings.Is bonding is enough to get automatically connected after disconnetion?

    Thank you.

  • Hi, 

    There is no security setting in the nRF Connect mobile, but the bond function is enough for the security. 

     "When you choose "autoConnect" with the nrf Connect app, the Android will try to establish connection whenever the device is in range". (source: Q&A page from the nRF connect app)  

    Have you tested this functionality? You could see the nRF Connect autoconnect to the device if you turn off and on the power on DK.

    -Amanda H.

Related