![]() |
PDL for FM0+
Version1.0
Peripheral Driverl Library for FM0+
|
Data Structures | |
struct | stc_mft_frt_config |
FRT configure. More... | |
struct | stc_frt_int_sel |
Enumeration of FRT interrupt selection. More... | |
struct | stc_frt_int_cb |
FRT interrupt callback function. More... | |
struct | stc_mft_frt_intern_data |
FRT instance internal data, storing internal information for each enabled FRT instance. More... | |
struct | stc_mft_frt_instance_data |
FRT instance data type. More... | |
Defines | |
#define | stc_mftn_frt_t FM0P_MFT_FRT_TypeDef |
#define | MFT0_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT0_FRT_BASE)) |
#define | MFT1_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT1_FRT_BASE)) |
#define | MFT2_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT2_FRT_BASE)) |
#define | FRT_INSTANCE_COUNT |
#define | MFT_FRT_CH0 0 |
#define | MFT_FRT_CH1 1 |
#define | MFT_FRT_CH2 2 |
#define | MFT_FRT_MAX_CH 3 |
Typedefs | |
typedef enum en_frt_instance_index | en_frt_instance_index_t |
Enumeration to define an index for each FRT instance. | |
typedef enum en_mft_frt_clock | en_mft_frt_clock_t |
Mft Clock Setting. | |
typedef enum en_mft_frt_mode | en_mft_frt_mode_t |
FRT count mode. | |
typedef struct stc_mft_frt_config | stc_mft_frt_config_t |
FRT configure. | |
typedef struct stc_frt_int_sel | stc_frt_int_sel_t |
Enumeration of FRT interrupt selection. | |
typedef enum en_mft_frt_int | en_mft_frt_int_t |
Enumeration of FRT interrupt index. | |
typedef struct stc_frt_int_cb | stc_frt_int_cb_t |
FRT interrupt callback function. | |
typedef struct stc_mft_frt_intern_data | stc_mft_frt_intern_data_t |
FRT instance internal data, storing internal information for each enabled FRT instance. | |
typedef struct stc_mft_frt_instance_data | stc_mft_frt_instance_data_t |
FRT instance data type. | |
Enumerations | |
enum | en_frt_instance_index { FrtInstanceIndexFrt0, FrtInstanceIndexFrt1, FrtInstanceIndexFrt2 } |
Enumeration to define an index for each FRT instance. More... | |
enum | en_mft_frt_clock { FrtPclkDiv1 = 0, FrtPclkDiv2 = 1, FrtPclkDiv4 = 2, FrtPclkDiv8 = 3, FrtPclkDiv16 = 4, FrtPclkDiv32 = 5, FrtPclkDiv64 = 6, FrtPclkDiv128 = 7, FrtPclkDiv256 = 8, FrtPclkDiv512 = 9, FrtPclkDiv1024 = 10 } |
Mft Clock Setting. More... | |
enum | en_mft_frt_mode { FrtUpCount = 0, FrtUpDownCount = 1 } |
FRT count mode. More... | |
enum | en_mft_frt_int { enFrtZeroMatchInt = 0, enFrtPeakMatchInt } |
Enumeration of FRT interrupt index. More... | |
Functions | |
static stc_mft_frt_intern_data_t * | MftGetInternDataPtr (volatile FM0P_MFT_FRT_TypeDef *pstcFrt) |
Return the internal data for a certain FRT instance. | |
void | Mft_Frt_IrqHandler (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, stc_mft_frt_intern_data_t *pstcMftFrtInternData) |
FRT interrupt handler sub function. | |
static void | Mft_Frt_InitIrq (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, stc_frt_int_sel_t *pstcIntSel) |
Device dependent initialization of interrupts according CMSIS with level defined in pdl.h. | |
static void | Mft_Frt_DeInitIrq (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, stc_frt_int_sel_t *pstcIntSel) |
Device dependent initialization of interrupts according CMSIS with level defined in pdl.h. | |
en_result_t | Mft_Frt_Init (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, stc_mft_frt_config_t *pstcFrtConfig) |
Init FRT module. | |
en_result_t | Mft_Frt_SetMaskZeroTimes (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, uint8_t u8Times) |
set mask zero times | |
uint8_t | Mft_Frt_GetMaskZeroTimes (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch) |
get mask zero times | |
en_result_t | Mft_Frt_SetMaskPeakTimes (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, uint8_t u8Times) |
set mask peak times | |
uint8_t | Mft_Frt_GetMaskPeakTimes (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch) |
get mask peak times | |
en_result_t | Mft_Frt_Start (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch) |
Start FRT. | |
en_result_t | Mft_Frt_Stop (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch) |
set frt stop | |
en_result_t | Mft_Frt_EnableInt (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, stc_frt_int_sel_t *pstcIntSel, stc_frt_int_cb_t *pstcFrtIntCallback) |
enable frt interrupt | |
en_result_t | Mft_Frt_DisableInt (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, stc_frt_int_sel_t *pstcIntSel) |
disable frt interrupt | |
en_int_flag_t | Mft_Frt_GetIntFlag (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, en_mft_frt_int_t enIntType) |
get frt interrupt flag | |
en_result_t | Mft_Frt_ClrIntFlag (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, en_mft_frt_int_t enIntType) |
clear frt interrupt flag | |
en_result_t | Mft_Frt_SetCountCycle (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, uint16_t u16Cycle) |
set frt cycle value | |
en_result_t | Mft_Frt_SetCountVal (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch, uint16_t u16Count) |
set frt count value | |
uint16_t | Mft_Frt_GetCurCount (volatile FM0P_MFT_FRT_TypeDef *pstcFrt, uint8_t u8Ch) |
get frt current count | |
Variables | |
stc_mft_frt_instance_data_t | m_astcMftFrtInstanceDataLut [] |
Look-up table for all enabled FRT of MFT instances and their internal data. | |
stc_mft_frt_instance_data_t | m_astcMftFrtInstanceDataLut [(PDL_PERIPHERAL_ENABLE_MFT0_FRT==PDL_ON?1:0)+(PDL_PERIPHERAL_ENABLE_MFT1_FRT==PDL_ON?1:0)+(PDL_PERIPHERAL_ENABLE_MFT2_FRT==PDL_ON?1:0)] |
Look-up table for all enabled FRT of MFT instances and their internal data. |
Provided functions of FRT module:
How to use FRT module?
Mft_Frt_Init() must be used for configuration of a Free-Run timer (FRT) channel with a structure of the type stc_mft_frt_config_t.
Mft_Frt_SetMaskZeroTimes() is used to set the mask times of Zero match interrupt. Mft_Frt_GetMaskZeroTimes() is used to get the mask times of peak match interrupt.
Mft_Frt_SetMaskPeakTimes() is used to set the mask times of peak match interrupt. Mft_Frt_GetMaskPeakTimes() is used to get the mask times of peak match interrupt.
A FRT interrupt can be enabled by the function Mft_Frt_EnableInt(). This function can set callback function for each channel too.
With Mft_Frt_SetCountCycle() the FRT cycle is set to the value given in the parameter Mft_Frt_SetCountCycle::u16Cycle. And the initial count value can be modified by Mft_Frt_SetCountVal().
After above setting, calling Mft_Frt_Start() will start FRT.
With Mft_Frt_GetCurCount() the current FRT count can be read when FRT is running.
With interrupt mode, when the interrupt occurs, the interrupt flag will be cleared and run into user interrupt callback function.
With polling mode, user can use Mft_Frt_GetIntFlag() to check if the interrupt occurs, and clear the interrupt flag by Mft_Frt_ClrIntFlag().
When stopping the FRT, use Mft_Frt_Stop() to disable FRT and Mft_Frt_DisableInt() to disable FRT interrupt.
#define FRT_INSTANCE_COUNT |
(PDL_PERIPHERAL_ENABLE_MFT0_FRT == PDL_ON ? 1 : 0) + \ (PDL_PERIPHERAL_ENABLE_MFT1_FRT == PDL_ON ? 1 : 0) + \ (PDL_PERIPHERAL_ENABLE_MFT2_FRT == PDL_ON ? 1 : 0)
Definition at line 128 of file mft_frt.h.
Referenced by MftGetInternDataPtr().
#define MFT0_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT0_FRT_BASE)) |
Definition at line 124 of file mft_frt.h.
Referenced by Mft_Frt_DeInitIrq(), Mft_Frt_InitIrq(), and MFT_FRT_IRQHandler().
#define MFT1_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT1_FRT_BASE)) |
Definition at line 125 of file mft_frt.h.
Referenced by Mft_Frt_DeInitIrq(), Mft_Frt_InitIrq(), and MFT_FRT_IRQHandler().
#define MFT2_FRT (*((volatile stc_mftn_frt_t *) FM0P_MFT2_FRT_BASE)) |
Definition at line 126 of file mft_frt.h.
Referenced by Mft_Frt_DeInitIrq(), Mft_Frt_InitIrq(), and MFT_FRT_IRQHandler().
#define MFT_FRT_CH0 0 |
Definition at line 132 of file mft_frt.h.
Referenced by Mft_Frt_EnableInt().
#define MFT_FRT_CH1 1 |
Definition at line 133 of file mft_frt.h.
Referenced by Mft_Frt_EnableInt().
#define MFT_FRT_CH2 2 |
Definition at line 134 of file mft_frt.h.
Referenced by Mft_Frt_EnableInt().
#define MFT_FRT_MAX_CH 3 |
Definition at line 136 of file mft_frt.h.
Referenced by Mft_Frt_ClrIntFlag(), Mft_Frt_DisableInt(), Mft_Frt_EnableInt(), Mft_Frt_GetCurCount(), Mft_Frt_GetMaskPeakTimes(), Mft_Frt_GetMaskZeroTimes(), Mft_Frt_Init(), Mft_Frt_SetCountCycle(), Mft_Frt_SetCountVal(), Mft_Frt_SetMaskPeakTimes(), Mft_Frt_SetMaskZeroTimes(), Mft_Frt_Start(), and Mft_Frt_Stop().
#define stc_mftn_frt_t FM0P_MFT_FRT_TypeDef |
Definition at line 123 of file mft_frt.h.
Referenced by Mft_Frt_DeInitIrq(), Mft_Frt_InitIrq(), and MFT_FRT_IRQHandler().
typedef enum en_frt_instance_index en_frt_instance_index_t |
Enumeration to define an index for each FRT instance.
typedef enum en_mft_frt_clock en_mft_frt_clock_t |
Mft Clock Setting.
typedef enum en_mft_frt_int en_mft_frt_int_t |
Enumeration of FRT interrupt index.
typedef enum en_mft_frt_mode en_mft_frt_mode_t |
FRT count mode.
typedef struct stc_frt_int_cb stc_frt_int_cb_t |
FRT interrupt callback function.
typedef struct stc_frt_int_sel stc_frt_int_sel_t |
Enumeration of FRT interrupt selection.
typedef struct stc_mft_frt_config stc_mft_frt_config_t |
FRT configure.
typedef struct stc_mft_frt_instance_data stc_mft_frt_instance_data_t |
FRT instance data type.
typedef struct stc_mft_frt_intern_data stc_mft_frt_intern_data_t |
FRT instance internal data, storing internal information for each enabled FRT instance.
enum en_mft_frt_clock |
Mft Clock Setting.
enum en_mft_frt_int |
enum en_mft_frt_mode |
en_result_t Mft_Frt_ClrIntFlag | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
en_mft_frt_int_t | enIntType | ||
) |
clear frt interrupt flag
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | enIntType | the type of interrupt
|
Ok | frt interrupt flag is clear |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 766 of file mft_frt.c.
References enFrtZeroMatchInt, ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
Referenced by Mft_Frt_IrqHandler().
static void Mft_Frt_DeInitIrq | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
stc_frt_int_sel_t * | pstcIntSel | ||
) | [static] |
Device dependent initialization of interrupts according CMSIS with level defined in pdl.h.
[in] | pstcFrt | Pointer to FRT instance |
[in] | pstcIntSel | Pointer to interrupt selection structure |
Definition at line 228 of file mft_frt.c.
References stc_frt_int_sel::bFrtPeakMatchInt, stc_frt_int_sel::bFrtZeroMatchInt, MFT0_FRT, MFT1_FRT, MFT2_FRT, PDL_DEFAULT_INTERRUPT_LEVEL, and stc_mftn_frt_t.
Referenced by Mft_Frt_DisableInt().
en_result_t Mft_Frt_DisableInt | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
stc_frt_int_sel_t * | pstcIntSel | ||
) |
disable frt interrupt
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | pstcIntSel | Pointer to interrupt selection structure |
Ok | FRT interrupt disabled |
ErrorInvalidParameter | if one of following conditions are met:
|
Definition at line 674 of file mft_frt.c.
References stc_frt_int_sel::bFrtPeakMatchInt, stc_frt_int_sel::bFrtZeroMatchInt, ErrorInvalidParameter, Mft_Frt_DeInitIrq(), MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_EnableInt | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
stc_frt_int_sel_t * | pstcIntSel, | ||
stc_frt_int_cb_t * | pstcFrtIntCallback | ||
) |
enable frt interrupt
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | pstcIntSel | Pointer to interrupt selection structure |
[in] | pstcFrtIntCallback | Pointer to FRT interrupt callback function |
Ok | FRT interrupt enabled |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 582 of file mft_frt.c.
References stc_frt_int_sel::bFrtPeakMatchInt, stc_frt_int_sel::bFrtZeroMatchInt, ErrorInvalidParameter, MFT_FRT_CH0, MFT_FRT_CH1, MFT_FRT_CH2, Mft_Frt_InitIrq(), MFT_FRT_MAX_CH, MftGetInternDataPtr(), Ok, stc_mft_frt_intern_data::pfnFrt0PeakCallback, stc_mft_frt_intern_data::pfnFrt0ZeroCallback, stc_mft_frt_intern_data::pfnFrt1PeakCallback, stc_mft_frt_intern_data::pfnFrt1ZeroCallback, stc_mft_frt_intern_data::pfnFrt2PeakCallback, stc_mft_frt_intern_data::pfnFrt2ZeroCallback, stc_frt_int_cb::pfnFrtPeakCallback, and stc_frt_int_cb::pfnFrtZeroCallback.
uint16_t Mft_Frt_GetCurCount | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch | ||
) |
get frt current count
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
current | count of frt |
Definition at line 882 of file mft_frt.c.
References ErrorInvalidParameter, and MFT_FRT_MAX_CH.
en_int_flag_t Mft_Frt_GetIntFlag | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
en_mft_frt_int_t | enIntType | ||
) |
get frt interrupt flag
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | enIntType | the type of interrupt
|
FALSE | If one of following condition are met:
|
TRUE | If one of following condition are met:
|
Definition at line 725 of file mft_frt.c.
References enFrtZeroMatchInt, PdlClr, and PdlSet.
Referenced by Mft_Frt_IrqHandler().
uint8_t Mft_Frt_GetMaskPeakTimes | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch | ||
) |
get mask peak times
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
Definition at line 470 of file mft_frt.c.
References MFT_FRT_MAX_CH.
uint8_t Mft_Frt_GetMaskZeroTimes | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch | ||
) |
get mask zero times
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
Definition at line 399 of file mft_frt.c.
References MFT_FRT_MAX_CH.
en_result_t Mft_Frt_Init | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
stc_mft_frt_config_t * | pstcFrtConfig | ||
) |
Init FRT module.
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | pstcFrtConfig | configuration of FRT |
Ok | Internal data has been setup |
ErrorInvalidParameter | If one of following cases match:
|
Definition at line 298 of file mft_frt.c.
References stc_mft_frt_config::bEnBuffer, stc_mft_frt_config::bEnExtClock, stc_mft_frt_config::enFrtClockDiv, stc_mft_frt_config::enFrtMode, ErrorInvalidParameter, FrtPclkDiv1024, FrtUpDownCount, MFT_FRT_MAX_CH, MftGetInternDataPtr(), Ok, stc_mft_frt_intern_data::pfnFrt0PeakCallback, stc_mft_frt_intern_data::pfnFrt0ZeroCallback, stc_mft_frt_intern_data::pfnFrt1PeakCallback, stc_mft_frt_intern_data::pfnFrt1ZeroCallback, stc_mft_frt_intern_data::pfnFrt2PeakCallback, and stc_mft_frt_intern_data::pfnFrt2ZeroCallback.
static void Mft_Frt_InitIrq | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
stc_frt_int_sel_t * | pstcIntSel | ||
) | [static] |
Device dependent initialization of interrupts according CMSIS with level defined in pdl.h.
[in] | pstcFrt | Pointer to FRT instance |
[in] | pstcIntSel | Pointer to interrupt selection structure |
Definition at line 200 of file mft_frt.c.
References stc_frt_int_sel::bFrtPeakMatchInt, stc_frt_int_sel::bFrtZeroMatchInt, MFT0_FRT, MFT1_FRT, MFT2_FRT, PDL_IRQ_LEVEL_MFT_FRT, and stc_mftn_frt_t.
Referenced by Mft_Frt_EnableInt().
void Mft_Frt_IrqHandler | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
stc_mft_frt_intern_data_t * | pstcMftFrtInternData | ||
) |
FRT interrupt handler sub function.
[in] | pstcFrt | Pointer to FRT instance |
[in] | pstcMftFrtInternData | structure of frt callback function
|
Definition at line 145 of file mft_frt.c.
References enFrtPeakMatchInt, enFrtZeroMatchInt, Mft_Frt_ClrIntFlag(), Mft_Frt_GetIntFlag(), PdlSet, stc_mft_frt_intern_data::pfnFrt0PeakCallback, and stc_mft_frt_intern_data::pfnFrt0ZeroCallback.
Referenced by MFT_FRT_IRQHandler().
en_result_t Mft_Frt_SetCountCycle | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
uint16_t | u16Cycle | ||
) |
set frt cycle value
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | u16Cycle | the cycle value |
Ok | FRT cycle value is set |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 812 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_SetCountVal | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
uint16_t | u16Count | ||
) |
set frt count value
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | u16Count | the count value
|
Ok | FRT count value is set |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 850 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_SetMaskPeakTimes | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
uint8_t | u8Times | ||
) |
set mask peak times
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | u8Times | mask times
|
Ok | mask peak times is set |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 436 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_SetMaskZeroTimes | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch, | ||
uint8_t | u8Times | ||
) |
set mask zero times
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
[in] | u8Times | mask times
|
Ok | Internal data has been setup |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 365 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_Start | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch | ||
) |
Start FRT.
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
Ok | FRT is started |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 506 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
en_result_t Mft_Frt_Stop | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt, |
uint8_t | u8Ch | ||
) |
set frt stop
[in] | pstcFrt | Pointer to FRT instance |
[in] | u8Ch | channel of Free run timer
|
Ok | FRT is stopped |
ErrorInvalidParameter | If one of following conditions are met:
|
Definition at line 540 of file mft_frt.c.
References ErrorInvalidParameter, MFT_FRT_MAX_CH, and Ok.
static stc_mft_frt_intern_data_t* MftGetInternDataPtr | ( | volatile FM0P_MFT_FRT_TypeDef * | pstcFrt | ) | [static] |
Return the internal data for a certain FRT instance.
pstcFrt | Pointer to FRT instance |
Definition at line 118 of file mft_frt.c.
References FRT_INSTANCE_COUNT, and stc_mft_frt_instance_data::stcInternData.
Referenced by Mft_Frt_EnableInt(), and Mft_Frt_Init().
{ { & (*((volatile FM0P_MFT_FRT_TypeDef *) FM0P_MFT0_FRT_BASE)) , {NULL,NULL,NULL,NULL,NULL,NULL} }, { & (*((volatile FM0P_MFT_FRT_TypeDef *) FM0P_MFT1_FRT_BASE)) , {NULL,NULL,NULL,NULL,NULL,NULL} }, { & (*((volatile FM0P_MFT_FRT_TypeDef *) FM0P_MFT2_FRT_BASE)) , {NULL,NULL,NULL,NULL,NULL,NULL} }, }
Look-up table for all enabled FRT of MFT instances and their internal data.
Definition at line 74 of file mft_frt.c.
Referenced by MFT_FRT_IRQHandler().
stc_mft_frt_instance_data_t m_astcMftFrtInstanceDataLut[(PDL_PERIPHERAL_ENABLE_MFT0_FRT==PDL_ON?1:0)+(PDL_PERIPHERAL_ENABLE_MFT1_FRT==PDL_ON?1:0)+(PDL_PERIPHERAL_ENABLE_MFT2_FRT==PDL_ON?1:0)] |
Look-up table for all enabled FRT of MFT instances and their internal data.
Definition at line 74 of file mft_frt.c.
Referenced by MFT_FRT_IRQHandler().