h8s-2161b Renesas Electronics Corporation., h8s-2161b Datasheet - Page 552

no-image

h8s-2161b

Manufacturer Part Number
h8s-2161b
Description
Renesas 16-bit Single-chip Microcomputer H8s Family/h8s/2100 Series
Manufacturer
Renesas Electronics Corporation.
Datasheet
Section 17 Keyboard Buffer Controller
Rev. 3.00 Mar 21, 2006 page 498 of 788
REJ09B0300-0300
(KBBR reception prohibited)
Set I/O inhibit (KCLKO = 0)
Set I/O inhibit (KCLKO = 1)
Set start bit (KDO = 0)
and KDI bits both
Set transmit data
Set KBIOE bit
Read KBCRH
Read KBCRH
Read KBCRH
Read KBCRH
(KDO = D(i))
KCLKI = 0?
KCLKI = 1?
KCLKI = 1?
KBE = 0
i = i + 1
KCLKI
i
Start
Wait
i = 0
1?
1
9?
Yes
Yes
Yes
Yes
Yes
(Continued on next page)
Figure 17.5 (1) Sample Transmit Processing Flowchart
No
No
No
No
No
KDO remains at 1
KCLKO remains at 0
KDO remains at 0
[1]
[2]
[3]
[4]
[5]
[6]
(Continued on
next page)
2
[1] Set the KBE bit to 1 in KBCRH.
[2] Read KBCRH, and if the KCLKI and
[3] Write 0 in the KBE bit (prohibit KBBR
[4] Write 0 in the KDO bit (set start bit).
[5] Write 1 in the KCLKO bit (clear I/O
[6] Read KBCRH, and when KCLKI = 0,
[7] After transmitting the stop bit, read
[8] Read KBCRH. Confirm that the KCLKI
The transmit operation can be continued
by repeating steps [2] to [8].
i = 0 to 7: Transmit data
i = 8: Parity bit
i = 9: Stop bit
KDI bits are both 1, write 0 in the
KCLKO bit (set I/O inhibit).
receive operation).
inhibit).
set the transmit data in the KDO bit
(LSB-first). Next, set the parity bit and
stop bit in the KDO bit.
KBCRL and confirm that KDI = 0
(receive completed notification from the
keyboard).
and KDI bits are both 1.

Related parts for h8s-2161b