Query - nRF5340 Audio DK - Configuration to Stream Multiple Stereo Audio

Hello,

I have 3 nRF5340 Audio DK. With the steps mentioned in below links, I configured Json file to stream left/right audios and I'm able to achieve it.

https://developer.nordicsemi.com/nRF_Connect_SDK/doc/2.0.2/nrf/applications/nrf5340_audio/README.html
https://www.youtube.com/watch?v=ZtNflUO8IC0

How to stream stereo audio to 2 sink DK from a source DK?
How to do multi-streaming to 3 or more DK? (Usecase: I want to stream 4 separate audios at a same time to 4 separate sinks from a source)

Thanks

Parents
  • Hello,

    How to stream stereo audio to 2 sink DK from a source DK?

    You can configure your gateway to connect to two headsets. The left and right channels of the stereo audio can be sent over one CIS. For the headsets to be able to decode stereo sound you need to configure the decoder setting.

    How to do multi-streaming to 3 or more DK? (Usecase: I want to stream 4 separate audios at a same time to 4 separate sinks from a source)

    There may be a limit of two ACL links in connected stream mode (CIS). I have asked internally for more information on this. I will get back to you when I know more.

    With four separate audios you would likely run out of processing power. The encoding needs a significant amount of the CPU, and as the encoder is a mono encoder, encoding stereo doubles the amount of processing power needed. For the current stage of our LE Audio implementation, the maximum number of channels which can be encoded at the same time is three or four. For four separate stereo audios you will unfortunately not have enough CPU power available on the nRF5340 Audio DK.

    Kind Regards,
    Maria

  • The left and right channels of the stereo audio can be sent over one CIS

    I see Bluetooth SIG community mentioned max limit of CIS to be 31. Here does left and right channels contribute 2 CIS or they combine to form 1 CIS?
    How can I connect 3rd(2nd) CIS to 3rd headset(nrf5340 DK) from gateway(nrf5340) with new audio channel(not the left and right channels which is active in 1st CIS) 

    With nRF5340 user guide, I could only see that the configurations can be set to transmit same audio(left/right) to 'n' no of headsets(DK) using CIS. 
    My motive is to stream multiple audio tracks(2 diff song) through different channel to different DK,

    Thanks for your support

  • Hello,

    I am doing a little more research on this and will get back to you tomorrow.

    Thank you for your patience.

    Kind Regards,
    Maria

  • Bala4nRF said:
    I see Bluetooth SIG community mentioned max limit of CIS to be 31. Here does left and right channels contribute 2 CIS or they combine to form 1 CIS?

    The limit of 31 CIS in one CIG is from the Bluetooth specification. For the LE Audio Controller Subsystem for nRF53, the maximum CIS per CIG is two. Also, there is a maximum of two ACL links with the nRF53 LE Audio controller. Each ACL link can control one CIG or both CIS in the same CIG separately.

    The left and right channels can be combined to form 1 CIS.

    Bala4nRF said:
    How can I connect 3rd(2nd) CIS to 3rd headset(nrf5340 DK) from gateway(nrf5340) with new audio channel(not the left and right channels which is active in 1st CIS) 

    This is not possible with the current controller. Each connected device needs an ACL and the maximum number of ACL links is 2. The BIS mode is the only mode supporting streaming to more than two devices at this point.

    Bala4nRF said:
    With nRF5340 user guide, I could only see that the configurations can be set to transmit same audio(left/right) to 'n' no of headsets(DK) using CIS. 

    Yes, this is the way the application implements stereo -- two kits needed for left and right output. You can modify the application to be able to stream stereo by combining the left and right channel after encoding and before sending the audio. In the application code, the combination needs to be done before streamctrl_encoded_data_send() is called in the encoder_thread() in src/audio/audio_system.

    Bala4nRF said:
    My motive is to stream multiple audio tracks(2 diff song) through different channel to different DK,

    Two different songs with stereo audio will need four channels to be encoded, which will surpass the processing power available. You are free to test if a lower sample rate for the audio will make the processing power decrease enough to make it work. This is just speculation from my side, though.

    Kind Regards,
    Maria

Reply
  • Bala4nRF said:
    I see Bluetooth SIG community mentioned max limit of CIS to be 31. Here does left and right channels contribute 2 CIS or they combine to form 1 CIS?

    The limit of 31 CIS in one CIG is from the Bluetooth specification. For the LE Audio Controller Subsystem for nRF53, the maximum CIS per CIG is two. Also, there is a maximum of two ACL links with the nRF53 LE Audio controller. Each ACL link can control one CIG or both CIS in the same CIG separately.

    The left and right channels can be combined to form 1 CIS.

    Bala4nRF said:
    How can I connect 3rd(2nd) CIS to 3rd headset(nrf5340 DK) from gateway(nrf5340) with new audio channel(not the left and right channels which is active in 1st CIS) 

    This is not possible with the current controller. Each connected device needs an ACL and the maximum number of ACL links is 2. The BIS mode is the only mode supporting streaming to more than two devices at this point.

    Bala4nRF said:
    With nRF5340 user guide, I could only see that the configurations can be set to transmit same audio(left/right) to 'n' no of headsets(DK) using CIS. 

    Yes, this is the way the application implements stereo -- two kits needed for left and right output. You can modify the application to be able to stream stereo by combining the left and right channel after encoding and before sending the audio. In the application code, the combination needs to be done before streamctrl_encoded_data_send() is called in the encoder_thread() in src/audio/audio_system.

    Bala4nRF said:
    My motive is to stream multiple audio tracks(2 diff song) through different channel to different DK,

    Two different songs with stereo audio will need four channels to be encoded, which will surpass the processing power available. You are free to test if a lower sample rate for the audio will make the processing power decrease enough to make it work. This is just speculation from my side, though.

    Kind Regards,
    Maria

