BLE pairing process with nRF5340 Audio

I have asked this before, but I will ask again.

I have a few questions about the sample source of nRF5340 Audio.

1. Where does the connection process between the gateway and the headset take place?

2. Where is the BLE bonding information set?

3. Is it possible to rewrite the bonding information?

4. Will reconnection occur automatically after executing bt_mgmt_bonding_clear()?

5. If I want to fix the key exchanged during pairing instead of generating it randomly, which source should I edit?

  • Hi, 

    1. Where does the connection process between the gateway and the headset take place?

    See https://github.com/nrfconnect/sdk-nrf/blob/v2.7.0/applications/nrf5340_audio/src/bluetooth/bt_management/bt_mgmt.c#L62 

    2. Where is the BLE bonding information set?

    See this course on how to implement bonding. 

    3. Is it possible to rewrite the bonding information?

    Yes, it is possible to rewrite the bonding information. To clear the bonding information, press and hold BTN 5 during boot or reprogram all the development kits. 

    4. Will reconnection occur automatically after executing bt_mgmt_bonding_clear()?

    yes, but it needs both sides to delete the bonding information.

    5. If I want to fix the key exchanged during pairing instead of generating it randomly, which source should I edit?

    You can use the CONFIG_BT_FIXED_PASSKEY configuration option which allows you to set a fixed passkey that will be used during the pairing process. See my colleague's example in this post.  However, please note that using a fixed passkey is less secure and is not recommended for production use, as it is easy to deduce during the pairing procedure. 

    Regards,
    Amanda H.

Related