
R01UH0336EJ0102 Rev.1.02
Page 1177 of 1538
Jul 17, 2014
V850E2/PG4-L
Section 21 Clocked Serial Interface G (CSIG)
21.3.4
Data Transfer Modes
(1)
Trasmit-Only Mode
Setting CSIGnCTL0.CSIGnTXE = 1 and CSIGnCTL0.CSIGnRXE = 0 puts the
CSIG in transmit-only mode. After setting CSIGnCTL0.CSIGnTXE = 1,
transmission starts when transmit data is written in the CSIGnTX0W or
CSIGnTX0H register.
In master mode, transmission starts when transmit data is written in the
CSIGnTX0W or CSIGnTX0H register.
In slave mode, transmission starts on clock input to CSIGnTSCK after the
settings indicated above.
Caution
In case transmit-only mode has been entered after any reception mode, the
data in the CSIGnRX0 buffer becomes undefined after completion of the first
transmission. Consequently the reception register CSIGnRX0 has to be read
before changing to transmit-only mode.
(2)
Receive-Only Mode
Setting CSIGnCTL0.CSIGnTXE = 0 and CSIGnCTL0.CSIGnRXE = 1 puts the
CSIG in receive-only mode.
In master mode, once the CSIGnCTL0.CSIGnRXE is set to 1, reading from the
CSIGnRX0 register causes transfer to start. As long as
CSIGnBCTL0.CSIGnSCE = 1, reading from the receive data register
(CSIGnRX0) triggers further reception.
In slave mode, reception starts when the communication clock CSIGTSCK
from the master is received.
Note
In receive-only mode, avoid overwriting of data by reading previously received
data from the reception register (CSIGnRX0) before new data arrive.
Moreover, the communication start bit CSIGnBCTL0.CSIGnSCE has to be set
to 1 and then set back to 0 before reading the last received data from
CSIGnRX0.
The recommended procedure is:
1. Before starting the first receive operation, read CSIGnRX0 (dummy data)
with CSIGnBCTL0.CSIGnSCE = 1.
2. Wait for the reception interrupt CSIGnTIR.
3. Read CSIGnRX0 (received data).
If further data reception is to continue from step 2, continue to read all
received data every time reception is completed.
Before reading the last of the received data from CSIGnRX0, set
CSIGnBCTL0.CSIGnSCE = 0. For details, refer to Section 21.4 (6),
CSIGnBCTL0 - CSIG Receive-Only Mode Control Register 0.
(3)
Transmit/Receive Mode
Setting CSIGnCTL0.CSIGnTXE = 1 and CSIGnCTL0.CSIGnRXE = 1 puts the
CSIG in transmit/receive mode.
Data transfer (transmission and reception) starts when transmit data is written
to the CSIGnTX0W or CSIGnTX0H register.
Содержание V850 Series
Страница 1556: ...V850E2 PG4 L R01UH0336EJ0102 Back Cover ...