Format Of Interrupt Mask Flag Register; Format Of External Interrupt Mode Register 0 - NEC switch User Manual

Nec user's manua switch
Table of Contents

Advertisement

(2) Interrupt mask flag registers (MK0 and MK1)
The interrupt mask flag is used to enable/disable the corresponding maskable interrupt servicing.
MK0 and MK1 are set with a 1-bit or 8-bit memory manipulation instruction.
RESET input sets MK0 and MK1 to FFH.
<7>
<6>
Symbol
MK0
TMMK01 TMMK00 CSIMK10 KRMK00
7
<6>
0
MK1
USBTMMKUSBRTMK USBRDMKUSBSTMK USBREIF
XXMKX
0
Interrupt servicing enabled
1
Interrupt servicing disabled
Cautions
1. If the TMMK4 flag is read when the watchdog timer is used in watchdog timer mode 1
or 2, its value becomes undefined.
2. Because port 2 has an alternate function as an external interrupt input, when the
output level is changed by specifying the output mode of the port function, an
interrupt request flag is set. Therefore, the interrupt mask flag should be set to 1
before using the output mode.
(3) External interrupt mode register 0 (INTM0)
This register is used to set the valid edge of INTP0.
INTM0 is set with an 8-bit memory manipulation instruction.
RESET input sets INTM0 to 00H.
7
6
5
Symbol
INTM0
0
0
0
ES01
ES00
0
0
Falling edge
0
1
Rising edge
1
0
Setting prohibited
Both rising and falling edges
1
1
Cautions
1. Bits 0, 1 and 4 to 7 must be set to 0.
2. Before setting the INTM0 register, be sure to set xxMKx of the relevant interrupt mask
flag to 1 to disable interrupts. After that clear the interrupt mask flag (xxMKx = 0) to
enable interrupts after clearing the interrupt request flag(xxIFx = 0).
168
CHAPTER 11
INTERRUPT FUNCTIONS
Figure 11-3. Format of Interrupt Mask Flag Register
<5>
<4>
3
1
<5>
<4>
<3>
Interrupt servicing control
Figure 11-4. Format of External Interrupt Mode Register 0
4
3
2
1
0
ES01 ES00
0
User's Manual U12978EJ3V0UD
Address
2
<1>
<0>
1
PMK0
TMMK4
FFE4H
<2>
1
0
1
1
FFE5H
Address
After reset
0
0
FFECH
00H
INTP0 valid edge selection
After reset
R/W
FFH
R/W
FFH
R/W
R/W
R/W

Advertisement

Table of Contents
loading

Table of Contents