
11. Low Power Consumption
11.6
Low Power Consumption Modes
11.6.1
Sleep Mode
11.6.1.1
Transition to Sleep Mode
When the WAIT instruction is executed while the SBYCR.SSBY bit is 0, the CPU enters sleep mode. In sleep mode, the
CPU stops operating but the contents of its internal registers are retained. Other peripheral functions do not stop.
When the WDT is used, the WDT stops counting when sleep mode is entered.
Counting by the IWDT stops if a transition to sleep mode is made while the IWDT is being used in auto-start mode and
the OFS0.IWDTSLCSTP bit is 1. In the same way, counting by the IWDT stops if a transition to sleep mode is made
while the IWDT is being used in register start mode and the SLCSTP bit in IWDTCSTPR is 1.
Furthermore, counting by the IWDT continues if a transition to sleep mode is made while the IWDT is being used in
auto-start mode and the OFS0.IWDTSLCSTP bit is 0 (counting by the IWDT continues through transitions to low-
power-consumption modes). In the same way, counting by the IWDT continues if a transition to sleep mode is made
while the IWDT is being used in register start mode and the SLCSTP bit in IWDTCSTPR is 0.
To use sleep mode, make the following settings and then execute a WAIT instruction.
(1) Clear the PSW.I bit
*1 of the CPU to 0.
(2) Set the interrupt destination to be used for recovery from sleep mode to the CPU.
(3) Set the
priority*2 of the interrupt to be used for recovery from sleep mode to a level higher than the setting of the
PSW.IPL[3:0] bits
*1 of the CPU.
(4) Set the IERm.IENj bit
*2 for the interrupt to 1.
(5) For the last I/O register to which writing proceeded, read the register to confirm that the value written has been
reflected.
(6) Execute the WAIT instruction (this automatically sets the I bi
t*1 in the PSW of the CPU to 1).
Note 1.
Note 2.
11.6.1.2
Canceling Sleep Mode
Sleep mode is canceled by any interrupt, the reset signal from the RES# pin, a power-on reset, a voltage monitoring reset,
or a reset caused by an IWDT underflow.
Canceling by an interrupt
When an interrupt occurs, sleep mode is canceled and the interrupt exception handling starts. If a maskable interrupt
has been masked by the CPU (the priority
level*1 of the interrupt has been set to a value lower than that of the
PSW.IPL[3:0] bit
s*2 of the CPU), sleep mode is not canceled.
Canceling by the RES# pin
When the RES# pin is driven low, the LSI enters the reset state. When the RES# pin is driven high after the reset
signal is input for a predetermined time period, the CPU starts the reset exception handling.
Canceling by a power-on reset
Sleep mode is canceled by a power-on reset.
Canceling by a voltage monitoring reset
Sleep mode is canceled by a voltage monitoring reset from the voltage detection circuit.
Canceling by the independent watchdog timer
Sleep mode is canceled by an internal reset generated by an IWDT underflow. However, when such conditions are
set that stop IWDT counting in sleep mode (OFS0.IWDTSTRT = 0 and OFS0.IWDTSLCSTP = 1, or
OFS0.IWDTSTRT = 1 and IWDTCSTPR.SLCSTP = 1), the IWDT is stopped and sleep mode cannot be canceled
by the independent watchdog timer reset.
Note 1.
Note 2.