Figure 13.20 Sample Flowchart For Operations In Slave Receive Mode (Hnds = 0) - Renesas H8S/2111B Hardware Manual

Bit single-chip microcomputer h8s family / h8s/2100 series
Table of Contents

Advertisement

Continuous Receive Operation:
Figure 13.20 shows the sample flowchart for the operations in slave receive mode (HNDS = 0).
Read AASX, AAS and ADZ in ICSR

Figure 13.20 Sample Flowchart for Operations in Slave Receive Mode (HNDS = 0)

Slave receive mode
Set MST = 0
and TRS = 0 in ICCR
Set ACKB = 0 in ICSR
Set HNDS = 0 in ICXR
Clear IRIC in ICCR
No
ICDRF = 1?
Yes
Read ICDR
Read IRIC in ICCR
No
IRIC = 1?
Yes
Clear IRIC in ICCR
Yes
AAS = 1
and ADZ = 1?
No
Read TRS in ICCR
Yes
TRS = 1?
No
No
(n-2)th-byte
reception?
Wait for one frame
Set ACKB = 1 in ICSR
No
ICDRF = 1?
Yes
Read ICDR
Read IRIC in ICCR
No
IRIC = 1?
Yes
ESTP = 1 or
STOP = 1?
No
Clear IRIC in ICCR
No
ICDRF = 1?
Yes
Read ICDR
Clear IRIC in ICCR
End
[1] Select slave receive mode.
[2] Read the receive data remaining unread.
[3] to [7] Wait for one byte to be received (slave address + R/W)
(Set IRIC at the rise of the 9th clock)
[8] Clear IRIC
General call address processing
* Description omitted
Slave transmit mode
* n: Address + total number of bytes received
[9] Wait for ACKB setting and set acknowledge data
for the last reception
(after the rise of the 9th clock of (n-1)th byte data)
[10] Read the receive data. The first read is a dummy read.
[11] Wait for one byte to be received
(Set IRIC at the rise of the 9th clock)
[12] Detect stop condition
[13] Clear IRIC
[14] Read the last receive data
[15] Clear IRIC
Rev. 1.00, 05/04, page 325 of 544

Advertisement

Table of Contents
loading

This manual is also suitable for:

Hd64f2111b

Table of Contents