RL78/I1D
Operation state switching IAR
R01AN3597EJ0100 Rev.1.00
Page 6 of 42
Jan. 31, 2017
4. Software explanation
4.1. Outline of operation
In this sample code, the operation state of RL78/I1D is switched by the button pressing (INTP0 interrupt generation).
There are 8 kinds of operation states with combination of the flash operation mode and the regulator mode. After 8-time
external interrupt INTO0 generations, it returns back to the state same as after reset. The operation state is displayed by
the combination of turning on, turning off, and blinking LED. The fixed periodical interrupt processing triggered by the
12-bit interval timer updates the LED display. The transition to HS (high speed main) mode is executed when the VDD
voltage is 2.4V or more. In the case of VDD below 2.4V, the transition to the HS mode is not executed. LED is blinked
to inform the error.
Table 4.1 shows operation state detail and operation state transition.
Table 4.1
Operation state detail and operation state transition
Transition
state
State
LED1
LED2
Operation clock
Range
of
operation
voltage
Status of the
next
transition
0
(after
reset)
LV mode
Turning off
Turning on
HOCO: 4MHz
1.6V~3.6V
1
1
LS mode
(Normal
setting)
Turning on
Turning off
HOCO: 8MHz
1.8V~3.6V
2
2
LS mode
(low
consumption
setting)
High-speed
blinking
Turning off
MOCO: 4MHz
1.8V~3.6V
3
3
LS mode
(Normal
setting)
Turning on
Turning off
HOCO: 8MHz
1.8V~3.6V
4 or
4-Error
4
HS mode
Turning on
Turning on
HOCO: 16MHz
2.4V~3.6V
5
4-Error
LS mode
(Normal
setting)
Super-high-speed
blinking
Super-high-speed
blinking
HOCO: 8MHz
1.8V~3.6V
5
5
LS mode
(Normal
setting)
Turning on
Turning off
HOCO: 8MHz
1.8V~3.6V
6
6
LP mode
Low-speed
blinking
Turning off
MOCO: 1MHz
1.8V~3.6V
7
7
LS mode
(Normal
setting)
Turning on
Turning off
HOCO: 8MHz
1.8V~3.6V
0