Peripheral DMA
UG0331 User Guide Revision 15.0
266
9.2.1.2
8-Channel DMA Controller
The 8-channel DMA controller consists of eight instances of a single DMA channel, as shown in the
preceding figure. Each channel can be configured to perform 8-bit, 16-bit, or 32-bit data transfers from
the peripheral to memory, memory to peripheral, and memory to memory. Each DMA channel supports
Ping-pong mode for continuous data transfer. To enable and use PDMA services, the AHB bus master
matrix must configure the following 32-bit registers.
•
•
•
•
CHANNEL_x_BUFFER_A_TRANSFER_COUNT
•
•
•
CHANNEL_x_BUFFER_B_TRANSFER_COUNT
If bidirectional DMA of peripheral to memory (receive) and memory to peripheral (transmit) is desired,
two channels must be programmed appropriately. In particular, the TRANSFER_SIZE fields in both the
registers must be programmed identically. The PDMA performs the correct
byte lane adjustments appropriate to the address being used on the AHB. Efficient use of memory
storage is achieved in this manner, even if only performing byte or 16-bit accesses to or from a
peripheral.For example, when the PDMA is accessing peripherals, the lowest 8 or 16 bits of the data bus
are always used for 8-bit or 16-bit transfers. For 32-bit transfers, the full 32-bits are used. It is possible to
configure the data width of a transfer to be independent of the address increment. The address
increment at both ends of the DMA transfer can be different, which is required when reading from a
peripheral holding register (single address) and writing to memory incrementally (many addresses).
Sixteen possible channels are available to the PDMA, as listed below. Only eight are used
simultaneously.
•
MMUART_0 to any MSS memory-mapped location
•
Any MSS memory-mapped location to MMUART_0
•
MMUART_1 to any MSS memory-mapped location
•
Any MSS memory-mapped location to MMUART_1
•
SPI_0 to any MSS memory-mapped location
•
Any MSS memory-mapped location to SPI_0
•
SPI_1 to any MSS memory-mapped location
•
Any MSS memory-mapped location to SPI_1
•
FPGA fabric peripheral on FIC_0 to any MSS memory-mapped location
•
Any MSS memory-mapped location to FPGA fabric peripheral on FIC_0
•
CAN to any MSS memory-mapped location
•
Any MSS memory-mapped location to CAN
•
FPGA fabric peripheral on FIC_1 to any MSS memory-mapped location
•
Any MSS memory-mapped location to FPGA fabric peripheral on FIC_1
•
COMM_BLK to any MSS memory-mapped location
•
Any MSS memory-mapped locations to COMM_BLK
9.2.1.2.1
Ping-Pong Mode
Ping-pong mode is a dual buffering scheme for continuous stream of operation. There are two buffers
(Buffer A and Buffer B) associated with each DMA channel for ping-pong operation. This removes the
real-time constraint on the firmware of having to service the DMA channel in real time, which would exist
if there were only one DMA buffer per channel.
To begin a transaction, source address, destination address, and transfer size in bytes of buffer A and
buffer B are to be configured by the AHB bus matrix master (such as Cortex-M3 firmware). The following
figure shows the sequence of operations that must be performed by firmware for ping-pong operation on
a configured DMA channel. The channel control register (
) is configured initially
before enabling ping-pong operation.
Содержание SmartFusion2 MSS
Страница 1: ...UG0331 User Guide SmartFusion2 Microcontroller Subsystem ...
Страница 166: ...Cortex M3 Processor Reference Material UG0331 User Guide Revision 15 0 132 ...
Страница 200: ...Embedded NVM eNVM Controllers UG0331 User Guide Revision 15 0 166 Figure 87 System Builder Window ...
Страница 407: ...Universal Serial Bus OTG Controller UG0331 User Guide Revision 15 0 373 ...
Страница 806: ...Fabric Interface Controller UG0331 User Guide Revision 15 0 772 Figure 345 FIC Master AHB Lite Subsystem ...