
412
Chapter 12
Asynchronous Serial Interface A (UARTA)
User’s Manual U16702EE3V2UD00
(5)
UARTAn status register (UAnSTR)
The UAnSTR register is an 8-bit register that indicates the transfer status of UARTAn and the con-
tents of a reception error.
This bit can be read or written in 8-bit or 1-bit units, but the UAnTSF bit can only be read. The
UAnPE, UAnFE, and UAnOVE bits can be read or written, but they can only be cleared by writing
0 to them, and cannot be set by writing 1 (if 1 is written to these bits, they hold the current status).
The following table shows the initialization conditions of these bits.
Figure 12-6:
UARTAn Status Register (UAnSTR) Format (1/2)
Remark:
n = 0 to 1
Register/Bit
Initialization Conditions
UAnSTR register
•
Reset input
•
UAnPWR bit of UAnCTL0 register = 0
UAnTSF bit
•
UAnTXE bit of UAnCTL0 register = 0
UAnPE, UAnFE, UAnOVE bits
•
Writing of 0
•
UAnRXE bit of UAnCTL0 register = 0
Address: UA0STR: FFFFFA04H, UA1STR: FFFFFA14H
After
Reset
Symbol
7
6
5
4
3
2
1
0
Address R/W
UAnSTR UAnTSF
0
0
0
0
UAnPE
UAnFE
UAnOVE
R/W
00H
UAnTSF
Transfer status flag
0
•
When UAnPWR bit of UAnCTL0 register = 0 or when UAnTXE bit of UAnCTL0 register = 0
•
If next transfer data is not in UAnTX after completion of transfer
1
Writing to UAnTX register
The UAnTSF bit is always 1 when transmission is executed continuously. Before initializing the transmission unit,
check that the UAnTSF bit = 0. If the transmission unit is initialized while the UAnTSF bit = 1, the transmit data
cannot be guaranteed.
UAnPE
Parity error flag
0
•
When UAnPWR bit of UAnCTL0 register = 0 or when UAnRXE bit of UAnCTL0 register = 0
•
When 0 is written to this bit
1
When the parity of the received data does not match the parity bit
•
The operation of the UAnPE bit differs depending on how the UAnPS1 and UAnPS0 bits of the UAnCTL0 reg-
ister are set.
•
Although the UAnPE bit can be read or written, it can only be cleared by writing 0, and cannot be set by writ-
ing 1. It holds the current status when 1 is written.
electronic components distributor