Datasheet
CHAPTER 18 KEY INTERRUPT FUNCTION
User’s Manual U18698EJ1V0UD
455
18.3 Register Controlling Key Interrupt
(1) Key return mode register (KRM)
This register controls the KRM0, KRM3, and KRM4 bits using the KR0, KR3, and KR4 signals, respectively.
KRM is set by a 1-bit or 8-bit memory manipulation instruction.
Reset signal generation clears KRM to 00H.
Figure 18-2. Format of Key Return Mode Register (KRM)
0
Does not detect key interrupt signal
Detects key interrupt signal
KRMn
0
1
Key interrupt mode control (n = 0, 3, or 4)
KRM 0 0 KRM4 KRM3 0 0 KRM0
Address: FF6EH After reset: 00H R/W
Symbol
765432 0
Cautions 1. If any of the KRM0, KRM3, or KRM4 bits used is set to 1, set bit 0 (PU40) of the
corresponding pull-up resistor register 4 (PU4), or bits 2 or 3 (PU12 or PU13) of the
corresponding pull-up resistor register 1 (PU1) to 1.
2. If KRM is changed, the interrupt request flag may be set. Therefore, disable interrupts and
then change the KRM register. Clear the interrupt request flag and enable interrupts.
3. The bits not used in the key interrupt mode can be used as normal ports.
4. When using the P40/KR0/V
LC3 pin for the key interrupt function (KR0), set the LCD display
mode register (LCDM) to a setting other than the 1/4 bias method. When the pin is set to the
1/4 bias method, it is used as V
LC3.