AnsweredAssumed Answered

Halt and restart SPORT during sample rate change

Question asked by kenfred on Feb 24, 2011
Latest reply on Sep 2, 2015 by Harshit.Gaharwar

I am attempting to halt, reconfigure, and then restart the SPORT DMA and SPORT controller during a sample rate change.  I am running the SPORTs in multichannel mode on a 21469.  I assume the procedure is as follows:

 

1. Mask the SPORT DMA interrupts

2. Disable SPORT DMA (Clear the SDEN_A/B bits in the SPCTLx reigesters)

3. Disable SPORT interface (Clear the MCEN_A/B bits in the SPMCTLx reigesters)

4. Reconfigure the DMA TCBs

5. Clear the DMA ping/pong memory

6. Clear the SPORT FIFOs (?)

7. Enable DMA

8. Enable SPORT interface

 

Is the above procedure correct?

 

The main questions is how to accomplish step 6.  I can't find documentation that describes how to flush the SPORT FIFOs.  Is there a way to shift out the stale elements in the FIFO while watching the DXS0_A/B status bits to know when the FIFO is empty?

 

Any help would be appreciated.

Outcomes