
DR
AFT
DR
AFT
DRAFT
DR
D
RAFT
DRAFT
DRA
FT DRAF
D
RAFT DRAFT DRAFT DRAFT DRAFT D
DRAFT
D
RAFT DRA
FT DRAFT DRAFT DRAFT DRA
UM10360_0
© NXP B.V. 2009. All rights reserved.
User manual
Rev. 00.06 — 5 June 2009
38 of 808
NXP Semiconductors
UM10360
Chapter 4: LPC17xx Clocking and power control
5.11 Procedure for determining PLL0 settings
PLL0 parameter determination can be simplified by using a spreadsheet available from
NXP. To determine PLL0 parameters by hand, the following general procedure may be
used:
1. Determine if the application requires use of the USB interface, and whether it will be
clocked from PLL0. The USB requires a 50% duty cycle clock of 48 MHz within a very
small tolerance, which means that F
CCO
must be an even integer multiple of 48 MHz
(i.e. an integer multiple of 96 MHz), within a very small tolerance.
2. Choose the desired processor operating frequency (CCLK). This may be based on
processor throughput requirements, need to support a specific set of UART baud
rates, etc. Bear in mind that peripheral devices may be running from a lower clock
frequency than that of the processor (see
Section 4–7 “Clock dividers” on page 47
and
Section 4–8 “Power control” on page 50
). Find a value for F
CCO
that is close to a
multiple of the desired CCLK frequency, bearing in mind the requirement for USB
support in [1] above, and that lower values of F
CCO
result in lower power dissipation.
3. Choose a value for the PLL input frequency (F
IN
). This can be a clock obtained from
the main oscillator, the RTC oscillator, or the on-chip RC oscillator. For USB support,
the main oscillator should be used. Bear in mind that if PLL1 rather than PLL0 is used
to clock the USB subsystem, this affects the choice of the main oscillator frequency.
4. Calculate values for M and N to produce a sufficiently accurate F
CCO
frequency. The
desired M value -1 will be written to the MSEL0 field in PLL0CFG. The desired N value
-1 will be written to the NSEL0 field in PLL0CFG.
In general, it is better to use a smaller value for N, to reduce the level of multiplication that
must be accomplished by the CCO. Due to the difficulty in finding the best values in some
cases, it is recommended to use a spreadsheet or similar method to show many
possibilities at once, from which an overall best choice may be selected. A spreadsheet is
available from NXP for this purpose.
5.12 Examples of PLL0 settings
The following examples illustrate selecting PLL0 values based on different system
requirements.
Example 1)
Assumptions:
•
The USB interface will be used in the application and clocked from PLL0. The lowest
integer multiple of 96 MHz that falls within the PLL operating range (288 MHz) will be
targeted.
•
The desired CPU rate = 60 MHz.
•
An external 4 MHz crystal or clock source will be used as the system clock source.
Calculations:
M = (F
CCO
×
N) / (2
×
F
IN
)