48 #define WWDG_OFFSET (WWDG_BASE - PERIPH_BASE) 51 #define CFR_OFFSET (WWDG_OFFSET + 0x04) 52 #define EWI_BitNumber 0x09 53 #define CFR_EWI_BB (PERIPH_BB_BASE + (CFR_OFFSET * 32) + (EWI_BitNumber * 4)) 58 #define CR_WDGA_Set ((uint32_t)0x00000080) 61 #define CFR_WDGTB_Mask ((uint32_t)0xFFFFFE7F) 62 #define CFR_W_Mask ((uint32_t)0xFFFFFF80) 63 #define BIT_Mask ((uint8_t)0x7F) 126 tmpreg |= WWDG_Prescaler;
139 __IO uint32_t tmpreg = 0;
148 tmpreg |= WindowValue & (uint32_t)
BIT_Mask;
FlagStatus WWDG_GetFlagStatus(void)
Checks whether the Early Wakeup interrupt flag is set or not.
#define IS_WWDG_COUNTER(COUNTER)
This file contains all the functions prototypes for the WWDG firmware library.
void assert_param(int val)
#define IS_WWDG_WINDOW_VALUE(VALUE)
void WWDG_EnableIT(void)
Enables the WWDG Early Wakeup interrupt(EWI).
#define IS_WWDG_PRESCALER(PRESCALER)
void WWDG_SetPrescaler(uint32_t WWDG_Prescaler)
Sets the WWDG Prescaler.
void RCC_APB1PeriphResetCmd(uint32_t RCC_APB1Periph, FunctionalState NewState)
Forces or releases Low Speed APB (APB1) peripheral reset.
void WWDG_DeInit(void)
Deinitializes the WWDG peripheral registers to their default reset values.
#define RCC_APB1Periph_WWDG
This file contains all the functions prototypes for the RCC firmware library.
void WWDG_SetCounter(uint8_t Counter)
Sets the WWDG counter value.
void WWDG_ClearFlag(void)
Clears Early Wakeup interrupt flag.
void WWDG_SetWindowValue(uint8_t WindowValue)
Sets the WWDG window value.
void WWDG_Enable(uint8_t Counter)
Enables WWDG and load the counter value.