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.

Omap L138 dsp audio test program

Hi,

I’m using Zoom-Omap L-138 EVM module and i try to modify Audio test example. I’m testing it in Debug mode?

But when I put even a small signal processing code, i loose program flow, it stuck at while(!CHK…..). Here I put a simple for loop it.

If make it to 70 I can see audio loopthrough, but when I make to 75 i loose signal.

 

         // wait for recv ready and send a sample to the left channel.

            while (!CHKBIT(MCASP->SRCTL11, XRDY)) {}

                  MCASP->XBUF11 = dat;

            dat = MCASP->XBUF12;

 

                  for(i=0;i<75;i++)

                  x=3;

 

            // wait for recv ready and send a sample to the right channel.

            while (!CHKBIT(MCASP->SRCTL11, XRDY)) {}

                  MCASP->XBUF11 = dat;

            dat = MCASP->XBUF12;

 

Where do think problem is (is it MCASP, or thread scheduling), and how can I solve it?

 

Any helps will appreciate.

Volkan

 

  • Volkan MERIC said:
    Where do think problem is (is it MCASP, or thread scheduling), and how can I solve it?

    Volkan,

       The problem is deffenately not with the McASP Peripheral. To solve your issue, I would switch to interrupt driven responses rather than polling as the McASP has robust error logic to test against timing issues with input samples.

  • Hello,

    I get the same issue than Volkan.

    Drew Abuan said:
    To solve your issue, I would switch to interrupt driven responses rather than polling

    How can I enable interruption? Is is possible through RINTCTL and XINTCTL McASP registers?

    By the way, it looks strange to me that the DSP is not done with the for loop when 48 kHz sampling occurs, because, for what I understood, that is what causes of the problem.

    Thanks in advance for clarification.

  • Bruno Grentzinger said:
    How can I enable interruption?

    There is a project which already does this here.

     

    Bruno Grentzinger said:
    By the way, it looks strange to me that the DSP is not done with the for loop when 48 kHz sampling occurs, because, for what I understood, that is what causes of the problem.

    It's a little more complex than this. The clocking tree of the device must be configured for both the McASP & DSP to operate at the desired frequencies. If the McASP is not clocked correctly, or the DSP is not clocked correctly, it becomes very difficult to determine the root cause. The project I pointed to above has the correct clock settings for DSP + McASP Audio Project.

  • Hi,

    I haven't seen this project. I try to simple put the source code into sample DSP/BIOS project then set the interrupts by this:

    http://processors.wiki.ti.com/index.php/Setting_up_interrupts_in_DSP_BIOS

    but the interrupts still not occurs.

    I'm gonna try your that project after my annual leave :D

     

    Thanks for the advice.

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

    Volkan