Product Specs

Table Of Contents
50 UART Universal asynchronous receiver/
transmitter
Page
533
5
0
1
2
N-2
N-1
N
6
5
50.3 Shared resources
The UART shares registers and other resources with other peripherals that have the same ID as the UART.
Therefore, you must disable all peripherals that have the same ID as the UART before the UART can be
configured and used. Disabling a peripheral that has the same ID as the UART will not reset any of the
registers that are shared with the UART. It is therefore important to configure all relevant UART registers
explicitly to ensure that it operates correctly.
See the Instantiation table in Instantiation on page 24 for details on peripherals and their IDs.
50.4 Transmission
A UART transmission sequence is started by triggering the STARTTX task.
Bytes are transmitted by writing to the TXD register. When a byte has been successfully transmitted the
UART will generate a TXDRDY event after which a new byte can be written to the TXD register. A UART
transmission sequence is stopped immediately by triggering the STOPTX task.
If flow control is enabled a transmission will be automatically suspended when CTS is deactivated and
resumed when CTS is activated again, as illustrated in Figure 161: UART transmission on page 533.
A byte that is in transmission when CTS is deactivated will be fully transmitted before the transmission is
suspended. For more information, see Suspending the UART on page 534.
Figure 161: UART transmission
50.5 Reception
A UART reception sequence is started by triggering the STARTRX task.
The UART receiver chain implements a FIFO capable of storing six incoming RXD bytes before data is
overwritten. Bytes are extracted from this FIFO by reading the RXD register. When a byte is extracted from
the FIFO a new byte pending in the FIFO will be moved to the RXD register. The UART will generate an
RXDRDY event every time a new byte is moved to the RXD register.
When flow control is enabled, the UART will deactivate the RTS signal when there is only space for four
more bytes in the receiver FIFO. The counterpart transmitter is therefore able to send up to four bytes after
the RTS signal is deactivated before data is being overwritten. To prevent overwriting data in the FIFO, the
counterpart UART transmitter must therefore make sure to stop transmitting data within four bytes after the
RTS line is deactivated.
1
3
2
TXD
Lifeline
CTS
STARTTX
TXD = 0
TXDRDY
TXD = 1
TXDRDY
TXD = 2
TXDRDY
TXD = N-1
TXDRDY
TXD = N
TXDRDY
STOPTX