STM32H735xx HAL User Manual
Functions
Configuration of comparator inputs
COMP Exported Functions

Functions

__STATIC_INLINE void LL_COMP_ConfigInputs (COMP_TypeDef *COMPx, uint32_t InputMinus, uint32_t InputPlus)
 Set comparator inputs minus (inverting) and plus (non-inverting).
__STATIC_INLINE void LL_COMP_SetInputPlus (COMP_TypeDef *COMPx, uint32_t InputPlus)
 Set comparator input plus (non-inverting).
__STATIC_INLINE uint32_t LL_COMP_GetInputPlus (COMP_TypeDef *COMPx)
 Get comparator input plus (non-inverting).
__STATIC_INLINE void LL_COMP_SetInputMinus (COMP_TypeDef *COMPx, uint32_t InputMinus)
 Set comparator input minus (inverting).
__STATIC_INLINE uint32_t LL_COMP_GetInputMinus (COMP_TypeDef *COMPx)
 Get comparator input minus (inverting).
__STATIC_INLINE void LL_COMP_SetInputHysteresis (COMP_TypeDef *COMPx, uint32_t InputHysteresis)
 Set comparator instance hysteresis mode of the input minus (inverting input).
__STATIC_INLINE uint32_t LL_COMP_GetInputHysteresis (COMP_TypeDef *COMPx)
 Get comparator instance hysteresis mode of the minus (inverting) input.

Function Documentation

__STATIC_INLINE void LL_COMP_ConfigInputs ( COMP_TypeDef *  COMPx,
uint32_t  InputMinus,
uint32_t  InputPlus 
)

Set comparator inputs minus (inverting) and plus (non-inverting).

Note:
In case of comparator input selected to be connected to IO: GPIO pins are specific to each comparator instance. Refer to description of parameters or to reference manual.
On this STM32 series, scaler bridge is configurable: to optimize power consumption, this function enables the voltage scaler bridge only when required (when selecting comparator input based on VrefInt: VrefInt or subdivision of VrefInt).
  • For scaler bridge power consumption values, refer to device datasheet, parameter "IDDA(SCALER)".
  • Voltage scaler requires a delay for voltage stabilization. Refer to device datasheet, parameter "tSTART_SCALER".
  • Scaler bridge is common for all comparator instances, therefore if at least one of the comparator instance is requiring the scaler bridge, it remains enabled.
Reference Manual to LL API cross reference:
CFGRx INMSEL LL_COMP_ConfigInputs
CFGRx INPSEL LL_COMP_ConfigInputs
CFGRx BRGEN LL_COMP_ConfigInputs
CFGRx SCALEN LL_COMP_ConfigInputs
Parameters:
COMPxComparator instance
InputMinusThis parameter can be one of the following values:
InputPlusThis parameter can be one of the following values:
Return values:
None

Definition at line 427 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE uint32_t LL_COMP_GetInputHysteresis ( COMP_TypeDef *  COMPx)

Get comparator instance hysteresis mode of the minus (inverting) input.

Reference Manual to LL API cross reference:
CSR HYST LL_COMP_GetInputHysteresis
Parameters:
COMPxComparator instance
Return values:
Returnedvalue can be one of the following values:

Definition at line 577 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE uint32_t LL_COMP_GetInputMinus ( COMP_TypeDef *  COMPx)

Get comparator input minus (inverting).

Note:
In case of comparator input selected to be connected to IO: GPIO pins are specific to each comparator instance. Refer to description of parameters or to reference manual.
Reference Manual to LL API cross reference:
CFGRx INMSEL LL_COMP_GetInputMinus
CFGRx BRGEN LL_COMP_GetInputMinus
CFGRx SCALEN LL_COMP_GetInputMinus
Parameters:
COMPxComparator instance
Return values:
Returnedvalue can be one of the following values:

Definition at line 546 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE uint32_t LL_COMP_GetInputPlus ( COMP_TypeDef *  COMPx)

Get comparator input plus (non-inverting).

Note:
In case of comparator input selected to be connected to IO: GPIO pins are specific to each comparator instance. Refer to description of parameters or to reference manual.
Reference Manual to LL API cross reference:
CFGRx INPSEL LL_COMP_GetInputPlus
Parameters:
COMPxComparator instance
Return values:
Returnedvalue can be one of the following values:

Definition at line 477 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE void LL_COMP_SetInputHysteresis ( COMP_TypeDef *  COMPx,
uint32_t  InputHysteresis 
)

Set comparator instance hysteresis mode of the input minus (inverting input).

Reference Manual to LL API cross reference:
CFGRx HYST LL_COMP_SetInputHysteresis
Parameters:
COMPxComparator instance
InputHysteresisThis parameter can be one of the following values:
Return values:
None

Definition at line 562 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE void LL_COMP_SetInputMinus ( COMP_TypeDef *  COMPx,
uint32_t  InputMinus 
)

Set comparator input minus (inverting).

Note:
In case of comparator input selected to be connected to IO: GPIO pins are specific to each comparator instance. Refer to description of parameters or to reference manual.
On this STM32 series, scaler bridge is configurable: to optimize power consumption, this function enables the voltage scaler bridge only when required (when selecting comparator input based on VrefInt: VrefInt or subdivision of VrefInt).
  • For scaler bridge power consumption values, refer to device datasheet, parameter "IDDA(SCALER)".
  • Voltage scaler requires a delay for voltage stabilization. Refer to device datasheet, parameter "tSTART_SCALER".
  • Scaler bridge is common for all comparator instances, therefore if at least one of the comparator instance is requiring the scaler bridge, it remains enabled.
Reference Manual to LL API cross reference:
CFGRx INMSEL LL_COMP_SetInputMinus
CFGRx BRGEN LL_COMP_SetInputMinus
CFGRx SCALEN LL_COMP_SetInputMinus
Parameters:
COMPxComparator instance
InputMinusThis parameter can be one of the following values:
Return values:
None

Definition at line 520 of file stm32h7xx_ll_comp.h.

__STATIC_INLINE void LL_COMP_SetInputPlus ( COMP_TypeDef *  COMPx,
uint32_t  InputPlus 
)

Set comparator input plus (non-inverting).

Note:
In case of comparator input selected to be connected to IO: GPIO pins are specific to each comparator instance. Refer to description of parameters or to reference manual.
Reference Manual to LL API cross reference:
CFGRx INPSEL LL_COMP_SetInputPlus
Parameters:
COMPxComparator instance
InputPlusThis parameter can be one of the following values:
Return values:
None

Definition at line 456 of file stm32h7xx_ll_comp.h.