Datasheet

Chapter 7 Keyboard Interrupt (S08KBIV2)
MC9S08LC60 Series Data Sheet: Technical Data, Rev. 4
Freescale Semiconductor 99
7.3 Register Definition
The KBI includes three registers:
An 8-bit pin status and control register.
An 8-bit pin enable register.
An 8-bit edge select register.
Refer to the direct-page register summary in the Memory chapter for the absolute address assignments for
all KBI registers. This section refers to registers and control bits only by their names and relative address
offsets.
Some MCUs may have more than one KBI, so register names include placeholder characters to identify
which KBI is being referenced.
7.3.1 KBIx Status and Control Register (KBIxSC)
KBIxSC contains the status flag and control bits, which are used to configure the KBI.
7.3.2 KBIx Pin Enable Register (KBIxPE)
KBIxPE contains the pin enable control bits.
76543210
R 0 0 0 0 KBF 0
KBIE KBMOD
W KBACK
Reset: 0 0 0 0 0 0 0 0
= Unimplemented
Figure 7-3. KBIx Status and Control Register
Table 7-2. KBIxSC Register Field Descriptions
Field Description
7:4 Unused register bits, always read 0.
3
KBF
Keyboard Interrupt Flag — KBF indicates when a keyboard interrupt is detected. Writes have no effect on KBF.
0 No keyboard interrupt detected.
1 Keyboard interrupt detected.
2
KBACK
Keyboard Acknowledge — Writing a 1 to KBACK is part of the flag clearing mechanism. KBACK always reads
as 0.
1
KBIE
Keyboard Interrupt Enable — KBIE determines whether a keyboard interrupt is requested.
0 Keyboard interrupt request not enabled.
1 Keyboard interrupt request enabled.
0
KBMOD
Keyboard Detection Mode KBMOD (along with the KBEDG bits) controls the detection mode of the keyboard
interrupt pins.0Keyboard detects edges only.
1 Keyboard detects both edges and levels.