English
Language : 

MC9S08QG8 Datasheet, PDF (153/300 Pages) Freescale Semiconductor, Inc – 8-BIT HCS08 Central Processor Unit
Internal Clock Source (S08ICSV1)
— If entering FEE, set the reference divider and clear the IREFS bit to switch to the external
reference.
— The internal reference can optionally be kept running by setting the IRCLKEN bit. This is
useful if the application will switch back and forth between internal clock and external clock
modes. For minimum power consumption, leave the internal reference disabled while in an
external clock mode.
4. The CLKST bits can be monitored to determine when the mode switch has completed. If FEE was
selected, the bus clock will be stable in tAcquire milliseconds. The CLKST bits will not change when
switching from FEI to FEE.
10.5.1.2 Initialization Sequence, External Clock Mode to Internal Clock Mode
To change from FEE or FBE clock modes to FEI or FBI clock modes, follow this procedure:
1. If saved, copy the TRIM and FTRIM values from FLASH to the ICSTRM and ICSSC registers.
This needs to be done only once after POR.
2. Enable the internal clock reference by selecting FBI (CLKS = 0:1) or selecting FEI (CLKS = 0:0,
RDIV = 0:0:0, and IREFS = 1) in ICSC1.
3. Wait for the internal clock reference to stabilize. The typical startup time is given in Appendix A,
“Electrical Characteristics.”
4. Write to ICSC2 to disable the external clock.
— The external reference can optionally be kept running by setting the ERCLKEN bit. This is
useful if the application will switch back and forth between internal clock and external clock
modes. For minimum power consumption, leave the external reference disabled while in an
internal clock mode.
— If FBI will be the selected mode, also set the LP bit at this time to minimize power
consumption.
NOTE
The internal reference must be enabled and running before disabling the
external clock. Therefore it is imperative to execute steps 2 and 3 before
step 4.
5. The CLKST bits in the ICSSC register can be monitored to determine when the mode switch has
completed. The CLKST bits will not change when switching from FEE to FEI. If FEI was selected,
the bus clock will be stable in tAcquire milliseconds.
MC9S08QG8 and MC9S08QG4 Data Sheet, Rev. 1.01
Freescale Semiconductor
153