MCUXpresso SDK API Reference Manual  Rev. 0
NXP Semiconductors
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Gpc

Overview

Data Structures

struct  gpc_tran_step_config_t
 Configuration for GPC transition step. More...
 

Enumerations

enum  {
  kGPC_CM_EventWakeupRequest,
  kGPC_CM_DebugWakeupRequest
}
 _gpc_cm_non_irq_wakeup_request GPC Non-IRQ wakeup request. More...
 
enum  {
  kGPC_SetPoint0 = 1UL << 0UL,
  kGPC_SetPoint1 = 1UL << 1UL,
  kGPC_SetPoint2 = 1UL << 2UL,
  kGPC_SetPoint3 = 1UL << 3UL,
  kGPC_SetPoint4 = 1UL << 4UL,
  kGPC_SetPoint5 = 1UL << 5UL,
  kGPC_SetPoint6 = 1UL << 6UL,
  kGPC_SetPoint7 = 1UL << 7UL,
  kGPC_SetPoint8 = 1UL << 8UL,
  kGPC_SetPoint9 = 1UL << 9UL,
  kGPC_SetPoint10 = 1UL << 10UL,
  kGPC_SetPoint11 = 1UL << 11UL,
  kGPC_SetPoint12 = 1UL << 12UL,
  kGPC_SetPoint13 = 1UL << 13UL,
  kGPC_SetPoint14 = 1UL << 14UL,
  kGPC_SetPoint15 = 1UL << 15UL
}
 
enum  
 _gpc_cm_interrupt_status_flag
 
enum  gpc_cm_standby_mode_status_t {
  kGPC_CM_SleepBusy,
  kGPC_CM_WakeupBusy
}
 CPU standby mode status. More...
 
enum  gpc_cm_tran_step_t {
  kGPC_CM_SleepSsar = 0UL,
  kGPC_CM_SleepLpcg = 1UL,
  kGPC_CM_SleepPll = 2UL,
  kGPC_CM_SleepIso = 3UL,
  kGPC_CM_SleepReset = 4UL,
  kGPC_CM_SleepPower = 5UL,
  kGPC_CM_SleepSP = 6UL,
  kGPC_CM_SleepSTBY = 7UL,
  kGPC_CM_WakeupSTBY = 8UL,
  kGPC_CM_WakeupSP = 9UL,
  kGPC_CM_WakeupPower = 10UL,
  kGPC_CM_WakeupReset = 11UL,
  kGPC_CM_WakeupIso = 12UL,
  kGPC_CM_WakeupPll = 13UL,
  kGPC_CM_WakeupLpcg = 14UL,
  kGPC_CM_WakeupSsar = 15UL
}
 CPU mode transition step in sleep/wakeup sequence. More...
 
enum  gpc_tran_step_counter_mode_t {
  kGPC_StepCounterDisableMode,
  kGPC_StepCounterDelayMode,
  kGPC_StepCounterIgnoreResponseMode = 2UL,
  kGPC_StepCounterTimeOutMode = 3UL
}
 Step counter work mode. More...
 
enum  gpc_sp_tran_step_t {
  kGPC_SP_SsarSave = 0UL,
  kGPC_SP_LpcgOff = 1UL,
  kGPC_SP_GroupDown = 2UL,
  kGPC_SP_RootDown = 3UL,
  kGPC_SP_PllOff = 4UL,
  kGPC_SP_IsoOn = 5UL,
  kGPC_SP_ResetEarly = 6UL,
  kGPC_SP_PowerOff = 7UL,
  kGPC_SP_BiasOff = 8UL,
  kGPC_SP_BandgapPllLdoOff = 9UL,
  kGPC_SP_LdoPre = 10UL,
  kGPC_SP_DcdcDown = 11UL,
  kGPC_SP_DcdcUp = 12UL,
  kGPC_SP_LdoPost = 13UL,
  kGPC_SP_BandgapPllLdoOn = 14UL,
  kGPC_SP_BiasOn = 15UL,
  kGPC_SP_PowerOn = 16UL,
  kGPC_SP_ResetLate = 17UL,
  kGPC_SP_IsoOff = 18UL,
  kGPC_SP_PllOn = 19UL,
  kGPC_SP_RootUp = 20UL,
  kGPC_SP_GroupUp = 21UL,
  kGPC_SP_LpcgOn = 22UL,
  kGPC_SP_SsarRestore = 23UL
}
 GPC set point transition steps. More...
 
