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.
Hello,
I am using EDMA3 to write to UART2.
I am activating it in manual triggered mode, and configuring it so each time the transfer is complete, an interrupt is generated, where the new transfer parameters are set.
This works fine, as long as I set a break point in interrupt routine, but when I let it run with no breakpoints, somwhere in the middle the transfer stops, although sequence runs to completion.
I think the problem is in the way EDMA event register are configured:
in start sequence I set (each with corrsponding bit): ICR and ESR, in interrupt i set at the start ECR and ICR, at the end of interrupt service routine ESR (to triger nex event)
Is this the right way to do it, or I miss something?
Thank You.
Arye
Make sure you're using the channel associated with UART TX. Your EDMA channel should be setup as A-sync such that the UART is able to pace the transfer of data.
The DSP can very easily keep up with the UART by directly writing to the UART2 Xmit register whenever it is empty, and the UART provides an interrupt source available to the DSP to tell it when another word can be written. But this requires a lot of overhead for the DSP to service an interrupt for each word.
The EDMA can very easily be programmed to copy from a buffer of data to the UART Xmit register whenever it is empty, and the UART provides an event source available to the EDMA to tell it when another word can be written. The EDMA could then interrupt the DSP when the whole buffer has been transmitted, and this would require the DSP to be interrupted only once per buffer rather than once per word or byte transmitted.
The way you are currently doing this is to combine the overhead of the DSP interrupts with the overhead of programming the EDMA, and you are not taking advantage of the timing signals from the UART that tell you when the Xmit register is ready for another word to be written.
There is a training video on the basics of EDMA3 with the C6474 training videos at http://e2e.ti.com/media/p/36682.aspx . The EDMA3/QDMA/IDMA module has a few details that are specific to the C6474, but most of the module is generic to all EDMA3 implementations. It explains how events are used from the peripherals to sequence through a buffer without DSP involvement on a word-by-word basis.
You will have to do like Brad said, and use the UART TX channel, then you can start using the event from the UART TX logic to control the EDMA operation.