Atmel Evaluation Kit AT91SAM9G25-EK AT91SAM9G25-EK 데이터 시트

제품 코드
AT91SAM9G25-EK
다운로드
페이지 1102
461
SAM9G25 [DATASHEET]
11032C–ATARM–25-Jan-13
31.4.4 DMAC Transfer Types
A DMAC transfer may consist of single or multi-buffer transfers. On successive buffers of a multi-buffer transfer, the
DMAC_SADDRx/DMAC_DADDRx registers in the DMAC are reprogrammed using either of the following methods:
z
Buffer chaining using linked lists
z
Replay mode
z
Contiguous address between buffers 
On successive buffers of a multi-buffer transfer, the DMAC_CTRLAx and DMAC_CTRLBx registers in the DMAC are re-
programmed using either of the following methods:
z
Buffer chaining using linked lists
z
Replay mode
When buffer chaining using linked lists is the multi-buffer method of choice, and on successive buffers, the
DMAC_DSCRx register in the DMAC is re-programmed using the following method:
z
Buffer chaining using linked lists
A buffer descriptor (LLI) consists of following registers, DMAC_SADDRx, DMAC_DADDRx, DMAC_DSCRx,
DMAC_CTRLAx, DMAC_CTRLBx.These registers, along with the DMAC_CFGx register, are used by the DMAC to set
up and describe the buffer transfer. 
31.4.4.1 Multi-buffer Transfers
Buffer Chaining Using Linked Lists
In this case, the DMAC re-programs the channel registers prior to the start of each buffer by fetching the buffer descriptor
for that buffer from system memory. This is known as an LLI update.
DMAC buffer chaining is supported by using a Descriptor Pointer register (DMAC_DSCRx) that stores the address in
memory of the next buffer descriptor. Each buffer descriptor contains the corresponding buffer descriptor
(DMAC_SADDRx, DMAC_DADDRx, DMAC_DSCRx, DMAC_CTRLAx DMAC_CTRLBx).
To set up buffer chaining, a sequence of linked lists must be programmed in memory.
The DMAC_SADDRx, DMAC_DADDRx, DMAC_DSCRx, DMAC_CTRLAx and DMAC_CTRLBx registers are fetched
from system memory on an LLI update. The updated content of the DMAC_CTRLAx register is written back to memory
on buffer completion. 
 shows how to use chained linked lists in memory to define multi-buffer
transfers using buffer chaining.
The Linked List multi-buffer transfer is initiated by programming DMAC_DSCRx with DSCRx(0) (LLI(0) base address)
different from zero. Other fields and registers are ignored and overwritten when the descriptor is retrieved from memory. 
The last transfer descriptor must be written to memory with its next descriptor address set to 0.
Figure 31-5. Multi Buffer Transfer Using Linked List 
System Memory
SADDRx
= DSCRx(0) + 0x0
DADDRx
= DSCRx(0) + 0x4
CTRLAx
= DSCRx(0) + 0x8
CTRLBx
= DSCRx(0) + 0xC
DSCRx(1)
= DSCRx(0) + 0x10
SADDRx
= DSCRx(1) + 0x0
DADDRx
= DSCRx(1) + 0x4
CTRLBx
= DSCRx(1) + 0x8
CTRLBx
= DSCRx(1) + 0xC
DSCRx(2)
= DSCRx(1) + 0x10
DSCRx(0)
DSCRx(2)
(points to 0 if
LLI(1) is the last
transfer descriptor
DSCRx(1)
LLI(0)
LLI(1)