DIY Logging Volt/Ampmeter
PWR Exported Macros

Macros

#define __HAL_PWR_GET_FLAG(__FLAG__)   ((PWR->CSR & (__FLAG__)) == (__FLAG__))
 Check PWR flag is set or not. More...
 
#define __HAL_PWR_CLEAR_FLAG(__FLAG__)   SET_BIT(PWR->CR, ((__FLAG__) << 2))
 Clear the PWR's pending flags. More...
 
#define __HAL_PWR_PVD_EXTI_ENABLE_IT()   SET_BIT(EXTI->IMR, PWR_EXTI_LINE_PVD)
 Enable interrupt on PVD Exti Line 16. More...
 
#define __HAL_PWR_PVD_EXTI_DISABLE_IT()   CLEAR_BIT(EXTI->IMR, PWR_EXTI_LINE_PVD)
 Disable interrupt on PVD Exti Line 16. More...
 
#define __HAL_PWR_PVD_EXTI_ENABLE_EVENT()   SET_BIT(EXTI->EMR, PWR_EXTI_LINE_PVD)
 Enable event on PVD Exti Line 16. More...
 
#define __HAL_PWR_PVD_EXTI_DISABLE_EVENT()   CLEAR_BIT(EXTI->EMR, PWR_EXTI_LINE_PVD)
 Disable event on PVD Exti Line 16. More...
 
#define __HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE()   SET_BIT(EXTI->FTSR, PWR_EXTI_LINE_PVD)
 PVD EXTI line configuration: set falling edge trigger.
More...
 
#define __HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE()   CLEAR_BIT(EXTI->FTSR, PWR_EXTI_LINE_PVD)
 Disable the PVD Extended Interrupt Falling Trigger. More...
 
#define __HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE()   SET_BIT(EXTI->RTSR, PWR_EXTI_LINE_PVD)
 PVD EXTI line configuration: set rising edge trigger. More...
 
#define __HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE()   CLEAR_BIT(EXTI->RTSR, PWR_EXTI_LINE_PVD)
 Disable the PVD Extended Interrupt Rising Trigger. This parameter can be: More...
 
#define __HAL_PWR_PVD_EXTI_ENABLE_RISING_FALLING_EDGE()   __HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE();__HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE();
 PVD EXTI line configuration: set rising & falling edge trigger. More...
 
#define __HAL_PWR_PVD_EXTI_DISABLE_RISING_FALLING_EDGE()   __HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE();__HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE();
 Disable the PVD Extended Interrupt Rising & Falling Trigger. This parameter can be: More...
 
#define __HAL_PWR_PVD_EXTI_GET_FLAG()   (EXTI->PR & (PWR_EXTI_LINE_PVD))
 Check whether the specified PVD EXTI interrupt flag is set or not. More...
 
#define __HAL_PWR_PVD_EXTI_CLEAR_FLAG()   (EXTI->PR = (PWR_EXTI_LINE_PVD))
 Clear the PVD EXTI flag. More...
 
#define __HAL_PWR_PVD_EXTI_GENERATE_SWIT()   SET_BIT(EXTI->SWIER, PWR_EXTI_LINE_PVD)
 Generate a Software interrupt on selected EXTI line. More...
 

Detailed Description

Macro Definition Documentation

◆ __HAL_PWR_CLEAR_FLAG

#define __HAL_PWR_CLEAR_FLAG (   __FLAG__)    SET_BIT(PWR->CR, ((__FLAG__) << 2))

Clear the PWR's pending flags.

Parameters
<strong>FLAG</strong>specifies the flag to clear. This parameter can be one of the following values:
  • PWR_FLAG_WU: Wake Up flag
  • PWR_FLAG_SB: StandBy flag

Definition at line 198 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_GET_FLAG

#define __HAL_PWR_GET_FLAG (   __FLAG__)    ((PWR->CSR & (__FLAG__)) == (__FLAG__))

Check PWR flag is set or not.

Parameters
<strong>FLAG</strong>specifies the flag to check. This parameter can be one of the following values:
  • PWR_FLAG_WU: Wake Up flag. This flag indicates that a wakeup event was received from the WKUP pin or from the RTC alarm An additional wakeup event is detected if the WKUP pin is enabled (by setting the EWUP bit) when the WKUP pin level is already high.
  • PWR_FLAG_SB: StandBy flag. This flag indicates that the system was resumed from StandBy mode.
  • PWR_FLAG_PVDO: PVD Output. This flag is valid only if PVD is enabled by the HAL_PWR_EnablePVD() function. The PVD is stopped by Standby mode For this reason, this bit is equal to 0 after Standby or reset until the PVDE bit is set.
