The table below shows MCGOUTCLK frequency calculations using C1[FRDIV],
C5[PRDIV0], and C6[VDIV0] settings for each clock mode.
Table 25-17. MCGOUTCLK Frequency Calculation Options
Clock Mode
f
MCGOUTCLK
Note
FEI (FLL engaged internal)
(f
int
* F)
Typical f
MCGOUTCLK
= 21 MHz
immediately after reset.
FEE (FLL engaged external)
(f
ext
/ FLL_R) *F
f
ext
/ FLL_R must be in the range of
31.25 kHz to 39.0625 kHz
FBE (FLL bypassed external)
OSCCLK
OSCCLK / FLL_R must be in the
range of 31.25 kHz to 39.0625 kHz
FBI (FLL bypassed internal)
MCGIRCLK
Selectable between slow and fast
IRC
PEE (PLL engaged external)
(OSCCLK / PLL_R) * M
OSCCLK / PLL_R must be in the
range of 2 – 4 MHz
PBE (PLL bypassed external)
OSCCLK
OSCCLK / PLL_R must be in the
range of 2 – 4 MHz
BLPI (Bypassed low power internal)
MCGIRCLK
Selectable between slow and fast
IRC
BLPE (Bypassed low power external)
OSCCLK
1. FLL_R is the reference divider selected by the C1[FRDIV] bits, PLL_R is the reference divider selected by C5[PRDIV0]
bits, F is the FLL factor selected by C4[DRST_DRS] and C4[DMX32] bits, and M is the multiplier selected by C6[VDIV0]
bits.
This section will include three mode switching examples using an 4 MHz external
crystal. If using an external clock source less than 2 MHz, the MCG must not be
configured for any of the PLL modes (PEE and PBE).
25.5.3.1 Example 1: Moving from FEI to PEE mode: External Crystal =
4 MHz, MCGOUTCLK frequency = 48 MHz
In this example, the MCG will move through the proper operational modes from FEI to
PEE to achieve 48 MHz MCGOUTCLK frequency from 4 MHz external crystal
reference. First, the code sequence will be described. Then there is a flowchart that
illustrates the sequence.
1. First, FEI must transition to FBE mode:
a. C2 = 0x2C
• C2[RANGE] set to 2'b01 because the frequency of 4 MHz is within the high
frequency range.
Initialization / Application information
K22F Sub-Family Reference Manual , Rev. 3, 7/2014
560
Freescale Semiconductor, Inc.