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.

[C6747] McASP Locking up

I am using the Write Fifos for transmitting audio out the McASP on the 6747 (the Write Fifos are fed by an interrupt).  When I halt the processor the wrirte fifos empty out, and the McAsp throws an Underrun error.  Once the program starts again the McASP seems to refuse to ask for any more samples from the Write Fifos (the Write fifos fill up and stay filled up). 

What do I need to do to kick start the MCASP into normal operation after an emulator interrtupion? Do I have to do an entire reset of all the state machines or am I just not clearing a bit somewhere?  I am writing oxFFFF to the McASP XSTAT register with no luck.  My McASP Clock Error detector is not set up, can that freeze the Mcasp?

Also since there is no Emulation control on this McASP, is there an external Emulation signal that I could use to tell my PLD to freeze the audio clocks, thus simualting an emulation freeze?

thanks,

-howy

 

  • sprufm1.pdf Ch 2.4.7.2 said:

    In TDM mode, during an underrun case, a long stream of zeros are shifted out causing the DACs to mute.
    To recover, reset the McASP and start again with the proper initialization.

    You might also consider another option.  If you use the EDMA to service the McASP then it too would continue to run when you halt the CPU.  That would enable you to continue filling the McASP FIFO even when you are halted.  A specific method is described in spra870 in Chapter 2.3 for doing exactly that.  In fact, not only does it solve the issue of the 6747 not having the "emulation suspend" feature, but also it solves another issue that would be present regardless in cases where the clock master is the other device, e.g. the codec.  In the case where the codec is the clock master and you halt the processor you have a 50/50 chance of ending up with swapped/rotated channels when the CPU resumes running.  The method discussed in spra870 was actually focused on solving that particular problem though it just so happens to fit your description too!

    I hope that helps.  If you have troubles with EDMA configuration please start a separate thread.

    Brad