CMS32L051 User Manual |Chapter 12 Universal Serial Communication Unit
www.mcu.com.cn 379 / 703
12.5.8 Procedure for handling errors during 3-wire serial I/O communication (SSPI00,
SSPI01, SSPI10, SSPI11, SSPI20, SSPI21)
In 3-wire serial I/O (SSPI00, SSPI01, SSPI10, SSPI11, SSPI20 SSPI21), the processing steps
when an error occurs during communication are shown in Figure 12-69.
Figure 12-69 Steps to handle when an overflow error occurs
Read the serial data register
The BFFmn bit of the SSRmn register is 0 and
the channel n is in acceptable.
This is to prevent overflow errors
from ending the next reception
during mishandling.
Read the serial status register
mn (SSRmn)
The type of error is judged, and the
reading value is used to clear the
error flag.
Clear trigger register mn to the
serial flag
By writing the read value of the
SSRmn register directly to the
SDIRmn register, errors during read
operations can only be cleared.
Remark m: Unit number (m=0, 1) n: Channel number (n=0~3)mn=00~ 03, 10~11.