enum  gpc_cpu_mode_t {
  kGPC_RunMode = 0x0UL,
  kGPC_WaitMode = 0x1UL,
  kGPC_StopMode = 0x2UL,
  kGPC_SuspendMode = 0x3UL
}
 CPU mode. More...
 
enum  gpc_cm_wakeup_sp_sel_t {
  kGPC_CM_WakeupSetpoint,
  kGPC_CM_RequestPreviousSetpoint = 1UL
}
 
enum  gpc_stby_tran_step_t {
  kGPC_STBY_LpcgIn = 0UL,
  kGPC_STBY_PllIn = 1UL,
  kGPC_STBY_BiasIn = 2UL,
  kGPC_STBY_PldoIn = 3UL,
  kGPC_STBY_BandgapIn = 4UL,
  kGPC_STBY_LdoIn = 5UL,
  kGPC_STBY_DcdcIn = 6UL,
  kGPC_STBY_PmicIn = 7UL,
  kGPC_STBY_PmicOut = 8UL,
  kGPC_STBY_DcdcOut = 9UL,
  kGPC_STBY_LdoOut = 10UL,
  kGPC_STBY_BandgapOut = 11UL,
  kGPC_STBY_PldoOut = 12UL,
  kGPC_STBY_BiasOut = 13UL,
  kGPC_STBY_PllOut = 14UL,
  kGPC_STBY_LpcgOut = 15UL
}
 GPC standby mode transition steps. More...
 

Variables

uint32_t gpc_tran_step_config_t::stepCount
 Step count, which is depended on the value of cntMode. More...
 
gpc_tran_step_counter_mode_t gpc_tran_step_config_t::cntMode
 Step counter working mode. More...
 
bool gpc_tran_step_config_t::enableStep
 Enable the step. More...
 

Driver version

#define FSL_GPC_RIVER_VERSION   (MAKE_VERSION(2, 1, 0))
 GPC driver version 2.1.0. More...
 

CPU mode control

static void GPC_CM_EnableCpuSleepHold (GPC_CPU_MODE_CTRL_Type *base, bool enable)
 
static void GPC_CM_SetNextCpuMode (GPC_CPU_MODE_CTRL_Type *base, gpc_cpu_mode_t mode)
 Set the CPU mode on the next sleep event. More...
 
static gpc_cpu_mode_t GPC_CM_GetCurrentCpuMode (GPC_CPU_MODE_CTRL_Type *base)
 Get current CPU mode. More...
 
static gpc_cpu_mode_t GPC_CM_GetPreviousCpuMode (GPC_CPU_MODE_CTRL_Type *base)
 Get previous CPU mode. More...
 
void GPC_CM_EnableIrqWakeup (GPC_CPU_MODE_CTRL_Type *base, uint32_t irqId, bool enable)
 Enable IRQ wakeup request. More...
 
static void GPC_CM_EnableNonIrqWakeup (GPC_CPU_MODE_CTRL_Type *base, uint32_t mask, bool enable)
 Enable Non-IRQ wakeup request. More...
 
bool GPC_CM_GetIrqWakeupStatus (GPC_CPU_MODE_CTRL_Type *base, uint32_t irqId)
 Get the status of the IRQ wakeup request. More...
 
static bool GPC_CM_GetNonIrqWakeupStatus (GPC_CPU_MODE_CTRL_Type *base, uint32_t mask)
 Get the status of the Non-IRQ wakeup request. More...
 
