TMP91C824
91C824-50
(6) Attention
point
The instruction execution unit and the bus interface unit of this CPU operate independently.
Therefore, immediately before an interrupt is generated, if the CPU fetches an instruction that clears
the corresponding interrupt request flag, the CPU may execute the instruction that clears the
interrupt request flag(*1) between accepting and reading the interrupt vector. In this case, the CPU
reads the default vector 0008H and reads the interrupt vector address FFFF08H.
To avoid the avobe plogram, place instructions that clear interrupt request flags after a DI
instruction.
In the case of changing the value of the interrupt mask register <IFF2:0> by execution of POP SR
instruction, disable an interrupt by DI instruction before execution of POP SR instruction.
In addition, take care as the following 2 circuits are exceptional and demand special attention.
In Level Mode INT0 is not an edge-triggered interrupt. Hence, in Level
Mode the interrupt request flip-flop for INT0 does not function. The
peripheral interrupt request passes through the S input of the flip-flop and
becomes the Q output. If the interrupt input mode is changed from Edge
Mode to Level Mode, the interrupt request flag is cleared automatically.
INT0 Level Mode
If the CPU enters the interrupt response sequence as a result of INT0 going
from 0 to 1, INT0 must then be held at 1 until the interrupt response sequence
has been completed. If INT0 is set to Level Mode so as to release a Halt state,
INT0 must be held at 1 from the time INT0 changes from 0 to 1 until the Halt
state is released. (Hence, it is necessary to ensure that input noise is not
interpreted as a 0, causing INT0 to revert to 0 before the Halt state has been
released.)
When the mode changes from Level Mode to Edge Mode, interrupt request
flags which were set in Level Mode will not be cleared. Interrupt request
flags must be cleared using the following sequence.
DI
LD (IIMC), 00H; Switches interrupt input mode from Level Mode to
Edge Mode.
LD (INTCLR), 0AH; Clears interrupt request flag.
EI
INTRX
The interrupt request flip-flop can only be cleared by a Reset or by reading
the Serial Channel Receive Buffer. It cannot be cleared by an instruction.
(note): The following instructions or pin input state changes are equivalent to instructions that clear the
interrupt request flag.
INT0: Instructions which switch to Level Mode after an interrupt request has been
generated in Edge Mode.
The pin input change from High to Low after interrupt request has been generated
in Level Mode. (H
→
L)
INTRX: Instruction which read the Receive Buffer