250
Start
Read bits OER, PER, and
FER in SSR
Read bit RDRF in SSR
Continue receiving?
Clear bit RE in SCR3 to 0
End
1
Yes
Yes
No
No
1. Read bits OER, PER, and
FER in the serial status
register (SSR) to
determine if a receive
error has occurred.
If a receive error has
occurred, receive error
processing is executed.
OER = 1?
FER = 1?
PER = 1?
Clear bits OER, PER, and
FER in SSR to 0
Overrun error
processing
Break?
Framing error
processing
Parity error
processing
Yes
Yes
Yes
No
No
No
Yes
No
4
Receive error processing
End receive error
processing
4
A
Start receive
error processing
A
OER + PER +
FER = 1
RDRF = 1?
No
Yes
2. Read the serial status register
(SSR), and after confirming
that bit RDRF = 1, read
received data from the receive
data register (RDR).
When RDR data is read, RDRF
is automatically cleared to 0.
3. To continue receiving data,
read bit RDRF and finish
reading RDR before the stop
bit of the present frame is
received.
When data is read from RDR,
RDRF is automatically cleared
to 0.
4. When a receive error occurs,
read bits OER, PER, and FER
in SSR to determine which
error (s) occurred.
After the necessary error
processing, be sure to clear
the above bits all to 0.
Data receiving cannot be resumed
while any of bits OER, PER, or
FER is set to 1.
When a framing error occurs,
a break can be detected by
reading the RXD pin value.
2
Read received data in RDR
3
Figure 10.10 Typical Serial Data Receiving Flow Chart in Asynchronous Mode