7 OSCILLATOR (OSC)
S1C17704 TECHNICAL MANUAL
EPSON
7-5
7.4 Switching the System Clock
The OSC module allows software to switch the system clock between the OSC3 and OSC1 clocks. Current
consumption can be reduced by disabling the OSC3 oscillation after the system clock is switched to OSC1.
The following shows the control procedure:
OSC3 to OSC1
1. Set OSC1EN (D1/OSC_CTL register) to 1 to start the OSC1 oscillation if it is disabled.
∗
OSC1EN
: OSC1 Enable Bit in the Oscillation Control (OSC_CTL) Register (D1/0x5061)
2. Set CLKSRC (D0/OSC_SRC register) to 1 to switch the system clock from OSC3 to OSC1.
∗
CLKSRC
: System Clock Source Select Bit in the Clock Source Select (OSC_SRC) Register (D0/0x5060)
3. If the application does not need the peripheral modules clocked with OSC3 to operate, set OSC3EN (D0/
OSC_CTL register) to 0 to stop the OSC3 oscillation.
∗
OSC3EN
: OSC3 Enable Bit in the Oscillation Control (OSC_CTL) Register (D0/0x5061)
Notes
: • When the system clock is switched from OSC3 to OSC1 immediately after the OSC1 oscillator
starts oscillating, the system clock is halted until the OSC1 clock is activated (256 OSC1
clock-cycle period).
• The OSC3 oscillation cannot be stopped before switching the system clock to OSC1.
OSC1 to OSC3
1. Set a stable oscillation wait time (see Table 7.2.2) longer than the OSC3 oscillation start time using
OSC3WT[1:0] (D[5:4]/OSC_CTL register). (This control is not necessary if it has been set already.)
∗
OSC3WT[1:0]
: OSC3 Wait Cycle Select Bits in the Oscillation Control (OSC_CTL) Register (D[5:4]/0x5061)
2. Set OSC3EN (D0/OSC_CTL register) to 1 to start the OSC3 oscillation if it is disabled. The OSC3 clock is
not supplied to the system until the wait time set in OSC3WT[1:0] (D[5:4]/OSC_CTL register) has elapsed
after the OSC3 oscillator starts oscillating.
3. Set CLKSRC (D0/OSC_SRC register) to 0 to switch the system clock from OSC1 to OSC3.
4. If the application does not need the peripheral modules clocked with OSC1 to operate, set OSC1EN (D1/
OSC_CTL register) to 0 to stop the OSC1 oscillation.
Notes
: • Skip Steps 1 and 2 when the OSC2 oscillator circuit is operating.
• The OSC3 oscillation start time varies depending on the resonator and externally attached
parts. Set the stable oscillation wait time with a safety margin. Refer to the oscillation start time
example described in Chapter 26, “Electrical Characteristics.”
• The OSC1 oscillation cannot be stopped before switching the system clock to OSC3.
Содержание S1C17704
Страница 1: ...TECHNICAL MANUAL S1C17704 CMOS 16 BIT SINGLE CHIP MICROCOMPUTER ...
Страница 22: ...1 OVERVIEW 1 10 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 42: ...3 MEMORY MAP BUS CONTROL 3 12 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 82: ...6 INTERRUPT CONTROLLER ITC 6 26 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 108: ...8 CLOCK GENERATOR CLG 8 8 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 112: ...9 PRESCALER PSC 9 4 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 138: ...10 I O PORTS P 10 26 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 156: ...11 16 BIT TIMERS T16 11 18 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 208: ...14 8 BIT OSC1 TIMER T8OSC1 14 16 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 234: ...16 STOPWATCH TIMER SWT 16 14 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 242: ...17 WATCHDOG TIMER WDT 17 8 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 264: ...18 UART 18 22 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 300: ...20 I2C 20 20 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 320: ...21 REMOTE CONTROLLER REMC 21 20 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 360: ...24 ON CHIP DEBUGGER DBG 24 6 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 362: ...25 BASIC EXTERNAL WIRING DIAGRAM 25 2 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...