This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Using 32bit I2S TX in mcaspPlayBk in StarterWare

Hi,

I am trying to modify the mcaspPlayBk to run on my board which codec 32bit I2S codec and could not get output channels correctly. For now, I only have 1 stereo input and 1 stereo output.

  • Is the input/output buffer  in the mcaspPlayBk interleaved? In the EDMA config, aCnt is 8, bCnt is the NUM_SAMPLES_PER_AUDIO_BUF, so the buffer should look like ch0-samp0 ch1-samp0 ch0-samp1 ch1-samp1 .... , right? The output format is expected to be like that, right?
  • After some experitment, I found that the output buffer has to be 4-channel interleaved, in which ch0 is sent to left and ch2 to the right, while ch1 and ch3 are lost in nowhere. Pls see the picture below, only the arrow pointed channels were heard in the output.

 

  • Here is a screenshot of the McASP registers

.

Thanks

  • It appears that the DMA event occurs twice as often as it should.

    And the input buffer seems to be 4-channel interleaved as well. So instead of 2 channel with 2000 samples in each channel, now I have 4 channels with 1000 samples in each channel. The DMA seems to serve 4000 samples each time, which is correct, but it does it as 4x1000 instead of 2x2000.

    Input buffer as in

    Any idea why?

  • If I set the minWdPerSer in the following to 2, then it works. But I shouldn't have to, do it?

    /* Enable the FIFOs for DMA transfer */   

    McASPReadFifoEnable(SOC_MCASP_0_FIFO_REGS, 1, 2);   

    McASPWriteFifoEnable(SOC_MCASP_0_FIFO_REGS, 1, 2);