13 UART (UART3)
S1C31D50/D51 TECHNICAL MANUAL
Seiko Epson Corporation
13-3
(Rev. 2.00)
13.3.2 Clock Supply in SLEEP Mode
When using the UART3 during SLEEP mode, the UART3 operating clock CLK_UART3_
n
must be configured so
that it will keep supplying by writing 0 to the CLGOSC.
xxxx
SLPC bit for the CLK_UART3_
n
clock source.
13.3.3 Clock Supply During Debugging
The CLK_UART3_
n
supply during debugging should be controlled using the UART3_
n
CLK.DBRUN bit.
The CLK_UART3_
n
supply to the UART3 Ch.
n
is suspended when the CPU enters debug state if the UART3_
n
CLK.DBRUN bit = 0. After the CPU returns to normal mode, the CLK_UART3_
n
supply resumes. Although the
UART3 Ch.
n
stops operating when the CLK_UART3_
n
supply is suspended, the output pin and registers retain the
status before the debug state was entered. If the UART3_
n
CLK.DBRUN bit = 1, the CLK_UART3_
n
supply is not
suspended and the UART3 Ch.
n
will keep operating in a debug state.
13.3.4 Baud Rate Generator
The UART3 includes a baud rate generator to generate the transfer (sampling) clock. The transfer rate is determined
by the UART3_
n
MOD.BRDIV, UART3_
n
BR.BRT[7:0], and UART3_
n
BR.FMD[3:0] bit settings. Use the follow-
ing equations to calculate the setting values for obtaining the desired transfer rate.
CLK_UART3 CLK_UART3
bps = —————————
BRT = BRDIV
×
(
—————— - FMD
)
- 1 (Eq. 13.1)
BRT + 1
bps
———— + FMD
BRDIV
Where
bps:
Transfer rate [bit/s]
CLK_UART3: UART3 operating clock frequency [Hz]
BRDIV:
Baud rate division ratio (1/16 or 1/4)
*
Selected by the UART3_
n
MOD.BRDIV bit
BRT: UART3_
n
BR.BRT[7:0] setting value (0 to 255)
FMD: UART3_
n
BR.FMD[3:0] setting value (0 to 15)
For the transfer rate range configurable in the UART3, refer to “UART Characteristics, Transfer baud rates U
BRT1
and U
BRT2
” in the “Electrical Characteristics” chapter.
13.4 Data Format
The UART3 allows setting of the data length, stop bit length, and parity function. The start bit length is fixed at one
bit.
Data length
With the UART3_
n
MOD.CHLN bit, the data length can be set to seven bits (UART3_
n
MOD.CHLN bit = 0) or
eight bits (UART3_
n
MOD.CHLN bit = 1).
Stop bit length
With the UART3_
n
MOD.STPB bit, the stop bit length can be set to one bit (UART3_
n
MOD.STPB bit = 0) or
two bits (UART3_
n
MOD.STPB bit = 1).
Parity function
The parity function is configured using the UART3_
n
MOD.PREN and UART3_
n
MOD.PRMD bits.
Table 13.4.1 Parity Function Setting
UART3_nMOD.PREN bit UART3_nMOD.PRMD bit
Parity function
1
1
Odd parity
1
0
Even parity
0
*
Non parity