English
Language : 

M16C28 Datasheet, PDF (78/423 Pages) Renesas Technology Corp – 16-BIT SINGLE-CHIP MICROCOMPUTER M16C FAMILY / M16C/Tiny SERIES
M16C/28 Group (M16C/28, M16C/28B)
7. Clock Generation Circuit
7.6.2.3 Pin Status During Wait Mode
The I/O port pins retain their status held just prior to wait mode.
7.6.2.4 Exiting Wait Mode
______
The microcomputer is moved out of wait mode by a hardware reset, NMI interrupt or peripheral func-
tion interrupt.
______
If the microcomputer is to be moved out of exit wait mode by a hardware reset or NMI interrupt, set the
peripheral function interrupt priority ILVL2 to ILVL0 bits to “0002” (interrupts disabled) before execut-
ing the WAIT instruction.
The peripheral function interrupts are affected by the CM02 bit. If CM02 bit is set to “0” (peripheral
function clocks not turned off during wait mode), peripheral function interrupts can be used to exit wait
mode. If CM02 bit is set to “1” (peripheral function clocks turned off during wait mode), the peripheral
functions using the peripheral function clocks stop operating, so that only the peripheral functions
clocked by external signals can be used to exit wait mode.
Table 7.4 lists the interrupts to exit wait mode.
Table 7.4 Interrupts to Exit Wait Mode
Interrupt
CM02=0
NMI interrupt
Can be used
Serial I/O interrupt
Can be used when operating
with internal or external clock
Multi-Master I2C
interrupt
key input interrupt
A/D conversion
interrupt
Timer A interrupt
Timer B interrupt
Can be used
Can be used
Can be used in one-shot mode
or single sweep mode
Can be used in all modes
Timer S interrupt
Can be used in all modes
INT interrupt
Can be used
CM02=1
Can be used
Can be used when operating
with external clock
(Do not use)
Can be used
(Do not use)
Can be used in event counter
mode or when the count
source is fC32
(Do not use)
Can be used
If the microcomputer is to be moved out of wait mode by a peripheral function interrupt, set up the
following before executing the WAIT instruction.
1. In the ILVL2 to ILVL0 bits of interrupt control register, set the interrupt priority level of the periph
eral function interrupt to be used to exit wait mode.
Also, for all of the peripheral function interrupts not used to exit wait mode, set the ILVL2 to ILVL0
bits to “0002” (interrupt disable).
2. Set the I flag to “1”.
3. Enable the peripheral function whose interrupt is to be used to exit wait mode.
In this case, when an interrupt request is generated and the CPU clock is thereby turned on, an
interrupt routine is executed.
The CPU clock turned on when exiting wait mode by a peripheral function interrupt is the same CPU
clock that was on when the WAIT instruction was executed.
Rev. 2.00 Jan. 31, 2007 page 58 of 385
REJ09B0047-0200