ODeV framework  v2
Typedefs | Functions
IAppPowerModeHelper.h File Reference

<DESCRIPTIOM> More...

#include "syslowpower.h"
+ Include dependency graph for IAppPowerModeHelper.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef struct _IAppPowerModeHelper IAppPowerModeHelper
 

Functions

sys_error_code_t IapmhInit (IAppPowerModeHelper *this)
 
EPowerMode IapmhComputeNewPowerMode (IAppPowerModeHelper *this, const SysEvent xEvent)
 
boolean_t IapmhCheckPowerModeTransaction (IAppPowerModeHelper *this, const EPowerMode eActivePowerMode, const EPowerMode eNewPowerMode)
 
sys_error_code_t IapmhDidEnterPowerMode (IAppPowerModeHelper *this, EPowerMode ePowerMode)
 
EPowerMode IapmhGetActivePowerMode (IAppPowerModeHelper *this)
 
SysPowerStatus IapmhGetPowerStatus (IAppPowerModeHelper *this)
 
boolean_t IapmhIsLowPowerMode (IAppPowerModeHelper *this, const EPowerMode ePowerMode)
 

Detailed Description

<DESCRIPTIOM>

Author
STMicroelectronics - ST-Korea - MCD Team
Version
1.0.0
Date
Oct 30, 2018
Attention

© COPYRIGHT 2018 STMicroelectronics

Licensed under MCD-ST Liberty SW License Agreement V2, (the "License"); You may not use this file except in compliance with the License. You may obtain a copy of the License at:

   http://www.st.com/software_license_agreement_liberty_v2

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Typedef Documentation

◆ IAppPowerModeHelper

Create type name for _IAppPowerModeHelper.

Function Documentation

◆ IapmhCheckPowerModeTransaction()

boolean_t IapmhCheckPowerModeTransaction ( IAppPowerModeHelper this,
const EPowerMode  eActivePowerMode,
const EPowerMode  eNewPowerMode 
)
inline

Used mainly for debug purpose. It checks if a request power mode transaction is valid.

Parameters
this[IN] specifies a pointer to the object.
eActivePowerMode[IN] species the actual power mode.
eNewPowerMode[IN] specifies a new power mode.
Returns
TRUE if the transaction is valid. If the transaction is not valid the program execution is stopped.

◆ IapmhComputeNewPowerMode()

EPowerMode IapmhComputeNewPowerMode ( IAppPowerModeHelper this,
const SysEvent  xEvent 
)
inline

Compute the new power mode depending on the input event.

Parameters
this[IN] specifies a pointer to the object.
xEvent[IN] an power mode input event.
Returns
the power mode that the system should enter due to the event.

◆ IapmhDidEnterPowerMode()

sys_error_code_t IapmhDidEnterPowerMode ( IAppPowerModeHelper this,
EPowerMode  ePowerMode 
)
inline

Used by the system to enter the new power mode. It is called after all application task are ready for the new power mode.

Parameters
this[IN] specifies a pointer to the object.
ePowerMode[IN] specifies a new power mode.

◆ IapmhGetActivePowerMode()

EPowerMode IapmhGetActivePowerMode ( IAppPowerModeHelper this)
inline

Get the active power mode.

Parameters
this[IN] specifies a pointer to the object.
Returns
the active power mode.

◆ IapmhGetPowerStatus()

SysPowerStatus IapmhGetPowerStatus ( IAppPowerModeHelper this)
inline

Get a copy of the actual power status.

Parameters
this[IN] specifies a pointer to the object.
Returns
a copy of the actual power status.

◆ IapmhInit()

sys_error_code_t IapmhInit ( IAppPowerModeHelper this)
inline

Initialize the interface IAppPowerModeHelper. It should be called after the object allocation and before using the object.

Parameters
this[IN] specifies a pointer to the object.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.

◆ IapmhIsLowPowerMode()

boolean_t IapmhIsLowPowerMode ( IAppPowerModeHelper this,
const EPowerMode  ePowerMode 
)
inline

Check if a power mode is a low power mode that put the MCU in STOPx mode or higher power efficient mode.

Parameters
this[IN] specifies a pointer to the object.
ePowerMode[IN] species a power mode.
Returns
TRUE if ePowerMode is a low power mode, ‘FALSE’ otherwise.