248
Transmitting: Figure 10.8 shows a typical flow chart for data transmission. After SCI3
initialization, follow the procedure below.
Start
Read bit TDRE in SSR
TDRE = 1?
Write transmit data in TDR
Continue
data transmission?
TEND = 1?
Read bit TEND in SSR
Break output?
Set PDR = 0 and PCR = 1
Clear bit TE in SCR3 to 0
End
1
2
3
1.
2.
3.
Read the serial status register (SRR),
and after confirming that bit TDRE = 1,
write transmit data in the transmit data
register (TDR). When data is written to
TDR, TDRE is automatically cleared to 0.
To continue transmitting data, first read
TDRE to confirm that it is set to 1, indicating
that data writing is enabled, then write the
next data to TDR. When data is written to
TDR, TDRE is automatically cleared to 0.
To output a break signal when transmission
ends, first set the port values PCR = 1 and
PDR = 0, then clear bit TE in SCR3 to 0.
No
Yes
No
No
Yes
No
Yes
Yes
Figure 10.8 Typical Data Transmission Flow Chart (Asynchronous Mode)