Skip to content

Commit 2c9d001

Browse files
committed
Disabled PWR module
1 parent e90a241 commit 2c9d001

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

variants/ARMED_V1/stm32f4xx_hal_conf.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
#define HAL_IWDG_MODULE_ENABLED
7373
/* #define HAL_LTDC_MODULE_ENABLED */
7474
/* #define HAL_DSI_MODULE_ENABLED */
75-
#define HAL_PWR_MODULE_ENABLED
75+
/* #define HAL_PWR_MODULE_ENABLED */
7676
/* #define HAL_QSPI_MODULE_ENABLED */
7777
#define HAL_RCC_MODULE_ENABLED
7878
/* #define HAL_RNG_MODULE_ENABLED */

variants/ARMED_V1/variant.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -146,13 +146,16 @@ WEAK void SystemClock_Config(void)
146146
RCC_ClkInitTypeDef RCC_ClkInitStruct;
147147
RCC_OscInitTypeDef RCC_OscInitStruct;
148148

149+
149150
/* Enable Power Control clock */
150151
__HAL_RCC_PWR_CLK_ENABLE();
151152

153+
#ifdef HAL_PWR_MODULE_ENABLED
152154
/* The voltage scaling allows optimizing the power consumption when the device is
153155
clocked below the maximum system frequency, to update the voltage scaling value
154156
regarding system frequency refer to product datasheet. */
155157
__HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE1);
158+
#endif
156159

157160
/* Enable HSE Oscillator and activate PLL with HSE as source */
158161
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSE;

0 commit comments

Comments
 (0)