
EM358x
Rev. 0.4
97
8.6 UART - Universal Asynchronous Receiver / Transmitter
The SC1 UART is enabled by writing 1 to SC1_MODE. The SC2 serial controller does not include UART
functions.
The UART supports the following features:
Flexible baud rate clock (300 bps to 921.6 kbps)
Data bits (7 or 8)
Parity bits (none, odd, or even)
Stop bits (1 or 2)
False start bit and noise filtering
Receive and transmit FIFOs
Optional RTS/CTS flow control
Receive and transmit DMA channels
8.6.1
GPIO Usage
The UART uses two signals to transmit and receive serial data:
TXD (Transmitted Data) – serial data sent by the EM358x
RXD (Received Data) – serial data received by the EM358x
If RTS/CTS flow control is enabled, these two signals are also used:
nRTS (Request To Send) – indicates the EM358x is able to receive data
nCTS (Clear To Send) – inhibits sending data from the EM358x if not asserted
The GPIO pins assigned to these signals are shown in Table 8-10.
Table 8-10. UART GPIO Usage
TXD
RXD
nCTS
1
nRTS
1
Direction
Output
Input
Input
Output
GPIO Configuration
Alternate
Output (push-pull)
Input
Input
Alternate
Output (push-pull)
SC1 pin
PB1
PB2
PB3
PB4
1
only used if RTS/CTS hardware flow control is enabled.
8.6.2
Set Up and Configuration
The UART baud rate clock is produced by a programmable baud generator starting from the 24 Hz clock:
F
N
MHz
baud
2
24
The integer portion of the divisor, N, is written to the SC1_UARTPER register and the fractional part, F, to the
SC1_UARTFRAC register. Table 8-11 shows the values used to generate some common baud rates and their
associated clock frequency error. The UART requires an internal clock that is at least eight times the baud rate
clock, so the minimum allowable setting for SC1_UARTPER is 8.
Summary of Contents for EMBER EM358 series
Page 2: ...EM358x 2 Rev 0 4 ...
Page 7: ...EM358x Rev 0 4 7 ...