void GPC_CM_ConfigCpuModeTransitionStep (GPC_CPU_MODE_CTRL_Type *base, gpc_cm_tran_step_t step, const gpc_tran_step_config_t *config)
 Config the cpu mode transition step. More...
 
void GPC_CM_RequestSleepModeSetPointTransition (GPC_CPU_MODE_CTRL_Type *base, uint8_t setPointSleep, uint8_t setPointWakeup, gpc_cm_wakeup_sp_sel_t wakeupSel)
 Request a set point transition before the CPU transfers into a sleep mode. More...
 
void GPC_CM_RequestRunModeSetPointTransition (GPC_CPU_MODE_CTRL_Type *base, uint8_t setPointRun)
 Request a set point transition during run mode. More...
 

Data Structure Documentation

struct gpc_tran_step_config_t

Data Fields

uint32_t stepCount
 Step count, which is depended on the value of cntMode. More...
 
gpc_tran_step_counter_mode_t cntMode
 Step counter working mode. More...
 
bool enableStep
 Enable the step. More...
 

Macro Definition Documentation

#define FSL_GPC_RIVER_VERSION   (MAKE_VERSION(2, 1, 0))

Enumeration Type Documentation

anonymous enum
Enumerator
kGPC_CM_EventWakeupRequest 

Event wakeup request.

kGPC_CM_DebugWakeupRequest 

Debug wakeup request.

anonymous enum
Enumerator
kGPC_SetPoint0 

GPC set point 0.

kGPC_SetPoint1 

GPC set point 1.

kGPC_SetPoint2 

GPC set point 2.

kGPC_SetPoint3 

GPC set point 3.

kGPC_SetPoint4 

GPC set point 4.

kGPC_SetPoint5 

GPC set point 5.

kGPC_SetPoint6 

GPC set point 6.

kGPC_SetPoint7 

GPC set point 7.

kGPC_SetPoint8 

GPC set point 8.

kGPC_SetPoint9 

GPC set point 9.

kGPC_SetPoint10 

GPC set point 10.

kGPC_SetPoint11 

GPC set point 11.

kGPC_SetPoint12 

GPC set point 12.

kGPC_SetPoint13 

GPC set point 13.

kGPC_SetPoint14 

GPC set point 14.

kGPC_SetPoint15 

GPC set point 15.

Enumerator
kGPC_CM_SleepBusy 

Indicate the CPU is busy entering standby mode.

kGPC_CM_WakeupBusy 

Indicate the CPU is busy exiting standby mode.

Enumerator
kGPC_CM_SleepSsar 

SSAR (State Save And Restore) sleep step.

kGPC_CM_SleepLpcg 

LPCG (Low Power Clock Gating) sleep step.

kGPC_CM_SleepPll 

PLL sleep step.

kGPC_CM_SleepIso 

ISO (Isolation) sleep step.

kGPC_CM_SleepReset 

Reset sleep step.

kGPC_CM_SleepPower 

Power sleep step.

kGPC_CM_SleepSP 

Setpoint sleep step.

Note that this step is controlled by setpoint controller.

kGPC_CM_SleepSTBY 

Standby sleep step.

Note that this step is controlled by standby controller.

kGPC_CM_WakeupSTBY 

Standby wakeup step.

Note that this step is controlled by standby controller.

kGPC_CM_WakeupSP 

Setpoint wakeup step.

Note that this step is controlled by setpoint countroller.

kGPC_CM_WakeupPower 

Power wakeup step.

kGPC_CM_WakeupReset 

Reset wakeup step.

kGPC_CM_WakeupIso 

ISO wakeup step.

kGPC_CM_WakeupPll 

PLL wakeup step.

kGPC_CM_WakeupLpcg 

LPCG wakeup step.

kGPC_CM_WakeupSsar 

SSAR wakeup step.

Enumerator
kGPC_StepCounterDisableMode 

