![Freescale Semiconductor ColdFire MCF5211 Reference Manual Download Page 357](http://html1.mh-extra.com/html/freescale-semiconductor/coldfire-mcf5211/coldfire-mcf5211_reference-manual_2330619357.webp)
UART Modules
MCF5213 ColdFire® Integrated Microcontroller Reference Manual, Rev. 3
Freescale Semiconductor
21-27
To configure the UART for DMA requests:
1. Initialize the DMAREQC in the SCM to map the desired UART DMA requests to the desired DMA
channels. For example; setting DMAREQC[7:4] to 1000 maps UART0 receive DMA requests to
DMA channel 1; setting DMAREQC[11:8] to 1101 maps UART1 transmit DMA requests to DMA
channel 2; and so on. It is possible to independently map transmit based and receive based UART
DMA requests in the DMAREQC.
2. Disable interrupts using the UIMR register. The appropriate UIMR bits must be cleared so that
interrupt requests are disabled for those conditions for which a DMA request is desired. For
example; to generate transmit DMA requests from UART1, then UIMR1[TXRDY] should be
cleared. This will prevent TXRDY from generating an interrupt request while a transmit DMA
request is generated.
3. Configure the GPACR and appropriate PACR registers located in the SCM for DMA access to
IPSBAR space.
4. Initialize the DMA channel. The DMA should be configured for cycle steal mode and a source and
destination size of one byte. This will cause a single byte to be transferred for each UART DMA
request.
shows the DMA requests.
21.5.2
UART Module Initialization Sequence
shows the UART module initialization sequence.
Table 21-14. UART DMA Requests
Register
Bit
DMA Request
UISR
n
1
Receive DMA request
UISR
n
0
Transmit DMA request
Table 21-15. UART Module Initialization Sequence
Register
Setting
UCR
n
Reset the receiver and transmitter.
Reset the mode pointer (MISC[2–0] equals 0b001).
UIMR
n
Enable the desired interrupt sources.
UACR
n
Initialize the input enable control (IEC bit).
UCSR
n
Select the receiver and transmitter clock. Use timer as source if required.
UMR1
n
If preferred, program operation of receiver ready-to-send (RXRTS bit).
Select receiver-ready or FIFO-full notification (RXRDY/FFULL bit).
Select character or block error mode (ERR bit).
Select parity mode and type (PM and PT bits).
Select number of bits per character (B/Cx bits).