nRF5340 Custom board - make it headphone device for mobile phones

Hi,

I am using a custom nRF5340 board and referring to the Zephyr sample application located at:

ncs\v2.6.0\nrf\applications\nrf5340_audio

My setup and testing environment are as follows:

  • Android phone with Bluetooth 5.3 support (LE Audio capable)

  • iPhone 16 Pro for additional testing

Steps Performed:

  1. Created custom board files for the non-secure (_ns) variant.

  2. Disabled certain parts of the code to make it compatible with my custom hardware.

  3. Built the application as a Unicast Server for the csb_cpuapp_ns board and successfully flashed it onto the custom board.

  4. The device advertises correctly with the name "NRF5340_AUDIO" and pairs successfully with my phone.

Issue:

After pairing, the device is not recognized as a headphone or microphone by the phone.

When making a phone call, the “NRF5340_AUDIO” device does not appear in the audio output/input selection menu.

I have verified this through the RTT logs attached below.

I have also attached the sample code that I am using right now for the custom board and build it for the csb_cpuapp_ns.

*** Booting nRF Connect SDK v3.5.99-ncs1 ***
-- [00:00:00.253,601] <inf> fw_info: 
   nRF5340 Audio nRF5340 Audio DK cpuapp           
   NCS base version: 2.6.0           
   Cmake run : Wed Nov 12 12:40:35 2025
-- [00:00:00.279,815] <inf> bt_mgmt_ctlr_cfg: Controller: SoftDevice: Version 5.4 (0x0d), Revision 8591
-- [00:00:00.279,998] <inf> bt_mgmt: Local identity addr: E6:25:48:D0:53:EB (random)
-- [00:00:00.283,996] <inf> bt_mgmt_adv: Local addr: 70:E2:C2:69:A3:F9 (random)
-- [00:00:00.284,515] <inf> bt_mgmt_adv: Advertising successfully started
-- [00:00:33.948,883] <inf> bt_mgmt: Connected: 45:2E:46:94:28:ED (random)
-- [00:00:33.948,913] <inf> main: Connected
-- [00:00:34.124,176] <wrn> bt_l2cap: Ignoring data for unknown channel ID 0x003a
-- [00:00:38.594,665] <inf> main: Security changed
-- [00:00:38.689,300] <err> bt_content_ctrl_media: Discovery of MCS failed (-61)
-- [00:00:45.884,948] <inf> bt_mgmt: Disconnected: 08:C7:B5:B5:48:46 (public) (reason 0x13)
-- [00:00:45.884,979] <inf> main: Disconnected
-- [00:00:45.886,474] <inf> bt_mgmt_adv: Local addr: 70:E2:C2:69:A3:F9 (random)
-- [00:00:45.886,535] <inf> bt_mgmt_adv: Adv directed to: 08:C7:B5:B5:48:46 (public).
-- [00:00:45.887,115] <inf> bt_mgmt_adv: Advertising successfully started
-- [00:00:47.167,999] <inf> bt_mgmt: Directed adv timed out with no connection, reverting to normal adv
-- [00:00:47.170,623] <inf> bt_mgmt_adv: Local addr: 70:B5:B6:F1:51:71 (random)
-- [00:00:47.171,478] <inf> bt_mgmt_adv: Advertising successfully started
-- [00:00:51.711,425] <inf> bt_mgmt: Connected: 08:C7:B5:B5:48:46 (public)
-- [00:00:51.711,456] <inf> main: Connected
-- [00:00:51.945,037] <inf> main: Security changed
-- [00:00:52.005,096] <err> bt_content_ctrl_media: Discovery of MCS failed (-61)
-- [00:00:52.064,880] <wrn> bt_l2cap: Ignoring data for unknown channel ID 0x003a

Question:

What could be the reason that the "NRF5340_AUDIO" device is not detected as a headphone or microphone on the phone after successful pairing? 

Any help would be much appreciated.