Counter disable mode: not use step counter, step completes once receiving step_done.

kGPC_StepCounterDelayMode 

Counter delay mode: delay after receiving step_done, delay cycle number is STEP_CNT.

kGPC_StepCounterIgnoreResponseMode 

Ignore step_done response, the counter starts to count once step begins, when counter reaches STEP_CNT value, the step completes.

kGPC_StepCounterTimeOutMode 

Time out mode, the counter starts to count once step begins, the step completes when either step_done received or counting to STEP_CNT value.

Enumerator
kGPC_SP_SsarSave 

SSAR save step.

kGPC_SP_LpcgOff 

LPCG off step.

kGPC_SP_GroupDown 

Group down step.

kGPC_SP_RootDown 

Root down step.

kGPC_SP_PllOff 

PLL off step.

kGPC_SP_IsoOn 

ISO on.

kGPC_SP_ResetEarly 

Reset early step.

kGPC_SP_PowerOff 

Power off step.

kGPC_SP_BiasOff 

Bias off step.

kGPC_SP_BandgapPllLdoOff 

Bandgap and PLL_LDO off step.

kGPC_SP_LdoPre 

LDO (Low-Dropout) pre step.

kGPC_SP_DcdcDown 

DCDC down step.

kGPC_SP_DcdcUp 

DCDC up step.

kGPC_SP_LdoPost 

LDO post step.

kGPC_SP_BandgapPllLdoOn 

Bandgap and PLL_LDO on step.

kGPC_SP_BiasOn 

Bias on step.

kGPC_SP_PowerOn 

Power on step.

kGPC_SP_ResetLate 

Reset late step.

kGPC_SP_IsoOff 

ISO off step.

kGPC_SP_PllOn 

PLL on step.

kGPC_SP_RootUp 

Root up step.

kGPC_SP_GroupUp 

Group up step.

kGPC_SP_LpcgOn 

LPCG on step.

kGPC_SP_SsarRestore 

SSAR restore step.

Enumerator
kGPC_RunMode 

Stay in RUN mode.

kGPC_WaitMode 

Transit to WAIT mode.

kGPC_StopMode 

Transit to STOP mode.

kGPC_SuspendMode 

Transit to SUSPEND mode.

Enumerator
kGPC_CM_WakeupSetpoint 

Request SP transition to CPU_SP_WAKEUP (param "setPointWakeup" in gpc_cm_sleep_sp_tran_config_t).

kGPC_CM_RequestPreviousSetpoint 

Request SP transition to the set point when the sleep event happens.

Enumerator
kGPC_STBY_LpcgIn 

LPCG in step.

kGPC_STBY_PllIn 

PLL in step.

kGPC_STBY_BiasIn 

Bias in step.

kGPC_STBY_PldoIn 

PLDO in step.

kGPC_STBY_BandgapIn 

Bandgap in step.

kGPC_STBY_LdoIn 

LDO in step.

kGPC_STBY_DcdcIn 

DCDC in step.

kGPC_STBY_PmicIn 

PMIC in step.

kGPC_STBY_PmicOut 

PMIC out step.

kGPC_STBY_DcdcOut 

DCDC out step.

kGPC_STBY_LdoOut 

LDO out step.

kGPC_STBY_BandgapOut 

Bandgap out step.

kGPC_STBY_PldoOut 

PLDO out step.

kGPC_STBY_BiasOut 

Bias out step.

kGPC_STBY_PllOut 

PLL out step.

kGPC_STBY_LpcgOut 

LPCG out step.

Function Documentation

static void GPC_CM_SetNextCpuMode ( GPC_CPU_MODE_CTRL_Type *  base,
gpc_cpu_mode_t  mode 
)
inlinestatic

This function configures the CPU mode that the CPU core will transmit to on next sleep event.

