![]() |
MCUXpresso SDK API Reference Manual
Rev. 0
NXP Semiconductors
|
Power driver provides APIs to control peripherals power and control the system power mode.
Macros | |
| #define | FSL_SDK_ENABLE_DRIVER_POWER_CONTROL (1) |
| Enable power control. | |
Driver version | |
| #define | FSL_POWER_DRIVER_VERSION (MAKE_VERSION(2, 0, 3)) |
| power driver version 2.0.3. More... | |
SYSCON Power Configuration | |
| static void | POWER_EnablePD (pd_bit_t en) |
| API to enable PDRUNCFG bit in the Syscon. More... | |
| static void | POWER_DisablePD (pd_bit_t en) |
| API to disable PDRUNCFG bit in the Syscon. More... | |
| static void | POWER_EnableFlashRemap (bool enable) |
| API to enable flash remap feature for deep sleep mode. More... | |
ARM core Power Configuration | |
| static void | POWER_EnableDeepSleep (void) |
| API to enable deep sleep bit in the ARM Core. More... | |
| static void | POWER_DisableDeepSleep (void) |
| API to disable deep sleep bit in the ARM Core. More... | |
PMU functionality | |
| void | POWER_EnterSleep (void) |
| API to enter sleep power mode. More... | |
| void | POWER_EnterDeepSleep (void) |
| API to enter deep sleep power mode. More... | |
| void | POWER_EnterDeepPowerDownMode (void) |
| API to enter deep power down mode. More... | |
| uint32_t | POWER_ReadPmuReg (void *regAddr) |
| API to read PMU register. More... | |
| void | POWER_WritePmuReg (void *regAddr, uint32_t regValue) |
| API to write PMU register. More... | |
| void | POWER_SetPmuRegBit (void *regAddr, uint32_t mask) |
| API to set PMU register bit. More... | |
| void | POWER_ClrPmuRegBit (void *regAddr, uint32_t mask) |
| API to clr PMU register bit. More... | |
| static void | POWER_EnablePmuInterrupt (uint32_t mask, bool enable) |
| API to enable PMU interrupt. More... | |
| static void | POWER_SetRetainData (power_gen_reg_t index, uint32_t data) |
| API to retore data to general purpose register which can be retain during deep power down mode. More... | |
| static uint32_t | POWER_GetRetainData (power_gen_reg_t index) |
| API to get data from general purpose register which retain during deep power down mode. More... | |
| static uint32_t | POWER_GetSleepModeFlag (void) |
| API to get sleep mode flag. More... | |
| static void | POWER_ClrSleepModeFlag (void) |
| API to clear sleep mode flag. | |
| static uint32_t | POWER_GetDeepPowerDownModeFlag (void) |
| API to get deep power down mode flag. More... | |
| static uint32_t | POWER_GetDeepPowerDownWakeupSrc (void) |
| API to get deep power down mode exit source. More... | |
| static void | POWER_ClrDeepPowerDownModeFlag (void) |
| API to clear deep power down mode flag. | |
| static void | POWER_EnableAutoPowerSwitch (bool enable) |
| API to enable auto power mode switch. More... | |
| static void | POWER_EnableAutoBatterySwitch (bool enable) |
| API to enable auto battery switch. More... | |
| static void | POWER_EnableDetectBrownOut (bool enable) |
| API to enable detection of VDD_ALON is falls below the threshold level(1.8v) More... | |
| static void | POWER_EnableWakeupPinForDeepPowerDown (power_dpd_wakeup_pin_t pin, bool enable) |
| API to enable detection of VDD_ALON is falls below the threshold level(1.8v) More... | |
| static bool | POWER_GetPmuAccessReadyStat (void) |
| API to get PMU access ready status. More... | |
| void | POWER_SelectPowerSource (power_src_sel_t sel) |
| API to select power source. More... | |
PMU status | |
| static uint32_t | PMU_GetStatus (void) |
| API to get PMU status,. More... | |
| static uint32_t | PMU_GetRawIntStatus (void) |
| API to get PMU raw interrupt status,. More... | |
| static uint32_t | PMU_GetIntStatus (void) |
| API to get PMU interrupt status. More... | |
| static void | PMU_ClrInterruptStatus (uint32_t mask) |
| API to clear PMU interrupt status. More... | |
| #define FSL_POWER_DRIVER_VERSION (MAKE_VERSION(2, 0, 3)) |
| enum pd_bit_t |
| enum power_gen_reg_t |
| enum power_src_sel_t |
| enum _power_status |
|
inlinestatic |
Note that enabling the bit powers down the peripheral
| en | peripheral for which to enable the PDRUNCFG bit |
|
inlinestatic |
Note that disabling the bit powers up the peripheral
| en | peripheral for which to disable the PDRUNCFG bit |
|
inlinestatic |
| enable,: | true is enable remap feature, false is disable the feature. |
|
inlinestatic |
|
inlinestatic |
| void POWER_EnterSleep | ( | void | ) |
| void POWER_EnterDeepSleep | ( | void | ) |
| void POWER_EnterDeepPowerDownMode | ( | void | ) |
| uint32_t POWER_ReadPmuReg | ( | void * | regAddr | ) |
| regAddr | address of PMU register. |
| void POWER_WritePmuReg | ( | void * | regAddr, |
| uint32_t | regValue | ||
| ) |
| regAddr | address of PMU register. |
| regValue | value to write. |
| void POWER_SetPmuRegBit | ( | void * | regAddr, |
| uint32_t | mask | ||
| ) |
| regAddr | address of PMU register. |
| mask | bit mask. |
| void POWER_ClrPmuRegBit | ( | void * | regAddr, |
| uint32_t | mask | ||
| ) |
| regAddr | address of PMU register. |
| mask | bit mask. |
|
inlinestatic |
| mask | interrupt mask. |
| enable | true is enable, false is disable. |
|
inlinestatic |
Note the kPMU_GenReg4 can retore 3 byte data only, so the general purpose register can store 19bytes data.
| index,: | general purpose data register index. |
| data,: | data to restore. |
|
inlinestatic |
Note the kPMU_GenReg4 can retore 3 byte data only, so the general purpose register can store 19bytes data.
| index,: | general purpose data register index. |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
| enable | true is enable, false is disable. |
|
inlinestatic |
| enable | true is enable, false is disable. |
|
inlinestatic |
| enable | true is enable, false is disable. |
|
inlinestatic |
| pin | pin used as wakeup source |
| enable | true is enable, false is disable. |
|
inlinestatic |
| void POWER_SelectPowerSource | ( | power_src_sel_t | sel | ) |
| sel | power source. |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
| mask | interrupt mask value to clear. |