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.

Audio Transmit Within A Task - XRDY not being reset.

Greetings, 

I have an audio task where I am transmitting one sample of audio (filling a buffer), at a time. I want to do this for both left and right channels of each MCASP, so I call the following once for each 

 

while (! ( MCASP0_SRCTL9 & 0x10 ) ); //While XRDY=0

            MCASP0_XBUF9_32BIT = (channel_mask[1]*sinetable[sample] << 15);

I do this for many channels, When I get to the right channel of the MCASP, where the above expressions are repeated, XRDY remains 0, even though I just filled the buffer a moment before. 

This code works well and transmits the audio properly outside of the task, but the moment I enclose it in a task, it hangs when transmitting the second sample. 

I'm working now to instead use an SIO, but any lower level examples, or advice to maintain this syntax would be appreciated. 

Cheers,

Amanda

  • Hi,

    Thanks for your post.

    Which TI bios example code are you using? Which TI board you are trying?

    Have you checked the task priority configuration in th bios config. file?

    Are you using the code as-is else, are you modifying the code as per your requirement?

    Have you debug the code inside the audio tx. task and evaluate the cause for the tx. hang?

    Did you create the instance for the audio tx. task in the bios config file?

    Kindly provide more details on the above.

    Thanks & regards,

    Sivaraj K

    ------------------------------------------------------------------------------------------------

    Please click the Verify Answer button on this post if it answers your question.

    ------------------------------------------------------------------------------------------------