eLooM for STM32 application  v3.3.0
A framework for multitasking low power embedded applications powerd by STM32
Loading...
Searching...
No Matches
IDriver.h File Reference

Public API for the Driver Interface. More...

#include "services/eloom_sysbase.h"
#include "services/syslowpower.h"
#include <stddef.h>
+ Include dependency graph for IDriver.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef struct _IDriver IDriver
 

Functions

static sys_error_code_t IDrvInit (IDriver *_this, void *pParams)
 
static sys_error_code_t IDrvStart (IDriver *_this)
 
static sys_error_code_t IDrvStop (IDriver *_this)
 
static sys_error_code_t IDrvDoEnterPowerMode (IDriver *_this, const EPowerMode eActivePowerMode, const EPowerMode eNewPowerMode)
 
static sys_error_code_t IDrvReset (IDriver *_this, void *pParams)
 

Detailed Description

Public API for the Driver Interface.

Author
STMicroelectronics - ST-Korea - MCD Team
Version
3.0.0
Date
Sep 6, 2016

IDriver is the base interface for the Driver subsystem. Each driver implements this interface.

Attention

Copyright (c) 2016 STMicroelectronics. All rights reserved.

This software is licensed under terms that can be found in the LICENSE file in the root directory of this software component. If no LICENSE file comes with this software, it is provided AS-IS.

Typedef Documentation

◆ IDriver

typedef struct _IDriver IDriver

Creates a type name for _IDriver.

Function Documentation

◆ IDrvDoEnterPowerMode()

static sys_error_code_t IDrvDoEnterPowerMode ( IDriver _this,
const EPowerMode  eActivePowerMode,
const EPowerMode  eNewPowerMode 
)
inlinestatic

This function is called by the framework when the system is changing the power mode. The driver must reconfigure itself according the new power mode.

Parameters
_this[IN] specifies a pointer to a IDriver object.
eActivePowerMode[IN] specifies the actual power mode.
eNewPowerMode[IN] specifies the new power mode.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.
+ Here is the call graph for this function:

◆ IDrvInit()

static sys_error_code_t IDrvInit ( IDriver _this,
void *  pParams 
)
inlinestatic

Initialize the driver. This method should be used by a task object during the hardware initialization process.

Parameters
_this[IN] specifies a pointer to a IDriver object.
pParams[IN] specifies a pointer to a initialization parameters defined by a subclass.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.
+ Here is the call graph for this function:

◆ IDrvReset()

static sys_error_code_t IDrvReset ( IDriver _this,
void *  pParams 
)
inlinestatic

Reset the peripherals owned by the driver. This method should operate at hardware level, for example by using the HAL_XXX_DeInit() and HAL_XXX_Init() functions.

Parameters
_this[IN] specifies a pointer to a IDriver object.
pParams[IN] specifies a pointer to a parameters defined by a subclass.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.
+ Here is the call graph for this function:

◆ IDrvStart()

static sys_error_code_t IDrvStart ( IDriver _this)
inlinestatic

Start the driver. This method enable the driver normal processing. For example it enables the related IRQ. It should be called after the driver initialization.

Parameters
_thiss[IN] specifies a pointer to a IDriver object.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.
+ Here is the call graph for this function:

◆ IDrvStop()

static sys_error_code_t IDrvStop ( IDriver _this)
inlinestatic

Stop a driver. This method disable the driver normal operation. For example it disables the IRQ. It doesn't de-initialize the driver.

Parameters
_this[IN] specifies a pointer to a IDriver object.
Returns
SYS_NO_ERROR_CODE if success, an error code otherwise.
+ Here is the call graph for this function: