Datasheet
Section 15 I
2
C Bus Interface2 (IIC2) (Option)
Rev.6.00 Mar. 18, 2009 Page 657 of 980
REJ09B0050-0600
No
Yes
Yes
Yes
RDRF=1 ?
No
Yes
RDRF=1 ?
The last receive
- 1?
Slave receive mode
Clear AAS in ICSR
Set ACKBT=0 in ICIER
Dummy read ICDRR
Read RDRF in ICSR
Read ICDRR
Set ACKBT=1 in ICIER
Read ICDRR
Read RDRF in ICSR
Read ICDRR
End
No
No
No
Yes
[1]
[2]
[3]
[4]
[5]
[6]
[7]
[8]
[9]
[10]
[1] Clear the flag AAS.
[2] Set the acknowledge for the transmit device.
[3] Dummy read ICDRR.
[4] Wait the reception end of 1 byte.
[5] Judge the (last receive - 1).
[6] Read the received data, and clear RDRF to 0.
[7] Set the acknowledge for the last byte.
[8] Read the received data of the (last byte - 1),
and clear RDRF to 0.
[9] Wait the reception end of the last byte.
[10] Read the received data of the last byte,
and clear RDRF to 0.
Additional information: When receiving one byte of data, execute step [1], and then step [7] omitting steps [2] to [6].
In step [8], dummy read ICDRR.
TDRE=0 ?
RDRF= 1?
Slave transmit mode
Figure 15.17 Sample Flowchart for Slave Receive Mode