nRF5340 AUDIO ,AUDIO FRAME DURATION

My project base on NCS V2.2.0.BIS mode,gateway

My "AUDIO FRAME DURATION" is 10ms.But my audio source is not i2s or usb.

My audio come from uart,1M bit/s.It will take 2-3ms.

and Lc3 encode take 5-6 ms.then time is not enough.

Can I modify this:AUDIO_FRAME_DURATION_US(I tried ,but failed),or an I reduce LC3 encode time.

any advice will be helpful.

  • Hello, I have forwarded the question to our audio team and will get back to you on Tuesday.

    Note that due to Easter holidays we will have less staffing in the coming week, and some delays in answers must be expected.

    Kind regards,
    Øyvind

  • Hello again, 

    Here is the initial answers from our audio team:

    No, the audio frame duration is highly related with
    • The synchronization and drift compensation mechanism in audio_datapath module
    • The frame size setting for LC3 ENC/DEC
    • I2S sampling number
    And it is very strange that the customer needs 5~6ms for encoding the data.
    There way to reduce the LC3 encoded time is to low down the bitrate.
    But it is still hard to understand what would the customer want to achieve, seems the audio is not from I2S but from UART.
    In addition: The audio frame duration is set by the LE Audio standards. It is not user adjustable. (It is possible to choose other codecs and other frame sizes, but that is a proprietary extension and out side the specs. For a qualifiable solution, the standardized frame size must be supported.)
    Would it be possible for you to share more details of what you are trying to achieve? Our audio team would like to assist, however, more details are needed.
    Kind regards,
    Øyvind
  • Hello,

    huniu said:
    Can I low down the i2s bitrate to 44.1K?

    We currently do not have support for 44.1 kHz sampling frequency, no.
    Is there a particular reason why you would like to use 44.1kHz instead of 48?

    Please also see the question from my colleague Øyvind about elaborating on your requirements and constraints so that we may better be able to help you.

    Best regards,
    Karl

  • 1.Yes,My audio from uart.

    2.LC3 encode need 6ms,I invert IO in "encoder_thread",it takes about 6ms.Then I have no time do my own work,such as another encode.

    3.My codec only suport 44.1K,So I need 44.1K.

Related