Children
  • Thanks for the detailed information.

    Could you please clarify some additional points here,

    The BIS mode is the only mode supporting streaming to more than two devices at this point.

    Is auracast possible with nRF5340? As BIS is connectionless, how many streams possible in BIS mode?
    Usecase : Stream 2 stereo audios / 4 Mono audios in BS mode from source. Headsets can tune into whatever they want.

    You can modify the application to be able to stream stereo by combining the left and right channel after encoding and before sending the audio. In the application code, the combination needs to be done before streamctrl_encoded_data_send() is called in the encoder_thread() in src/audio/audio_system.

    If I do this, both left and right channels will be able to receive same stereo audio? How can stereo be streamed through single channel of CIS? Are we merging two audios(left & right) to from mono, stream it via CIS and at the receiver(headset) do some logic to get stereo audio from mono?

    You are free to test if a lower sample rate for the audio will make the processing power decrease enough to make it work.

    I understand we can try to stream to more than 2 channels(CIS) even if its works, its expected to have some loss with low sampling rate. Here, is it possible to do changes in code such that source DK be able to take 2 stereo audio inputs at low sample rate, process and stream to 2 CIS at low sample rate. (Audio quality not important)

    Instead of giving audio inputs from type c/3.5mm jack, Is it possible to change source code to take input from SD card having mp3 files? Could you point me code where I could start checking

    Thanks once again!

  • Hello,

    Bala4nRF said:
    Thanks for the detailed information.

    Happy to help!

    Bala4nRF said:
    Is auracast possible with nRF5340?

    Currently, this is not supported, but it is planned.

    Bala4nRF said:
    As BIS is connectionless, how many streams possible in BIS mode?
    Usecase : Stream 2 stereo audios / 4 Mono audios in BS mode from source. Headsets can tune into whatever they want.

    Currently, the maximum amount of streams supported in the audio application is two. Note that any amount of headsets can subscribe to the stream. The maximum is the broadcast streams from the gateway.

    I do not have conclusive information on how stereo streaming in BIS mode works in terms of channels in a BIS within a BIG. I can ask the developers for this information, and report back to you after the weekend.

    Bala4nRF said:
    If I do this, both left and right channels will be able to receive same stereo audio? How can stereo be streamed through single channel of CIS?

    The receiving device will receive a merged stream which can be decoded and separated into the left and right channel. So when streaming the encoded audio stream, the left and right channels is merged into one isochronous stream.

    Bala4nRF said:
    Are we merging two audios(left & right) to from mono, stream it via CIS and at the receiver(headset) do some logic to get stereo audio from mono?

    Yes we are merging the left and right channel mono audio into one stream. At the receiving device, some work is required to get the timing right.

    This reply to a case and this case contains some useful information on how to get started with merging and separating streams.

    Bala4nRF said:
    I understand we can try to stream to more than 2 channels(CIS) even if its works, its expected to have some loss with low sampling rate. Here, is it possible to do changes in code such that source DK be able to take 2 stereo audio inputs at low sample rate, process and stream to 2 CIS at low sample rate. (Audio quality not important)

    Yes, this is what I am suggesting as an experiment for you.

    Bala4nRF said:
    Instead of giving audio inputs from type c/3.5mm jack, Is it possible to change source code to take input from SD card having mp3 files? Could you point me code where I could start checking

    Yes, this is possible. The Audio DK has an SD card holder. and you can find some reference code in the sd_card header and source files in nrf5340_audio/src/modules.

    You can also encode the audio before loading it onto the SD card by using a standalone LC3 encoder. This will free up the CPU when running the application as well as storage space on the SD card.

    Kind Regards,
    Maria

  • "Bala4nRF said:
    Is auracast possible with nRF5340?

    Currently, this is not supported, but it is planned."

    I see in the changelog for ncs 2.2.99 that "Possibility to create a Public Broadcast Announcement (PBA) needed for Auracast.". Is Auracast protocol implementation and a Auracast sample still being developed?

  • Hello,

    Support for Auracast (TM) is not implemented yet. You can keep up to date with the supported features of the nRF5340 Audio application by looking at the feature support matrix in the intro section for the application.

    Best Regards,
    Maria

Related