CHAPTER 4 SETTING METHODS
This chapter describes how to set the option byte, vector table, stack pointer, watchdog timer, clock frequency, and
ports, as well as the main processing.
For how to set registers, refer to the user’s manual of each product (
,
,
,
For assembler instructions, refer to the
78K/0S Series Instructions User’s Manual
4.1 Option Byte Setting
The option byte must be set. The following items are set with the option byte.
(1) Selection of system clock source
(2) Control of low-speed internal oscillator oscillation
(3) Selection of P34/RESET pin function
(4) Specification of oscillation stabilization time on power application or after reset release (only when using crystal
or ceramic oscillation)
In this sample program, the option byte is set as described in
, mentioned later.
Figure 4-1. Option Byte Format
Address: 0080H
Note 1.
Stopping the low-speed internal oscillator oscillation, stopping watchdog timer operation, and setting
the clock frequency are performed after reset release. For details, refer to
(Note 2, Caution, and Remark are on the next page.)
Control of low-speed internal oscillator oscillation
Note 1
0
Oscillation is stopped by software setting
(LSRSTOP bit is set to 1).
1 Cannot
be
stopped.
1 DEFOS
TS1
DEFOS
TS0
1 RMCE
OSCSE
L1
OSCSE
L0
LIOCP
Selection of system clock source
Note 1
0
0 Crystal or ceramic oscillation clock (10 MHz (MAX.))
0
1 External clock input (10 MHz (MAX.))
1
x High-speed internal oscillation clock (8 MHz (TYP.))
Selection of P34/RESET pin function
0
Used as P34 (dedicated input port).
1
Used as a RESET pin.
Specification of oscillation stabilization time on power
application or after reset release
Note 2
0 0
2
10
/fx
0 1
2
12
/fx
1 0
2
15
/fx
1 1
2
17
/fx
Application Note U18752EJ2V0AN
8