English
Language : 

HD66727 Datasheet, PDF (53/97 Pages) Hitachi Semiconductor – Low-Power Dot-Matrix Liquid Crystal Display Controller/Driver with Key Scan Function
Table 28 Key Scan Cycles for Each Operating Frequency
Register
NL1
KF1 KF0
0 (1, 2 lines) 0
0
0 (1, 2 lines) 0
1
0 (1, 2 lines) 1
0
0 (1, 2 lines) 1
1
1 (3, 4 lines) 0
0
1 (3, 4 lines) 0
1
1 (3, 4 lines) 1
0
1 (3, 4 lines) 1
1
Note: * Reference value
Key Scan Cycle
Clock Cycle 160 kHz
160
(1.0 ms)*
320
(2.0 ms)*
640
(4.0 ms)*
1,280
(8.0 ms)*
320
2.0 ms
640
4.0 ms
1,280
8.0 ms
2,560
16.0 ms
120 kHz
(1.3 ms)*
(2.7 ms)*
(5.3 ms)*
(10.7 ms)*
2.7 ms
5.3 ms
10.7 ms
21.3 ms
80 kHz
2.0 ms
4.0 ms
8.0 ms
16.0 ms
(4.0 ms)*
(8.0ms)*
(16.0 ms)*
(32.0 ms)*
HD66727
40 kHz
4.0 ms
8.0 ms
16.0 ms
32.0 ms
(8.0ms)*
(16.0ms)*
(32.0ms)*
(64.0ms)*
In order to compensate for the mechanical features of the keys, such as chattering and noise and for the
key-strobe generation cycle and the pulse width of the HD66727, software should read the scanned data
two or three times in succession to obtain valid data. Multiple keypress combinations should also be
processed in software. Up to three keys can be pressed simultaneously. Note, however, that if the third key
is pressed on an intersection between the rows and columns of the first two keys pressed, incorrect data will
be sampled. For three-key input, the third key must be on a separate column and row.
The input pins KIN0 to KIN3 are pulled up to VCC with internal MOS transistors (see the Electrical
Characteristics section). External resistors may also be required to further pull up the voltages when the
internal pull-ups are insufficient for the desired noise margins or for a large key matrix.
Key Scan Data Transfer
The key-scanned data can be read by an MPU via a serial interface as shown in Figure 28. First, a start byte
should be transferred. After the HD66727 has received the start byte, the MPU reads scan data SD0 to SD3
from the SCAN0 register starting from the MSB. Similarly, the MPU reads data from SCAN1, SCAN2,
SCAN3, SCAN4, SCAN5, SCAN6, and SCAN7 in that order. After reading SCAN7, the MPU starts at
SCAN0 again. While reading the scanned data, the MPU also reads the scan flags (SF1 and SF0) and the
transfer flag (TF). The scan flags reflect the value of the scan cycle counter, which automatically
increments its value by one for each scan cycle from 00 to 11 (after 11, it is reset to 00). If the scan data is
read more than once to be confirmed, and the corresponding scan counter values are the same, the scan data
might have been erroneously latched into the scan register at the same timing; it should be reconfirmed as
required. Also, if the transfer flag is read as 1, the HD66727 has been read out while it is latching scan data
and is thus unstable; it should also be reconfirmed as required.
53