The LPC55s28 DMA transmits USB data through ADAU1761 waveform abnormality

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

The LPC55s28 DMA transmits USB data through ADAU1761 waveform abnormality

ソリューションへジャンプ
722件の閲覧回数
MHY_0878
Contributor I

Hello seniors, I am using PC audio software to send audio data to MCU through USB, MCU automatically carries audio data to I2S through DMA, the data enters the ADAU1761 through I2S, and outputs through DAC, but the problem now is that the data waveform is incorrect after the audio data is transmitted to the ADAU1761 through USB. A few days ago, I have been testing DMA to transfer I2S data, and confirmed that DMA is no problem to transfer I2S data, but now the possible problem is that the format of USB transfer data does not match the format of DMA transmission.

My I2S configuration is 12.288mhz for MCLK, 48khz for LRCK, 3.072mhz for BCLK, left-aligned, frame length 64 bits, 24 bits of valid data, and the remaining 8 bits of 0 padding, DMA transmission is 32-bit transmission, USB partial configuration is 24-bit depth, 48khz sample rate.

Please give me your advice.
Thank you.

Attach my code at the end

0 件の賞賛
返信
1 解決策
671件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @MHY_0878 

now the possible problem is that the format of USB transfer data does not match the format of DMA transmission.

->> The most likely issue is a mismatch between the USB data format and the I2S/DMA configuration. Carefully verify the data formats at each stage (USB, MCU, I2S, and ADAU1761) and use debugging tools to identify where the waveform becomes incorrect. Once the mismatch is identified, adjust the software to ensure compatibility.

For example 

  • Use a logic analyzer or debug tool to capture the USB data stream and verify its format.
  • Since DMA is configured for 32-bit transmission, ensure the MCU is correctly handling the 24-bit audio data with 8-bit padding.
  • If the USB data is 24-bit without padding, you may need to add the 8-bit padding in the MCU before sending it to I2S.
  • Use a logic analyzer to capture the I2S signals (MCLK, BCLK, LRCK, and data) and compare them with the expected waveform.

 

BR

Alice

元の投稿で解決策を見る

0 件の賞賛
返信
2 返答(返信)
672件の閲覧回数
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @MHY_0878 

now the possible problem is that the format of USB transfer data does not match the format of DMA transmission.

->> The most likely issue is a mismatch between the USB data format and the I2S/DMA configuration. Carefully verify the data formats at each stage (USB, MCU, I2S, and ADAU1761) and use debugging tools to identify where the waveform becomes incorrect. Once the mismatch is identified, adjust the software to ensure compatibility.

For example 

  • Use a logic analyzer or debug tool to capture the USB data stream and verify its format.
  • Since DMA is configured for 32-bit transmission, ensure the MCU is correctly handling the 24-bit audio data with 8-bit padding.
  • If the USB data is 24-bit without padding, you may need to add the 8-bit padding in the MCU before sending it to I2S.
  • Use a logic analyzer to capture the I2S signals (MCLK, BCLK, LRCK, and data) and compare them with the expected waveform.

 

BR

Alice

0 件の賞賛
返信
586件の閲覧回数
MHY_0878
Contributor I
Thank you for your reply, the issue has been resolved.
MHY
0 件の賞賛
返信