MG32L003 Standard Peripherals Firmware Library
mg32l003_pwr.h
Go to the documentation of this file.
1 
10 /* Define to prevent recursive inclusion -------------------------------------*/
11 #ifndef __MG32L003_PWR_H
12 #define __MG32L003_PWR_H
13 
14 #ifdef __cplusplus
15  extern "C" {
16 #endif
17 
18 /* Includes ------------------------------------------------------------------*/
19 #include "mg32l003.h"
20 
29 /* Exported types ------------------------------------------------------------*/
30 /* Exported constants --------------------------------------------------------*/
31 
39 #define PWR_SLEEPENTRY_WFI ((uint8_t)0x01)
40 #define PWR_SLEEPENTRY_WFE ((uint8_t)0x02)
41 
49 /* Exported macro ------------------------------------------------------------*/
53 #define IS_PWR_SLEEP_ENTRY(ENTRY) (((ENTRY) == PWR_SLEEPENTRY_WFI) || ((ENTRY) == PWR_SLEEPENTRY_WFE))
54 
58 /* Exported functions --------------------------------------------------------*/
59 
60 void PWR_EnterSLEEPMode(uint8_t SLEEPEntry);
61 void PWR_EnterDEEPSLEEPMode(void);
62 
63 void PWR_EnableSleepOnExit(void);
64 void PWR_DisableSleepOnExit(void);
65 void PWR_EnableSEVOnPend(void);
66 void PWR_DisableSEVOnPend(void);
67 
68 
77 #ifdef __cplusplus
78 }
79 #endif
80 
81 #endif /*__MG32L003_PWR_H */
void PWR_EnableSleepOnExit(void)
Indicates Sleep-On-Exit when returning from Handler mode to Thread mode.
Definition: mg32l003_pwr.c:93
void PWR_DisableSEVOnPend(void)
Disables CORTEX M0+ SEVONPEND bit.
Definition: mg32l003_pwr.c:129
void PWR_DisableSleepOnExit(void)
Disables Sleep-On-Exit feature when returning from Handler mode to Thread mode.
Definition: mg32l003_pwr.c:105
void PWR_EnterDEEPSLEEPMode(void)
Enters Deep Sleep mode.
Definition: mg32l003_pwr.c:72
void PWR_EnterSLEEPMode(uint8_t SLEEPEntry)
Enters Sleep mode.
Definition: mg32l003_pwr.c:44
void PWR_EnableSEVOnPend(void)
Enables CORTEX M0+ SEVONPEND bit.
Definition: mg32l003_pwr.c:117