UM10850
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2016. All rights reserved.
User manual
Rev. 2.4 — 13 September 2016
414 of 464
NXP Semiconductors
UM10850
Chapter 30: LPC5410x Power profiles/Power control API
#define rom_driver_ptr (*(ROM) **) 0x0300 0200)
pPWRD = (PWRD *)(rom_driver_ptr->pPWRD);
30.4.1 Chip_POWER_SetPLL
This routine sets up the System PLL given the PLL input frequency and feedback
multiplier. Note that this API does not support special PLL operating modes. A library call
is available via LPCOpen that supports additional PLL features.
The Chip_POWER_SetPLL works by setting the PLL input pre-divider to 2. It then
determines what multiplier and post divider settings to use to get the requested frequency
(M * input freq) while keeping the PLL within its various operating limits.
30.4.1.1 Param0: multiplier
The input parameter multiplier (Param0) specifies the feedback multiplier for the PLL. The
range supported is from 1 to 16.
30.4.1.2 Param1: input_freq
The input frequency is the clock rate of the PLL input. The input frequency times the
multiplier must not be greater than 100 MHz.
30.4.1.3 Error or return codes
A return code of zero indicates that the operation was successful.
Table 466. Power API calls in LPCOpen power library
Function prototype
API description
Section
uint32_t Chip_POWER_SetPLL
(uint32_t multiply_by, uint32_t
input_freq)
;
Power API PLL configuration routine.This API sets up basic PLL operation.
uint32_t Chip_POWER_SetVoltage (0,
uint32_t desired_freq)
;
Power API internal voltage configuration routine.This API configures the
internal regulator for the desired active operating mode and frequency. Also
sets up corresponding flash wait states.
void Chip_POWER_EnterPowerMode
(POWER_MODE_T mode, uint32_t
peripheral_ctrl)
;
Power API power mode configuration routine.This API prepares the chip for
reduced power modes: sleep, deep-sleep, power-down or deep power-down
mode. Also allows selection of which peripherals are kept alive in the
reduced mode, and can therefore wake up the device from that mode.
Table 467. Chip_POWER_SetPLL routine
Routine
Chip_POWER_SetPLL
Prototype
uint32_t Chip_POWER_SetPLL (uint32_t multiply_by, uint32_t input_freq)
;
Input parameter
Param0:
multiplier (1 to 16)
Param1:
input_freq
Result
Error code. 0 = no error.
Description
Sets up the PLL for the requested multiplier and input frequency.
Table 468. Error codes
Return code
Error code
Description
0x000B 0002
ERR_CLK_INVALID_PARAM
Multiplier = 0 or (multiplier * input_freq) > 100MHz