22 System Clock
There are two clock sources for the system clock: external crystal oscillator and the built-in oscillator. The system
clock, Fosc, is obtained from one of these two clock sources through the clock divider, as shown in Figure 22-1.
The user can program the divider control bits SCKD2~SCKD0 (in PCON2 register) to get the desired system
clock.
The built-in oscillator is enabled by the hardware option ENROSC. Refer to Section 25: MCU’s Hardware Option.
Figure 22-1. Block Diagram of System Clock
XTAL1
Oscillating
Circuit
XTAL2
External
Crystal
Oscillator
1
0
OSC_Freq
Fosc
System Clock
Divider
System Clock
Built-in
Oscillator
1: Disable
0: Enable
SCKD2~SCKD0
ENROSC
Hareware Option
1: Disabled (default)
0: Enabled
PCON2 (Address=C7H, Power Control Register 2, Reset Value=00x0,0000B)
7
6
5
4
3
2
1
0
-
-
-
-
-
SCKD2 SCKD1 SCKD0
SCKD2~SCKD0: System clock divider control bits.
SCKD2 SCKD1 SCKD0
Fosc (System Clock)
OSC_Freq
0
0
0
0
1
1
1
1
0
0
1
1
0
0
1
1
0
1
0
1
0
1
0
1
OSC_Freq /2
OSC_Freq /4
OSC_Freq /8
OSC_Freq /16
OSC_Freq /32
OSC_Freq /64
OSC_Freq /128
22.1 Built-in Oscillator
The MPC82G516A has a built-in oscillator with the rough oscillating frequency of 6MHz. It can be used to replace
the external crystal oscillator in the application which doesn’t need an exact oscillating frequency. To enable the
built-in oscillator, the user should enable the hardware option ENROSC by a universal Writer/Programmer.
Typically, the oscillating frequency is about 6MHz at room temperature (25°C). And, the variation may be up to ±
30% over the temperature of –40°C to +85°C (+30% at –40°C, and –30% at +85°C). So, it is only for the
application which does not require an exact oscillating frequency.
MEGAWIN
MPC82G516A Data Sheet
114