Multiple Interrupt Servicing - NEC mPD178054 Series User Manual

8-bit single-chip microcontrollers
Table of Contents

Advertisement

12.4.4 Multiple interrupt servicing

The acknowledgement of another interrupt request while an interrupt is being serviced is called multiple interrupt
servicing.
Multiple interrupt servicing does not take place unless the interrupts (except the non-maskable interrupt) are abled
to be acknowledged (IE = 1). Acknowledging another interrupt request is disabled (IE = 0) when one interrupt has
been acknowledged. Therefore, to enable multiple interrupt servicing, the EI flag must be set to 1 during interrupt
servicing, to enable other interrupts.
Multiple interrupt servicing may not occur even when interrupts are enabled. This is controlled by the priorities
of the interrupts. Although two types of priorities, default priority and programmable priority, may be assigned to an
interrupt, multiple interrupt servicing is controlled by using the programmable priority.
If an interrupt with the same priority as or a higher priority than the interrupt currently being serviced occurs, that
interrupt can be acknowledged and serviced. If an interrupt with a priority lower than that of the interrupt currently
being serviced occurs, that interrupt cannot be acknowledged and serviced.
An interrupt that is not acknowledged and serviced because it is disabled or it has a low priority is held pending.
This interrupt is acknowledged after servicing of the current interrupt has been completed and one instruction of the
main routine has been executed.
Multiple interrupt servicing is not enabled while a non-maskable interrupt is being serviced.
Table 12-4 shows the interrupts that can enter multiple interrupt servicing, and Figure 12-13 shows an example
of multiple interrupt servicing.
Table 12-4. Interrupt Request Enabled for Multiple Interrupt Servicing During Interrupt Servicing
Interrupt Being
Serviced
Non-maskable interrupt
Maskable interrupt
Software interrupt servicing
Remarks 1. E: Multiple interrupt servicing enabled
2. D: Multiple interrupt servicing disabled
3. ISP and IE are the flags contained in PSW
4. PR is a flag contained in PR0L and PR0R.
CHAPTER 12 INTERRUPT FUNCTIONS
Multiple Interrupt
Non-Maskable
Request
Interrupt
Request
D
ISP = 0
E
ISP = 1
E
E
ISP = 0: An interrupt with higher priority is being serviced
ISP = 1: An interrupt request is not accepted or an interrupt with lower priority is
being serviced
IE = 0:
Interrupt request acknowledgement is disabled
IE = 1:
Interrupt request acknowledgement is enabled
PR = 0: Higher priority level
PR = 1: Lower priority level
User's Manual U15104EJ2V0UD
Maskable Interrupt Request
PR = 0
PR = 1
IE = 1
IE = 0
IE = 1
D
D
D
E
D
D
E
D
E
E
D
E
IE = 0
D
D
D
D
173

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mpd178053Mpd178054Mpd178f054

Table of Contents