Regards,
Vivek K

nrf5340_audio_csb_board.rar

Parents
  • Hi Vivek, 

    I am using a custom nRF5340 board and referring to the Zephyr sample application located at:

    ncs\v2.6.0\nrf\applications\nrf5340_audio

    First of all, I think starting off with a DK for development purposes is a good idea, since there otherwise could also be issues with the board as well as the board files. Not knowing exactly where the issue stem from make it harder to debug. 

    Another thing is that the nrf5340_audio sample app is what we call a nordic sample, since it is under /nrf/. As opposed to the audio samples under /zephyr/.

    And we recommend using a newer SDK version if you are able to do so given how far you've gotten in your application development. And this is especially the case for LE Audio which is so cutting edge that there might be major changes between these different versions.

    After pairing, the device is not recognized as a headphone or microphone by the phone.

    When making a phone call, the “NRF5340_AUDIO” device does not appear in the audio output/input selection menu.

    There might be some basic configuration needed for it to function as a microphone and speaker.  Did you just build and flash the default app?

    iPhone 16 Pro for additional testing

    Are you sure that this phone supports LE Audio? I'm not seeing much about it online at least. I find that phones typically do not support it unless they really brag about doing it, like what the Google Pixel does.

    I have verified this through the RTT logs attached below.

    I have also attached the sample code that I am using right now for the custom board and build it for the csb_cpuapp_ns.

    Error 61 means missing expected message data,  could be some compatibility issue.

    Regards,

    Elfving

  • Hi Elfving,

    Thanks for your quick response.

    First of all, I think starting off with a DK for development purposes is a good idea, since there otherwise could also be issues with the board as well as the board files. Not knowing exactly where the issue stem from make it harder to debug. 

    I don't have nRF5340 Audio DK board(nrf5340_audio application is developed based on it) at present. So i had to make it compilable for other nrf5340 dk boards. So rather I directly made it compilable for custom boards.

    And as I have mentioned in my original post, I have flashed it and it started advertising.

    FYI: I haven't modified BLE part.

    Another thing is that the nrf5340_audio sample app is what we call a nordic sample, since it is under /nrf/. As opposed to the audio samples under /zephyr/.

    I am using nrf5340_audio sample app from the /nrf/ directory itself and not from /zephyr/.

    FYI: I have already mentioned the ncs path of the nrf5340_audio that I took from. (ncs\v2.6.0\nrf\applications\nrf5340_audio)

    And we recommend using a newer SDK version if you are able to do so given how far you've gotten in your application development. And this is especially the case for LE Audio which is so cutting edge that there might be major changes between these different versions.

    I have developed many other modules as well, so not a good idea to switch to the latest sdk at the moment.

    FYI: I have referred following video that already showing demo in which ncs version used is v2.7.0. Also it shows Google Pixel phone could be able to paired and able to access LE audio feature.

    nrf5340 Audio DK headset demo on Google Pixel 8 phone

    Ok. I have cross verified and its looks like I nrf5340_audio sample has everything that is needed to make it act as headphone or mic.

    Are you sure that this phone supports LE Audio? I'm not seeing much about it online at least. I find that phones typically do not support it unless they really brag about doing it, like what the Google Pixel does.

    Not sure if iPhone 16 pro officially supported it or not.

    Google Pixel 8 does. Show in the demo video shared above.

    Error 61 means missing expected message data,  could be some compatibility issue.

    Ok. Noted. Will look more into it.

    I would like you to review the sample code I have provided in original post and expecting some inputs from your end that How can I make it a headphone or mic device (just like shown in demo video shared above - in this reply).

    Regards,
    Vivek K

  • The incompatibility issue (-61) and nothing giving us the impression that iPhone 16 pro supports LE Audio, points in the direction that this is the problem. 

    I would suggest that you either find a way to confirm that it supports LE Audio, or continue with a Pixel phone.

    Regards,

    Elfving

Reply Children
Related