A.2
Miscellaneous Programming/Debug Tips
Miscellaneous Programming/Debug Tips
www.ti.com
Table A-1. Debug List (continued)
Issue
Description/Solution
Completion interrupts are not asserted, or
You must ensure the following:
no further interrupts are received after the
1.
The interrupt generation is enabled in the OPT of the associated PaRAM set
first completion interrupt.
(TCINTEN = 1 and/or ITCINTEN = 1).
2.
The interrupts are enabled in the EDMA3 channel controller (EDMA3CC), via the
interrupt enable registers (IER/IERH).
3.
The corresponding interrupts are enabled in the device interrupt controller.
4.
The set interrupts are cleared in the interrupt pending registers (IPR/IPRH) before
exiting the transfer completion interrupt service routine (ISR). See
for details on writing EDMA3 ISRs.
5.
If working with shadow region interrupts, make sure that the DMA region access
enable registers (DRAE/DRAEH) are set up properly, because DRAE/DRAEH act
as secondary enables for shadow region completion interrupts, along with
IER/IERH.
If working with shadow region interrupts, make sure that the bits corresponding to
the transfer completion code (TCC) value are also enabled in DRAE/DRAEH. For
instance, if the PaRAM set associated with channel 0 returns a completion code of
63 (OPT.TCC = 63), make sure that DRAEH.E63 is also set for a shadow region
completion interrupt because the interrupt pending register bit set will be IPRH.I63
(not IPR.I0).
1. For several registers, the setting and clearing of bits needs to be done via separate dedicated
registers. For example, the event register (ER/ERH) bits can only be cleared by writing a 1 to the
corresponding bits in the event clear registers (ECR/ECRH). Similarly, the event enable register
(EER/EERH) bits can only be set with writes of 1 to the corresponding bits in the event enable set
registers (EESR/EESRH) and can only be cleared with writes of 1 to the corresponding bits in the
event enable clear registers (EECR/EECRH).
2. Writes to the shadow region memory maps are governed by region access enable registers
(DRAE/DRAEH/QRAE). If the appropriate channels are not enabled in these registers, read/write
access to the shadow region memory map is not enabled.
3. When working with shadow region completion interrupts, ensure that the DMA region access enable
registers (DRAE/DRAEH) for every region are set in a mutually exclusive way (unless it is a
requirement for an application). If there is an overlap in the allocated channels and transfer completion
codes (setting of interrupt pending register bits) in the region resource allocation, it results in multiple
shadow region completion interrupts. For example, if DRAE0.E0 and DRAE1.E0 are both set, then on
completion of a transfer that returns a TCC = 0, they will generate both shadow region 0 and 1
completion interrupts.
4. While programming a non-dummy parameter set, ensure the CCNT is not left to zero.
5. Enable the EDMA3CC error interrupt in the device controller and attach an interrupt service routine
(ISR) to ensure that error conditions are not missed in an application and are appropriately addressed
with the ISR.
6. Depending on the application, you may want to break large transfers into smaller transfers and use
self-chaining to prevent starvation of other events in an event queue.
7. In applications where a large transfer is broken into sets of small transfers using chaining or other
methods, you might choose to use the early chaining option to reduce the time between the sets of
transfers and increase the throughput. However, keep in mind that with early completion, all data might
have not been received at the end point when completion is reported because the EDMA3CC internally
signals completion when the TR is submitted to the EDMA3TC, potentially before any data has been
transferred.
8. The event queue entries can be observed to determine the last few events if there is a system failure
(provided the entries were not bypassed).
9. In order to put the EDMA3CC and EDMA3TC in power-down modes, you should ensure that there is
no activity with the EDMA3CC and EDMA3TC. The EDMA3CC status register (CCSTAT) and the
EDMA3TC channel status register (TCSTAT) should be used.
164
Tips
SPRUG34 – November 2008
Summary of Contents for TMS320DM357
Page 2: ...2 SPRUG34 November 2008 Submit Documentation Feedback ...
Page 12: ...List of Tables 12 SPRUG34 November 2008 Submit Documentation Feedback ...
Page 16: ...Read This First 16 SPRUG34 November 2008 Submit Documentation Feedback ...
Page 64: ...EDMA3 Architecture 64 SPRUG34 November 2008 Submit Documentation Feedback ...