G32R430 Device Driver Layer v1.0.4
G32R4xx Device Driver Layer API Reference
g32r4xx_ddl_pmu.c
Go to the documentation of this file.
1
42
43#if defined(USE_FULL_DDL_DRIVER)
44/* Includes ------------------------------------------------------------------*/
45#include "g32r4xx_ddl_pmu.h"
46#include "g32r4xx_ddl_rcm.h"
47#ifdef USE_FULL_ASSERT
48#include "g32_assert.h"
49#else
50#define ASSERT_PARAM(_PARAM_) ((void)0U)
51#endif
52
53/* Private function prototypes -----------------------------------------------*/
54
55/* Exported functions --------------------------------------------------------*/
56
60
64
71{
72 /* Set SLEEPDEEP bit of Cortex System Control Register */
73 SCB->SCR |= (uint32_t)0x04;
74
78
79 __WFI();
80}
81
88{
89 /* Set SLEEPDEEP bit of Cortex System Control Register */
90 SCB->SCR |= (uint32_t)0x04;
91
95
96 __WFI();
97}
98
105{
106 /* Set SLEEPDEEP bit of Cortex System Control Register */
107 SCB->SCR |= (uint32_t)0x04;
108
111 DDL_RCM_Lock();
112
113 __WFE();
114}
115
122{
123 /* Set SLEEPDEEP bit of Cortex System Control Register */
124 SCB->SCR |= (uint32_t)0x04;
125
128 DDL_RCM_Lock();
129
130 __WFE();
131}
132
136
140
141#endif
G32 assert template file. This file should be copied to the application folder and renamed to g32_ass...
Header file of PMU DDL module.
Header file of RCM DDL module.
void DDL_PMU_EnterStopModeWFI(void)
Enter Stop Mode by WFI.
void DDL_PMU_EnterStopModeWFE(void)
Enter Stop Mode by WFE.
void DDL_PMU_EnterStandbyModeWFE(void)
Enter Standby Mode by WFE.
void DDL_PMU_EnterStandbyModeWFI(void)
Enter Standby Mode by WFI.
#define DDL_RCM_LOWPOWER_STANDBY
#define DDL_RCM_LOWPOWER_STOP
__STATIC_INLINE void DDL_RCM_Lock(void)
Lock the RCM register.
__STATIC_INLINE void DDL_RCM_Unlock(void)
Unlock the RCM register.
__STATIC_INLINE void DDL_RCM_SetLowPowerMode(uint32_t Mode)
Select the low power mode when enter deep sleep mode.