This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2564: [A3DP&SPP] How to auto connect with Smartphone?

Part Number: CC2564

Hi,

I'm testing A3DP & SPP.

I'm trying to automatically connect A3DP and SPP from the board to my smartphone.

The smartphone we are using is Android.

For example, if I try to connect to a smartphone using the OpenRemoteEndPoint() function on the board, a pop-up appears asking if you want to connect to the board from your smartphone.

I do not want to appear this pop-up. If I do not want this pop-up to appear, what kind of data should be stored in the flash memory of the board?

Link Key? Or Authentication data?

  • Which host device are you using with CC2564?

    -- clip from earlier thread response on this forum -----
    There are 2 parts of this implementation from the BT stack side to store the link key of a paired device in NVM.

    - When a new device is paired, the atLinkKeyCreation event will occur in the GAP_Event_Callback. When this event occurs, you can see that the application is storing the link key in the following struct.

    static LinkKeyInfo_t LinkKeyInfo[MAX_SUPPORTED_LINK_KEYS];

    This struct is stored in the RAM, so it will not be retained over a power cycle. At this time, you can take a backup of the LinkKeyInfo in the NVM of the MCU.

    - When the device powers up, read the backup that is stored in the NVM. Then you can pass this data to the LinkKeyInfo struct in the InitializeApplication() function after the OpenStack call is successful. This way, the previously stored LinkKeyInfo is restored after the power cycle and when the remote device tries to reconnect, the A3DP application will be able to use the previously stored link key. This occurs in the atLinkKeyRequest event of the GAP_Event_Callback.


    Thanks