Note
This API must be called each time before entering sleep.
Parameters
baseGPC CPU module base address.
modeThe CPU mode that the core will transmit to, refer to "gpc_cpu_mode_t".
static gpc_cpu_mode_t GPC_CM_GetCurrentCpuMode ( GPC_CPU_MODE_CTRL_Type *  base)
inlinestatic
Parameters
baseGPC CPU module base address.
Returns
The current CPU mode, in type of gpc_cpu_mode_t.
static gpc_cpu_mode_t GPC_CM_GetPreviousCpuMode ( GPC_CPU_MODE_CTRL_Type *  base)
inlinestatic
Parameters
baseGPC CPU module base address.
Returns
The previous CPU mode, in type of gpc_cpu_mode_t.
void GPC_CM_EnableIrqWakeup ( GPC_CPU_MODE_CTRL_Type *  base,
uint32_t  irqId,
bool  enable 
)

This function enables the IRQ request which can wakeup the CPU platform.

Parameters
baseGPC CPU module base address.
irqIdID of the IRQ, accessible range is 0-255.
enableEnable the IRQ request or not.
static void GPC_CM_EnableNonIrqWakeup ( GPC_CPU_MODE_CTRL_Type *  base,
uint32_t  mask,
bool  enable 
)
inlinestatic

This function enables the non-IRQ request which can wakeup the CPU platform.

Parameters
baseGPC CPU module base address.
maskNon-IRQ type, refer to "_gpc_cm_non_irq_wakeup_request".
enableEnable the Non-IRQ request or not.
bool GPC_CM_GetIrqWakeupStatus ( GPC_CPU_MODE_CTRL_Type *  base,
uint32_t  irqId 
)
Parameters
baseGPC CPU module base address.
irqIdID of the IRQ, accessible range is 0-255.
Returns
Indicate the IRQ request is asserted or not.
static bool GPC_CM_GetNonIrqWakeupStatus ( GPC_CPU_MODE_CTRL_Type *  base,
uint32_t  mask 
)
inlinestatic
Parameters
baseGPC CPU module base address.
maskNon-IRQ type, refer to "_gpc_cm_non_irq_wakeup_request".
Returns
Indicate the Non-IRQ request is asserted or not.
void GPC_CM_ConfigCpuModeTransitionStep ( GPC_CPU_MODE_CTRL_Type *  base,
gpc_cm_tran_step_t  step,
const gpc_tran_step_config_t config 
)
Note
This function can not config the setpoint sleep/wakeup operation for those operation is controlled by setpoint control. This funcion can not config the standby sleep/wakeup too, because those operation is controlled by standby controlled.
Parameters
baseGPC CPU module base address.
stepstep type, refer to "gpc_cm_tran_step_t".
configtransition step configuration, refer to "gpc_tran_step_config_t".
void GPC_CM_RequestSleepModeSetPointTransition ( GPC_CPU_MODE_CTRL_Type *  base,
uint8_t  setPointSleep,
uint8_t  setPointWakeup,
gpc_cm_wakeup_sp_sel_t  wakeupSel 
)

This function triggers the set point transition during a CPU Sleep/wakeup event and selects which one the CMC want to transfer to.

Parameters
baseGPC CPU module base address.
setPointSleepThe set point CPU want the system to transit to on next CPU platform sleep sequence.
setPointWakeupThe set point CPU want the system to transit to on next CPU platform wakeup sequence.
wakeupSelSelect the set point transition on the next CPU platform wakeup sequence.
void GPC_CM_RequestRunModeSetPointTransition ( GPC_CPU_MODE_CTRL_Type *  base,
uint8_t  setPointRun 
)

This function triggers the set point transition and selects which one the CMC want to transfer to.

Parameters
baseGPC CPU module base address.
setPointRunThe set point CPU want the system to transit in the run mode.

Variable Documentation

uint32_t gpc_tran_step_config_t::stepCount
gpc_tran_step_counter_mode_t gpc_tran_step_config_t::cntMode
bool gpc_tran_step_config_t::enableStep