![]() |
PDL for FM4
Version1.2
Peripheral Driverl Library for FM4
|
#include "pdl.h"

Go to the source code of this file.
Data Structures | |
| struct | stc_wc_pres_clk |
| Structure to configure watch counter prescaler. More... | |
| struct | stc_wc_config |
| Structure to configure the watch counter. More... | |
| struct | stc_wc_intern_data |
| Structure of watch counter internal data. More... | |
| struct | stc_wc_instance_data |
| Structure of watch counter instance data. More... | |
Macros | |
| #define | stc_wcn_t FM4_WC_TypeDef |
| #define | WC0 (*((FM4_WC_TypeDef *) FM4_WC_BASE)) |
Typedefs | |
| typedef enum en_wc_instance_index | en_wc_instance_index_t |
| Enumeration to define an index for each WC instance. More... | |
| typedef enum en_input_clk | en_input_clk_t |
| Enumeration to define source clock of watch counter precaler. More... | |
| typedef enum en_output_clk | en_output_clk_t |
| Enumeration to define output clock of watch counter precaler. More... | |
| typedef struct stc_wc_pres_clk | stc_wc_pres_clk_t |
| Structure to configure watch counter prescaler. More... | |
| typedef enum en_wc_cnt_clk | en_wc_cnt_clk_t |
| Enumeration to set the clock of watch counter. More... | |
| typedef struct stc_wc_config | stc_wc_config_t |
| Structure to configure the watch counter. More... | |
| typedef struct stc_wc_intern_data | stc_wc_intern_data_t |
| Structure of watch counter internal data. More... | |
| typedef struct stc_wc_instance_data | stc_wc_instance_data_t |
| Structure of watch counter instance data. More... | |
Enumerations | |
| enum | en_wc_instance_index { WcInstanceIndexWc0 = 0 } |
| Enumeration to define an index for each WC instance. More... | |
| enum | en_input_clk { WcPresInClkSubOsc = 0, WcPresInClkMainOsc, WcPresInClkHighCr, WcPresInClkLowCr } |
| Enumeration to define source clock of watch counter precaler. More... | |
| enum | en_output_clk { WcPresOutClkArray0 = 0, WcPresOutClkArray1, WcPresOutClkArray2, WcPresOutClkArray3, WcPresOutClkArray4, WcPresOutClkArray5, WcPresOutClkArray6 } |
| Enumeration to define output clock of watch counter precaler. More... | |
| enum | en_wc_cnt_clk { WcCntClkWcck0 = 0, WcCntClkWcck1, WcCntClkWcck2, WcCntClkWcck3 } |
| Enumeration to set the clock of watch counter. More... | |
Functions | |
| en_result_t | Wc_Pres_SelClk (volatile FM4_WC_TypeDef *pstcWc, stc_wc_pres_clk_t *pstcWcPresClk) |
| Select the input clock an and set the division clock to be output. More... | |
| en_result_t | Wc_Pres_EnableDiv (volatile FM4_WC_TypeDef *pstcWc) |
| Enable oscilation of the divison clock. More... | |
| en_result_t | Wc_Pres_DisableDiv (volatile FM4_WC_TypeDef *pstcWc) |
| Disable oscilation of the divison clock. More... | |
| en_stat_flag_t | Wc_GetDivStat (volatile FM4_WC_TypeDef *pstcWc) |
| Get the operation status of the division counter. More... | |
| en_result_t | Wc_Init (volatile FM4_WC_TypeDef *pstcWc, stc_wc_config_t *pstcWcConfig) |
| Select the input clock an and set the division clock to be output. More... | |
| en_result_t | Wc_EnableCount (volatile FM4_WC_TypeDef *pstcWc) |
| Enable WC operation. More... | |
| en_result_t | Wc_DisableCount (volatile FM4_WC_TypeDef *pstcWc) |
| Disable WC operation. More... | |
| en_result_t | Wc_EnableInt (volatile FM4_WC_TypeDef *pstcWc, func_ptr_t pfnIntCallback) |
| Enable WC underflow interrupt. More... | |
| en_result_t | Wc_DisableInt (volatile FM4_WC_TypeDef *pstcWc) |
| Disable WC underflow interrupt. More... | |
| en_result_t | Wc_WriteReloadVal (volatile FM4_WC_TypeDef *pstcWc, uint8_t u8Val) |
| Set the counter value of WC. More... | |
| uint8_t | Wc_ReadCurCnt (volatile FM4_WC_TypeDef *pstcWc) |
| Read the value in the 6-bit down counter. More... | |
| en_result_t | Wc_ClearIntFlag (volatile FM4_WC_TypeDef *pstcWc) |
| Clear WC underflow flag. More... | |
| en_int_flag_t | Wc_GetIntFlag (volatile FM4_WC_TypeDef *pstcWc) |
| Get WC underflow flag status. More... | |
| en_stat_flag_t | Wc_GetOperationFlag (volatile FM4_WC_TypeDef *pstcWc) |
| Get WC operation state. More... | |
| void | Wc_IrqHandler (volatile FM4_WC_TypeDef *pstcWc, stc_wc_intern_data_t *pstcWcInternData) |
| Watch counter interrupt function. More... | |
Variables | |
| stc_wc_instance_data_t | m_astcWcInstanceDataLut [] |
| Look-up table for all enabled WC instances and their internal data. More... | |
Headerfile for WC functions
History:
Definition in file wc.h.