
2-19
CPU
[Level interrupts]
Level interrupts are interrupts for which the interrupt level can be controlled through the interrupt enable (IE) and
interrupt mask (IM2 to IM0) bits in the PSW. Level interrupts are interrupts from the interrupt group controllers
external to the CPU (in other words, peripheral interrupts). There are 18 groups, or 35 interrupt factors.
Each interrupt group controller includes an interrupt control register (GnICR); the interrupt priority level can be set
independently for each interrupt group. It is also possible to set the same interrupt priority level for different
interrupt groups. If interrupts of the same priority level are generated simultaneously, the interrupts are accepted in
the sequence set by the hardware (the lower the interrupt group number, the higher the priority).
When a level interrupt is accepted, the hardware causes the program to branch to an address with the upper 16 bits
being "x'4000" and the lower 16 bits indicated by the interrupt vector address register IVARn corresponding to the
interrupt level.
The interrupt handler accesses IAGR to analyze the interrupt group, accesses GnICR (n = 2 to 19) to analyze the
interrupt factor, performs interrupt processing, cancels the interrupt factor, and then returns to the normal program
using the RTI instruction.
2.5.4
Interrupt Definition
When this microcontroller accepts an interrupt, first the sequences automatically processed by the hardware are
executed. Then control transfers to interrupt handler by the software and the interrupt handler is started up.
The interrupt processing sequences are described below.
(Interrupt processing sequences executed by the hardware)
1.
The PSW is saved to the stack (SP-8).
2.
The PC (return address) is saved to the stack (SP-4).
3.
The PSW is updated.
IE is cleared and the accepted interrupt level is set in IM2 to IM0. (IM2 to IM0 is undefined in case of non-
maskable interrupts.)
4.
The stack pointer is updated. (SP-8
→
SP)
5.
Control is transferred to the address corresponding to the accepted interrupt factor or the address comprised of
the interrupt vector address register (IVARn).
When an interrupt other than a reset interrupt is accepted, control is transferred to the address corresponding to the
interrupt factor or the address comprised of the interrupt vector address register. The processing listed below is then
performed at the branch destination in order to judge the interrupt factor in further detail.
See "2.5.3 Interrupt Types" for processing reset interrupts.
(Note) In General, Branch instructions (JMP instruction, etc.) are placed at the branch destination for reset interrupts,
then it branches to the initialization program.
Summary of Contents for MN103001G/F01K
Page 1: ...MICROCOMPUTER MN1030 MN103001G F01K LSI User s Manual Pub No 23101 050E ...
Page 2: ......
Page 4: ......
Page 6: ......
Page 8: ......
Page 9: ...Table of Contents List of Figures and Tables 0 ...
Page 26: ...xviii ...
Page 27: ...1 0 1 General Specifications ...
Page 35: ...2 CPU 2 ...
Page 57: ...3 Extension Instruction Specifications 3 ...
Page 96: ...Extension Instruction Specifications 3 40 ...
Page 97: ...4 Memory Modes 3 4 ...
Page 102: ...Memory Modes 4 6 ...
Page 103: ...5 Operating Mode 5 ...
Page 107: ...6 Clock Generator 6 13 ...
Page 111: ...7 Internal Memory 7 ...
Page 114: ...Internal Memory 7 4 ...
Page 115: ...8 Bus Controller BC 8 ...
Page 189: ...9 Interrupt Controller 9 ...
Page 220: ...Interrupt Controller 9 32 ...
Page 221: ...10 8 bit Timers 9 10 ...
Page 254: ...8 bit Timers 10 34 ...
Page 255: ...11 16 bit Timers 11 ...
Page 292: ...16 bit Timers 11 38 ...
Page 293: ...12 Watchdog Timer 11 12 ...
Page 302: ...Watchdog Timer 12 10 ...
Page 303: ...13 Serial Interface 13 ...
Page 354: ...Serial Interface 13 52 ...
Page 355: ...14 A D Converter 14 ...
Page 367: ...15 I O Ports 15 ...
Page 431: ...16 Internal Flash Memory 16 ...
Page 439: ...17 17 Ordering Mask ROM ...
Page 442: ...Ordering Mask ROM 17 4 ...
Page 443: ...Appendix ...