1089
SAM9X35 [DATASHEET]
11055E–ATARM–10-Mar-2014
46.6.2.3 Disabling a DMA channel
1.
Clear the DFETCH bit in the DSCR.CHXCTRL field of the DSCR structure will disable the channel at the end of the
frame.
2.
Set the DSCR.CHXNEXT field of the DSCR structure will disable the channel at the end of the frame.
3.
Writing one to the CHDIS field of the CHXCHDR register will disable the channel at the end of the frame.
4.
Writing one to the CHRST field of the CHXCHDR register will disable the channel immediately. This may occur in
the middle of the image.
5.
Poll CHSR field in the CHXCHSR register until the channel is successfully disabled.
46.6.2.4 DMA Dynamic Linking of a New Transfer Descriptor
1.
Write the new descriptor structure in the system memory.
2.
Write the address of the new structure in the CHXHEAD register.
3.
Add the new structure to the queue of descriptors by writing one to the A2QEN field of the CHXCHER register.
4.
The new descriptor will be added to the queue on the next frame.
5.
An interrupt will be raised if unmasked, when the head descriptor structure has been loaded by the DMA channel.
46.6.2.5 DMA Interrupt Generation
The DMA controller operation sets the following interrupt flags in the interrupt status register CHXISR:
DMA field indicates that the DMA transfer is completed.
DSCR field indicates that the descriptor structure is loaded in the DMA controller.
ADD field indicates that a descriptor has been added to the descriptor queue.
DONE field indicates that the channel transfer has terminated and the channel is automatically disabled.
46.6.2.6 DMA Address Alignment Requirements
When programming the DSCR.CHXADDR field of the DSCR structure the following requirement must be met.
Table 46-5. DMA address alignment when CLUT Mode is selected
CLUT Mode
DMA Address Alignment
1 bpp
8 bit
2 bpp
8 bit
4 bpp
8 bit
8 bpp
8 bit
Table 46-6. DMA address alignment when RGB Mode is selected
RGB Mode
DMA Address Alignment
12 bpp RGB 444
16 bit
16 bpp ARGB 4444
16 bit
16 bpp RGBA 4444
16 bit
16 bpp RGB 565
16 bit
16 bpp TRGB 1555
16 bit
18 bpp RGB 666
32 bit
18 bpp RGB 666 PACKED
8 bit
19 bpp TRGB 1666
32 bit
19 bpp TRGB 1666
8 bit
24 bpp RGB 888
32 bit