EasyManua.ls Logo

Cmsemicon CMS32L051 - Page 351

Default Icon
703 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
V1.2.2
CMS32L051 User Manual |Chapter 12 Universal Serial Communication Unit
www.mcu.com.cn 351 / 703
Figure 12-44 Flowchart of the master transmit and receive (single transmit and receive mode)
SSPI communication starts
configure transmit and receive data
enable interrupt
write transmit data into
SIOp(=SDRmn[7:0])
wait for transmitting and reception
completes.
relevant initial configuration, refer to diagram 19~42 (select transmission
completion interrupt)
regarding transmit and receive data, configure storage region and data count (via
software, any specified internal RAM storage region, transmit data pointer
communnication data count)
after clear interrupt request flag(Ifxx) and release
interrupt mask(MKxx), enable interrupt
output SDOp and SCLKp signal (start
communication) via writing into SIOp.
read received data and write into storage region, update receive data
pointer.
SCI initial configuration
transmission completion interrupt
read received data into
SIOp(=SDRmn[7:0])
RETURN
Transmit and receive completed?
disable interrupt (mask).
set STmn bit to 1.
communication completed.
No
Yes
main program
interrupt process program
main program
if transmission completion interrupt
occurs, jump to interrupt process
program.
if there is next data then continue
transmitting
from reserved region read and transmit
data and write to SIOp, update transmit
data pointer

Table of Contents

Related product manuals