This document describes the universal asynchronous receiver/transmitter (UART) peripheral in the
TMS320DM643x Digital Media Processor (DMP) .
Notational Conventions
This document uses the following conventions.
•Hexadecimal numbers are shown with the suffix h. For example, the following number is 40
hexadecimal (decimal 64): 40h.
•Registers in this document are shown in figures and described in tables.
– Each register figure shows a rectangle divided into fields that represent the fields of the register.
Each field is labeled with its bit name, its beginning and ending bit numbers above, and its
read/write properties below. A legend explains the notation used for the properties.
– Reserved bits in a register figure designate a bit that is used for future device expansion.
Related Documentation From Texas Instruments
The following documents describe the TMS320DM643x Digital Media Processor (DMP). Copies of these
documents are available on the Internet at www.ti.com. Tip: Enter the literature number in the search box
provided at www.ti.com.
The current documentation that describes the DM643x DMP, related peripherals, and other technical
collateral, is available in the C6000 DSP product folder at: www.ti.com/c6000.
SPRU978 — TMS320DM643x DMP DSP Subsystem Reference Guide. Describes the digital signal
processor (DSP) subsystem in the TMS320DM643x Digital Media Processor (DMP).
Preface
SPRU997C–December 2009
Read This First
SPRU983 — TMS320DM643x DMP Peripherals Overview Reference Guide. Provides an overview and
briefly describes the peripherals available on the TMS320DM643x Digital Media Processor (DMP).
SPRAA84 — TMS320C64x to TMS320C64x+ CPU Migration Guide. Describes migrating from the
Texas Instruments TMS320C64x digital signal processor (DSP) to the TMS320C64x+ DSP. The
objective of this document is to indicate differences between the two cores. Functionality in the
devices that is identical is not included.
SPRU732 — TMS320C64x/C64x+ DSP CPU and Instruction Set Reference Guide. Describes the CPU
architecture, pipeline, instruction set, and interrupts for the TMS320C64x and TMS320C64x+ digital
signal processors (DSPs) of the TMS320C6000 DSP family. The C64x/C64x+ DSP generation
comprises fixed-point devices in the C6000 DSP platform. The C64x+ DSP is an enhancement of
the C64x DSP with added functionality and an expanded instruction set.
SPRU871 — TMS320C64x+ DSP Megamodule Reference Guide. Describes the TMS320C64x+ digital
signal processor (DSP) megamodule. Included is a discussion on the internal direct memory access
(IDMA) controller, the interrupt controller, the power-down controller, memory protection, bandwidth
management, and the memory and cache.
This document describes the universal asynchronous receiver/transmitter (UART) peripheral in the
TMS320DM643x Digital Media Processor (DMP) .
1.1Purpose of the Peripheral
The UART peripheral is based on the industry standard TL16C550 asynchronous communications
element, which in turn is a functional upgrade of the TL16C450. Functionally similar to the TL16C450 on
power up (single character or TL16C450 mode), the UART can be placed in an alternate FIFO
(TL16C550) mode. This relieves the CPU of excessive software overhead by buffering received and
transmitted characters. The receiver and transmitter FIFOs store up to 16 bytes including three additional
bits of error status per byte for the receiver FIFO.
The UART performs serial-to-parallel conversions on data received from a peripheral device and
parallel-to-serial conversion on data received from the CPU. The CPU can read the UART status at any
time. The UART includes control capability and a processor interrupt system that can be tailored to
minimize software management of the communications link.
The UART includes a programmable baud generator capable of dividing the UART input clock by divisors
from 1 to 65 535 and producing a 16 × reference clock for the internal transmitter and receiver logic. For
detailed timing and electrical specifications for the UART, see the device specific data manual.
User's Guide
SPRU997C–December 2009
1.2Features
The UART peripheral has the following features:
•Programmable baud rates up to 128 kbps (frequency pre-scale values from 1 to 65535)
•Fully programmable serial interface characteristics:
– 5, 6, 7, or 8-bit characters
– Even, odd, or no PARITY bit generation and detection
– 1, 1.5, or 2 STOP bit generation
•16-byte depth transmitter and receiver FIFOs:
– The UART can be operated with or without the FIFOs
– 1, 4, 8, or 14 byte selectable receiver FIFO trigger level for autoflow control and DMA
•DMA signaling capability for both received and transmitted data
•CPU interrupt capability for both received and transmitted data
•Operates in little-endian mode
•False START bit detection
•Line break generation and detection
•Internal diagnostic capabilities:
– Loopback controls for communications link fault isolation
– Break, parity, overrun, and framing error simulation
•Programmable autoflow control using CTS and RTS signals (not supported on all UARTs. See the
device-specific data manual for supported features.)
•Modem control functions using CTS and RTS signals (not supported on all UARTs. See the
device-specific data manual for supported features.)
Table 1 summarizes the capabilities supported on the UART. Note that the number of UARTs and their
supported features vary on each device, see the device-specific data manual for more details.
FeatureSupport
5, 6, 7 or 8-bit charactersSupported
Even, odd, or no PARITY bitSupported
1, 1.5, or 2 STOP bit generationSupported
Line break generation and detectionSupported
Internal loop backSupported
DMA sync events for both received and transmitted dataSupported
1, 4, 8, or 14 byte selectable receiver FIFO trigger levelSupported
Polling/InterruptSupported
Max speed 128 kbpsSupported
Modem control functions using CTS and RTSSupported
Autoflow control using CTS and RTSSupported
DTR and DSRNot supported
Ring indicationNot supported
Carrier detectionNot supported
Single-character transfer mode (mode 0) in DMA modeNot supported
(1)
www.ti.com
Table 1. UART Supported Features/Characteristics by Instance
(1)
(1)
Not supported on all UARTs. See the device-specific data manual for supported features.
1.3Functional Block Diagram
A functional block diagram of the UART is shown in Figure 1.
1.4Industry Standard(s) Compliance Statement
The UART peripheral is based on the industry standard TL16C550 asynchronous communications
element, which is a functional upgrade of the TL16C450. Any deviations in supported functions are
indicated in Table 1.
The information in this document assumes the reader is familiar with these standards.
The UART bit clock is sourced from the PLLC1 AUXCLK. It supports up to 128 kbps maximum data rate.
Figure 2 is a conceptual clock generation diagram for the UART. The processor clock generator receives
a signal from an external clock source and produces a UART input clock with a programmed frequency.
The UART contains a programmable baud generator that takes an input clock and divides it by a divisor in
the range between 1 and (216- 1) to produce a baud clock (BCLK). The frequency of BCLK is sixteen
times (16 ×) the baud rate; each received or transmitted bit lasts 16 BCLK cycles. When the UART is
receiving, the bit is sampled in the 8th BCLK cycle. The formula to calculate the divisor is:
Two 8-bit register fields (DLH and DLL), called divisor latches, hold this 16-bit divisor. DLH holds the most
significant bits of the divisor, and DLL holds the least significant bits of the divisor. For information about
these register fields, see Section 3. These divisor latches must be loaded during initialization of the UART
in order to ensure desired operation of the baud generator. Writing to the divisor latches results in two wait
states being inserted during the write access while the baud generator is loaded with the new value.
Figure 3 summarizes the relationship between the transferred data bit, BCLK, and the UART input clock.
Example baud rates and divisor values relative to a 27-MHz UART input clock are shown in Table 2.
The UARTs utilize a minimal number of signal connections to interface with external devices. The UART
signal descriptions are included in Table 3. Note that the number of UARTs and their supported features
vary on each device, see the device-specific data manual for more details.
Signal Name
UTXDnOutputSerial data transmit
URXDnInputSerial data receive
UCTSnInputClear-to-Send handshaking signal
URTSnOutputRequest-to-Send handshaking signal
(1)
The value n indicates the applicable UART; that is, UART0, UART1, etc.
(1)
Signal TypeFunction
2.3Pin Multiplexing
On the DM643x DMP extensive pin multiplexing is used to accommodate the largest number of peripheral
functions in the smallest possible package. Pin multiplexing is controlled using a combination of hardware
configuration at device reset and software programmable register settings. Refer to the device-specific
data manual to determine how pin multiplexing affects the UART.
2.4Protocol Description
www.ti.com
Table 3. UART Signal Descriptions
2.4.1Transmission
The UART transmitter section includes a transmitter hold register (THR) and a transmitter shift register
(TSR). When the UART is in the FIFO mode, THR is a 16-byte FIFO. Transmitter section control is a
function of the UART line control register (LCR). Based on the settings chosen in LCR, the UART
transmitter sends the following to the receiving device:
•1 START bit
•5, 6, 7, or 8 data bits
•1 PARITY bit (optional)
•1, 1.5, or 2 STOP bits
2.4.2Reception
The UART receiver section includes a receiver shift register (RSR) and a receiver buffer register (RBR).
When the UART is in the FIFO mode, RBR is a 16-byte FIFO. Receiver section control is a function of the
UART line control register (LCR). Based on the settings chosen in LCR, the UART receiver accepts the
following from the transmitting device:
•1 START bit
•5, 6, 7, or 8 data bits
•1 PARITY bit (optional)
•1 STOP bit (any other STOP bits transferred with the above data are not detected)