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

nRF52-DK automatic reconnect to android with Nordic nRF Connect App

Hi,

   I'm using nRF52-DK evaluation board, and ble_app_template_pca10040_s132 (from examples of nRF5_SDK_17.00.9d13099)

I'm designing an android smartphone as a central,  nRF52-DK EV board as a peripheral

,and using "nRF Connect for Mobile" App form Nordic to connect the EV board. 

  What I want to do is that

if terminate nRF App and turn it back on, my EV board will automatically reconnect. 

  nRF Connect App already support a function "Connect with autoConnect", but

this autoConnect is executed when EV board turns off & on again.

 if I terminate nRF App, I should touch "connect" button to confirm reconnection.

  Is there any way to operate auto-reconnection between nRF52 & android without external confirm 

, like commercial Bluetooth earphones ?

Thanks,

  • It's the Central (ie, your app) that initiates connections - so it's the app that would have to manage any auto-connect.

    The nRF part is irrelevant.

  • Thank you for letting me know that!

    What i struggle is only Nordic nRF Connect App can detect nRF52-DK EV Board with nRF5_SDK_example. 

    I tried connection with default Bluetooth App & MIT App inventor with BLE Extension

    ,but not worked.

    Have you tried to connect nRF5 EV Board with another Bluetooth app before?

    It seems like that only "nRF Connect for Mobile" from Nordic only works. 

  • nRF52-DK EV Board with nRF5_SDK_example

    Which example(s), exactly ?

    Note that some of the examples use proprietary services - so they won't be recognised by apps which don't "know" those services.

    default Bluetooth App

    What is that?

    Note that nRF is BLE only - so it won't be seen by "Classic" BT apps

    You need to consult the app documentation and/or contact the developer for support.

    Have you tried to connect nRF5 EV Board with another Bluetooth app before

    Yes - any standard BLE scanner app should be able to any nRF device.

  • http://developer.nordicsemi.com/nRF5_SDK/nRF5_SDK_v17.x.x/

    above link contains examples what i'm using

    Specifically, i used "ble_app_template_pca10040_s132,emProject"
     

    and Default Bluetooth App is below image

    nRF5 device name is "Nordic_template" setted by  "ble_app_template_pca10040_s132,emProject",

    Default Bluetooth App can detect its name, but the pairing is not executed.

    Thank you for specifying my issue.

  • Hello,

    What  is saying is correct - it is the central that will need to initiate the connection by sending a connection request to the peripheral.
    If you are making your own Android application, or using the nRF Connect application then you may have these use AutoConnect to automatically reconnect with your device when they receive an advertisement from it.

    In your original ticket I see that you specifically mention the ability to automatically reconnect without running a particular application and without having to confirm the reconnection ( if I have understood you correctly ), like the user-experience with headphones, for example.
    To my knowledge, the Android OS only does this for devices with the GATT HOGP profile - you can read more about this as part of the "link loss reconnection" section of the HOGP specification.

    It is here important to beware of the difference between the "Bluetooth classic" profiles, and the GATT profiles used for Bluetooth Low-Energy, as @awneil also mentions.

    Please do not hesitate to ask if you should encounter any issues or questions!

    Best regards,
    Karl

Related