Return values
Thenew state of FLAG (TRUE or FALSE).

Definition at line 190 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_CLEAR_FLAG

#define __HAL_PWR_PVD_EXTI_CLEAR_FLAG ( )    (EXTI->PR = (PWR_EXTI_LINE_PVD))

Clear the PVD EXTI flag.

Return values
None.

Definition at line 277 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_DISABLE_EVENT

#define __HAL_PWR_PVD_EXTI_DISABLE_EVENT ( )    CLEAR_BIT(EXTI->EMR, PWR_EXTI_LINE_PVD)

Disable event on PVD Exti Line 16.

Return values
None.

Definition at line 222 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE

#define __HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE ( )    CLEAR_BIT(EXTI->FTSR, PWR_EXTI_LINE_PVD)

Disable the PVD Extended Interrupt Falling Trigger.

Return values
None.

Definition at line 236 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_DISABLE_IT

#define __HAL_PWR_PVD_EXTI_DISABLE_IT ( )    CLEAR_BIT(EXTI->IMR, PWR_EXTI_LINE_PVD)

Disable interrupt on PVD Exti Line 16.

Return values
None.

Definition at line 210 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE

#define __HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE ( )    CLEAR_BIT(EXTI->RTSR, PWR_EXTI_LINE_PVD)

Disable the PVD Extended Interrupt Rising Trigger. This parameter can be:

Return values
None.

Definition at line 250 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_DISABLE_RISING_FALLING_EDGE

#define __HAL_PWR_PVD_EXTI_DISABLE_RISING_FALLING_EDGE ( )    __HAL_PWR_PVD_EXTI_DISABLE_RISING_EDGE();__HAL_PWR_PVD_EXTI_DISABLE_FALLING_EDGE();

Disable the PVD Extended Interrupt Rising & Falling Trigger. This parameter can be:

Return values
None.

Definition at line 263 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_ENABLE_EVENT

#define __HAL_PWR_PVD_EXTI_ENABLE_EVENT ( )    SET_BIT(EXTI->EMR, PWR_EXTI_LINE_PVD)

Enable event on PVD Exti Line 16.

Return values
None.

Definition at line 216 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE

#define __HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE ( )    SET_BIT(EXTI->FTSR, PWR_EXTI_LINE_PVD)

PVD EXTI line configuration: set falling edge trigger.

Return values
None.

Definition at line 229 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_ENABLE_IT

#define __HAL_PWR_PVD_EXTI_ENABLE_IT ( )    SET_BIT(EXTI->IMR, PWR_EXTI_LINE_PVD)

Enable interrupt on PVD Exti Line 16.

Return values
None.

Definition at line 204 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE

#define __HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE ( )    SET_BIT(EXTI->RTSR, PWR_EXTI_LINE_PVD)

PVD EXTI line configuration: set rising edge trigger.

Return values
None.

Definition at line 243 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_ENABLE_RISING_FALLING_EDGE

#define __HAL_PWR_PVD_EXTI_ENABLE_RISING_FALLING_EDGE ( )    __HAL_PWR_PVD_EXTI_ENABLE_RISING_EDGE();__HAL_PWR_PVD_EXTI_ENABLE_FALLING_EDGE();

PVD EXTI line configuration: set rising & falling edge trigger.

Return values
None.

Definition at line 256 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_GENERATE_SWIT

#define __HAL_PWR_PVD_EXTI_GENERATE_SWIT ( )    SET_BIT(EXTI->SWIER, PWR_EXTI_LINE_PVD)

Generate a Software interrupt on selected EXTI line.

Return values
None.

Definition at line 283 of file stm32f1xx_hal_pwr.h.

◆ __HAL_PWR_PVD_EXTI_GET_FLAG

#define __HAL_PWR_PVD_EXTI_GET_FLAG ( )    (EXTI->PR & (PWR_EXTI_LINE_PVD))

Check whether the specified PVD EXTI interrupt flag is set or not.

Return values
EXTIPVD Line Status.

Definition at line 271 of file stm32f1xx_hal_pwr.h.