•
BEATSIZE is the configured number of bytes in a beat
•
STEPSIZE is the configured number of beats for each incrementation
shows an example where DMA channel 0 is configured to increment destination address by
.DSTINC=1) and DMA channel 1 is configured to increment destination address by
two beats (
.DSTINC=1,
address for both channels are peripherals, source incrementation is disabled (
Figure 26-9. Destination Address Increment
DST Data Buffer
a
b
c
d
26.6.2.8. Error Handling
If a bus error is received from an AHB slave during a DMA data transfer, the corresponding active
channel is disabled and the corresponding Channel Transfer Error Interrupt flag in the Channel Interrupt
Status and Clear register (
.TERR) is set. If enabled, the optional transfer error interrupt is
generated. The transfer counter will not be decremented and its current value is written-back in the write-
back memory section before the channel is disabled.
When the DMAC fetches an invalid descriptor (
.VALID=0) or when the channel is resumed and
the DMA fetches the next descriptor with null address (DESCADDR=0x00000000), the corresponding
channel operation is suspended, the Channel Suspend Interrupt Flag in the Channel Interrupt Flag Status
and Clear register (
.SUSP) is set, and the Channel Fetch Error bit in the Channel Status
register (
.FERR) is set. If enabled, the optional suspend interrupt is generated.
26.6.3. Additional Features
26.6.3.1. Linked Descriptors
A transaction can consist of either a single block transfer or of several block transfers. When a transaction
consist of several block transfers it is called linked descriptors.
illustrates how linked descriptors work. When the first block transfer is completed on
DMA channel 0, the DMAC fetches the next transfer descriptor which is pointed to by the value stored in
the Next Descriptor Address (
) register of the first transfer descriptor. Fetching the next
transfer descriptor (
) is continued until the last transfer descriptor. When the block transfer for
the last transfer descriptor is executed and
=0x00000000, the transaction is terminated. For
further details on how the next descriptor is fetched from SRAM, refer to section
Adding Descriptor to the End of a List
To add a new descriptor at the end of the descriptor list, create the descriptor in SRAM, with
=0x00000000 indicating that it is the new last descriptor in the list, and modify the
value of the current last descriptor to the address of the newly created descriptor.
Modifying a Descriptor in a List
In order to add descriptors to a linked list, the following actions must be performed:
Atmel SAM L22G / L22J / L22N [DATASHEET]
Atmel-42402E-SAM L22G / L22J / L22N_Datasheet_Complete-07/2016
445