MG32L003 Standard Peripherals Firmware Library

结构体 | 宏定义 | 函数
mg32l003_vcmp.h 文件参考

This file contains all the functions prototypes for the VCMP firmware library. 更多...

`#include "mg32l003.h"`

浏览源代码.

## 结构体
struct | VCMP_InitTypeDef
| VCMP Init structure definition 更多...

## 宏定义
#define | VCMP_VCAPDIV_ENABLE VCMP_CR0_VCAPDIV_EN
#define | VCMP_VCAPDIV_DISABLE (0x0U)
#define | VCMP_INT_ENABLE VCMP_CR1_INT_EN
#define | VCMP_INT_DISABLE (0x0U)
#define | VCMP_ENABLE VCMP_CR1_VCEN
#define | VCMP_DISABLE (0x0U)
#define | VCMP_1P4_VCAPDIV (0x00U)
#define | VCMP_2P4_VCAPDIV (0x01U)
#define | VCMP_3P4_VCAPDIV (0x02U)
#define | VCMP_4P4_VCAPDIV (0x03U)
#define | IS_VCMP_VCAPDIV(VCMP_VCAPDIV)
#define | VCMP_INPUT_0 (0x00U)
#define | VCMP_INPUT_1 (0x01U)
#define | VCMP_INPUT_2 (0x02U)
#define | VCMP_INPUT_VCAPDIV (0x03U)
#define | IS_VCMP_INPUT(VCMP_INPUT)
#define | VCMP_FILTER_ENABLE VCMP_CR1_FLTEN
#define | VCMP_FILTER_DISABLE (0x0U)
#define | IS_VCMP_FILTER_ENABLE(FILTER) (((FILTER) == VCMP_FILTER_ENABLE) || ((FILTER) == VCMP_FILTER_DISABLE))
#define | IS_VCMP_FILTER_NUM(FILTER_NUM) (((FILTER_NUM) >= 0U) && ((FILTER_NUM) <= 0xFFFFU))
#define | VCMP_HIGH_INT VCMP_CR1_HIGHINTEN
#define | VCMP_RISE_INT VCMP_CR1_RISEINTEN
#define | VCMP_FALL_INT VCMP_CR1_FALLINTEN
#define | VCMP_INT_MASK (VCMP_HIGH_INT | VCMP_RISE_INT | VCMP_FALL_INT)
#define | IS_VCMP_INT(VCMP_INT)
#define | VCMP_FILTER_CLK_NONE (0x00U)
#define | VCMP_FILTER_CLK_PCLK (0x01U << VCMP_CR1_VCMP_FLTCLK_SEL_Pos)
#define | VCMP_FILTER_CLK_LSI (0x02U << VCMP_CR1_VCMP_FLTCLK_SEL_Pos)
#define | IS_VCMP_FILTER_CLOCK(FILTER_CLOCK)
#define | VCMP_OUTCFG_INV_PAD (0x01 << VCMP_OUTCFG_INV_PAD_Pos)
#define | VCMP_OUTCFG_TIM1_BKE (0x01 << VCMP_OUTCFG_TIM1BKE_Pos)
#define | VCMP_OUTCFG_TIM1CH4_GATE (0x01 << VCMP_OUTCFG_TIM1CH4_EN_Pos)
#define | VCMP_OUTCFG_INV_TIM1CH4_GATE (0x01 << VCMP_OUTCFG_INV_TIM1CH4_Pos)
#define | VCMP_OUTCFG_TIM1CH3_GATE (0x01 << VCMP_OUTCFG_TIM1CH3_EN_Pos)
#define | VCMP_OUTCFG_INV_TIM1CH3_GATE (0x01 << VCMP_OUTCFG_INV_TIM1CH3_Pos)
#define | VCMP_OUTCFG_TIM1CH2_GATE (0x01 << VCMP_OUTCFG_TIM1CH2_EN_Pos)
#define | VCMP_OUTCFG_INV_TIM1CH2_GATE (0x01 << VCMP_OUTCFG_INV_TIM1CH2_Pos)
#define | VCMP_OUTCFG_TIM1CH1_GATE (0x01 << VCMP_OUTCFG_TIM1CH1_EN_Pos)
#define | VCMP_OUTCFG_INV_TIM1CH1_GATE (0x01 << VCMP_OUTCFG_INV_TIM1CH1_Pos)
#define | VCMP_OUTCFG_PCA_EXTCLK_EN (0x01 << VCMP_OUTCFG_PCAECI_EN_Pos)
#define | VCMP_OUTCFG_PCA_CAP0_EN (0x01 << VCMP_OUTCFG_PCACAP0_EN_Pos)
#define | VCMP_OUTCFG_INV_PCA (0x01 << VCMP_OUTCFG_INV_PCA_Pos)
#define | VCMP_OUTCFG_LPTIM_EXTCLK_EN (0x01 << VCMP_OUTCFG_LPTIMEXT_EN_Pos)
#define | VCMP_OUTCFG_LPTIM_GATE (0x01 << VCMP_OUTCFG_LPTIM_EN_Pos)
#define | VCMP_OUTCFG_TIM11_GATE (0x01 << VCMP_OUTCFG_TIM11_EN_Pos)
#define | VCMP_OUTCFG_TIM10_GATE (0x01 << VCMP_OUTCFG_TIM10_EN_Pos)
#define | VCMP_OUTCFG_INV_LPTIM_TIM10_11 (0x01 << VCMP_OUTCFG_INV_TIMX_Pos)
#define | VCMP_OUTCFG_MSK (0x7FFFFU)
#define | IS_VCMP_OUTCFG(OUTCFG) (((OUTCFG) & VCMP_OUTCFG_MSK) != 0x0000U)

## 函数
void | VCMP_DeInit (void)
| Deinitializes the VCMP peripheral. 更多...
void | VCMP_Init (VCMP_InitTypeDef *InitStruct)
| Initializes the VCMP according to the specified parameters in the VCMP_HandleTypeDef. 更多...
void | VCMP_ITConfig (uint32_t Config, FunctionalState NewState)
| Enables or disables the specified VCMP interrupts. 更多...
void | VCMP_ITCmd (FunctionalState NewState)
| Enables or disables VCMP interrupt. 更多...
void | VCMP_OutputConfig (uint32_t Config, FunctionalState NewState)
| Enables or disables the specified VCMP outputs. 更多...
FlagStatus | VCMP_GetFlagStatus (void)
| Checks whether VCMP interrupt flag is set or reset. 更多...
ITStatus | VCMP_GetITStatus (void)
| Checks whether VCMP interrupt is set or reset. 更多...
void | VCMP_ClearITPendingBit (void)
| Clears VCMP interrupt. 更多...
void | VCMP_ClearFlag (void)
| Clears VCMP interrupt flag. 更多...
FlagStatus | VCMP_GetOutputStatus (void)
| Checks VCMP output is set or reset. 更多...
void | VCMP_Cmd (FunctionalState NewState)
| Enables or disables VCMP peripheral(write access to VCMP_CR1 registers). 更多...

## 详细描述

This file contains all the functions prototypes for the VCMP firmware library.

作者
  megawin Application Team

版本
  V0.0.5

日期
  13-August-2024