![]() |
MCUXpresso SDK API Reference Manual
Rev. 0
NXP Semiconductors
|
Power driver provides APIs to control system power and power mode.
Files | |
| file | fsl_power.h |
Data Structures | |
| struct | power_aon_comp_config_t |
| AON Comparator config structure. More... | |
Functions | |
| __STATIC_INLINE void | POWER_ConfigWakeupPin (power_wakeup_pin_t pin, power_wakeup_edge_t edge) |
| Configure pin edge for wakeup. More... | |
| __STATIC_INLINE uint32_t | POWER_GetResetCause (void) |
| Get last reset cause. More... | |
| __STATIC_INLINE void | POWER_ClearResetCause (uint32_t cause) |
| Clear last reset cause. More... | |
| __STATIC_INLINE uint32_t | POWER_GetWakeupSource (void) |
| Get last wakeup source. More... | |
| __STATIC_INLINE void | POWER_ClearWakeupSource (uint32_t src) |
| Clear wakeup source. More... | |
| __STATIC_INLINE void | POWER_EnableWakeup (uint32_t interruptMask) |
| Enable the Wakeup interrupts. More... | |
| __STATIC_INLINE void | POWER_DisableWakeup (uint32_t interruptMask) |
| Disable the Wakeup interrupts. More... | |
| void | POWER_SetSleepMode (uint32_t mode) |
| Set sleep mode on idle. More... | |
| void | POWER_EnterPowerMode (uint32_t mode, uint32_t excludeIo) |
| Switch system into certain power mode. More... | |
| __STATIC_INLINE void | POWER_PowerOnVddio (power_vddio_t domain) |
| Power on IO domain. More... | |
| __STATIC_INLINE void | POWER_PowerOffVddio (power_vddio_t domain) |
| Power off IO domain. More... | |
| void | POWER_PowerOnVddioPad (power_vddio_t domain) |
| Power on IO domain pad regulator. More... | |
| void | POWER_PowerOffVddioPad (power_vddio_t domain) |
| Power off IO domain pad regulator. More... | |
| void | POWER_SetVddioPadVolt (power_vddio_t domain, power_vddio_volt_t volt) |
| Set IO domain pad voltage. More... | |
| __STATIC_INLINE void | POWER_PowerOnWlan (void) |
| Power on WLAN. | |
| __STATIC_INLINE void | POWER_PowerOffWlan (void) |
| Power off WLAN. | |
| __STATIC_INLINE void | PMU_EnableWlanWakeup (void) |
| Enable MCI wakeup WLAN. | |
| __STATIC_INLINE void | PMU_DisableWlanWakeup (void) |
| Disable MCI wakeup WLAN. | |
| void | POWER_AttachGpioIrq (uint32_t pin) |
| Attach GPIO interrupt to NVIC vector table. Since 2 GPIO pins shares 1 IRQ number. Attaching one GPIO IRQ implicits detaching the sibling GPIO IRQ. More... | |
| void | POWER_EnableAonComp (const power_aon_comp_config_t *config) |
| Enable AON Domain Comparator. More... | |
| void | POWER_DisableAonComp (void) |
| Disable AON Domain Comparator. | |
| uint32_t | POWER_GetAonCompValue (void) |
| Get AON Domain Comparator result. More... | |
| __STATIC_INLINE void | POWER_PowerUpBandgap (void) |
| Power up internal bandgap. | |
| __STATIC_INLINE void | POWER_PowerDownBandgap (void) |
| Power down internal bandgap. | |
| void | POWER_TrimBandgapRefVoltage (power_bandgap_ref_voltage_t refVoltage) |
| Trim internal bandgap reference voltage. More... | |
| __STATIC_INLINE bool | POWER_CheckBandgapReady (void) |
| Check internal bandgap ready status. More... | |
Driver version | |
| #define | FSL_POWER_DRIVER_VERSION (MAKE_VERSION(2, 1, 0)) |
| POWER driver version 2.1.0. More... | |
| struct power_aon_comp_config_t |
| #define FSL_POWER_DRIVER_VERSION (MAKE_VERSION(2, 1, 0)) |
| enum power_wakeup_edge_t |
| enum power_wakeup_pin_t |
| enum power_reset_cause_t |
| Enumerator | |
|---|---|
| kPOWER_ResetCauseVbatBrownout |
VBAT power brown-out detected. |
| kPOWER_ResetCauseAv12Brownout |
AV12 power brown-out detected. |
| kPOWER_ResetCauseAv18Brownout |
AV18 power brown-out detected. |
| kPOWER_ResetCauseSysResetReq |
CM4 system soft reset request. |
| kPOWER_ResetCauseLockup |
CM4 locked up. |
| kPOWER_ResetCauseWdt |
watchdog timer. |
| kPOWER_ResetCauseAll |
All reset causes. Used in POWER_ClearResetCause(). |
| enum power_wakeup_src_t |
| Enumerator | |
|---|---|
| kPOWER_WakeupSrcPin0 |
Wakeup0 pin. |
| kPOWER_WakeupSrcPin1 |
Wakeup1 pin. |
| kPOWER_WakeupSrcWlan |
WLAN interrupt. |
| kPOWER_WakeupSrcRtc |
RTC interrupt. |
| kPOWER_WakeupSrcComp |
PMIP Comp interrupt. |
| kPOWER_WakeupSrcAll |
All wakeup sources. Used in POWER_ClearWakeupSource(). |
| enum power_wakeup_mask_t |
| enum power_vddio_t |
| enum power_vddio_volt_t |
| enum power_aon_comp_ref_t |
| __STATIC_INLINE void POWER_ConfigWakeupPin | ( | power_wakeup_pin_t | pin, |
| power_wakeup_edge_t | edge | ||
| ) |
| pin | : Wakeup pin |
| edge | : Pin level for wakeup |
| __STATIC_INLINE uint32_t POWER_GetResetCause | ( | void | ) |
| __STATIC_INLINE void POWER_ClearResetCause | ( | uint32_t | cause | ) |
| cause | : A bitmask of of power_reset_cause_t |
| __STATIC_INLINE uint32_t POWER_GetWakeupSource | ( | void | ) |
| __STATIC_INLINE void POWER_ClearWakeupSource | ( | uint32_t | src | ) |
| src | : A bitmask of power_wakeup_src_t |
| __STATIC_INLINE void POWER_EnableWakeup | ( | uint32_t | interruptMask | ) |
| interruptMask | : A bitmask of interrupts to enable. See power_wakeup_mask_t. |
| __STATIC_INLINE void POWER_DisableWakeup | ( | uint32_t | interruptMask | ) |
| interruptMask | : A bitmask of interrupts to disable. See power_wakeup_mask_t. |
| void POWER_SetSleepMode | ( | uint32_t | mode | ) |
| mode | : 0 ~ 4 stands for PM0 ~ PM4. |
| void POWER_EnterPowerMode | ( | uint32_t | mode, |
| uint32_t | excludeIo | ||
| ) |
| mode | : 0 ~ 4 stands for PM0 ~ PM4. |
| excludeIo,: | IO domains bitmask to keep unchanged during PM2. |
| __STATIC_INLINE void POWER_PowerOnVddio | ( | power_vddio_t | domain | ) |
| domain | : IO domain to power on. |
| __STATIC_INLINE void POWER_PowerOffVddio | ( | power_vddio_t | domain | ) |
| domain | : IO domain to power off. |
| void POWER_PowerOnVddioPad | ( | power_vddio_t | domain | ) |
| domain | : IO domain to power on. |
| void POWER_PowerOffVddioPad | ( | power_vddio_t | domain | ) |
| domain | : IO domain to power off. |
| void POWER_SetVddioPadVolt | ( | power_vddio_t | domain, |
| power_vddio_volt_t | volt | ||
| ) |
| domain | : IO domain. |
| volt | : Voltage level to be set. |
| void POWER_AttachGpioIrq | ( | uint32_t | pin | ) |
| pin | : GPIO index. |
| void POWER_EnableAonComp | ( | const power_aon_comp_config_t * | config | ) |
| config | : AON Comparator config data. |
| uint32_t POWER_GetAonCompValue | ( | void | ) |
| void POWER_TrimBandgapRefVoltage | ( | power_bandgap_ref_voltage_t | refVoltage | ) |
| refVoltage | The reference voltage value to trim, please refer to power_bandgap_ref_voltage_t for details. |
| __STATIC_INLINE bool POWER_CheckBandgapReady | ( | void | ) |
| true | Internal bandgap is ready. |
| false | Internal bandgap is not ready. |