2020-11-27 04:36 AM
Hello,
I updated the HAL libraries for STM32G072RB from 1.3.0 to 1.4.0 (using the CubeIDE and opening the .ioc file and confirming the Migration).
However, I can't compile the project any more. Is there something I can do?
make -j8 all
arm-none-eabi-gcc "../Core/Src/system_stm32g0xx.c" -mcpu=cortex-m0plus -std=gnu11 -g3 -DSTM32G071xx -DUSE_HAL_DRIVER -DDEBUG -c -I/home/david/c/stm32/common -I../Drivers/CMSIS/Include -I../Core/Inc -I../Drivers/STM32G0xx_HAL_Driver/Inc -I../Drivers/CMSIS/Device/ST/STM32G0xx/Include -I../Drivers/STM32G0xx_HAL_Driver/Inc/Legacy -O0 -ffunction-sections -fdata-sections -Wall -fstack-usage -MMD -MP -MF"Core/Src/system_stm32g0xx.d" -MT"Core/Src/system_stm32g0xx.o" --specs=nano.specs -mfloat-abi=soft -mthumb -o "Core/Src/system_stm32g0xx.o"
../Core/Src/system_stm32g0xx.c: In function 'SystemCoreClockUpdate':
../Core/Src/system_stm32g0xx.c:231:10: error: 'RCC_CFGR_SWS_HSE' undeclared (first use in this function); did you mean 'RCC_CFGR_SWS_Msk'?
case RCC_CFGR_SWS_HSE: /* HSE used as system clock */
^~~~~~~~~~~~~~~~
RCC_CFGR_SWS_Msk
../Core/Src/system_stm32g0xx.c:231:10: note: each undeclared identifier is reported only once for each function it appears in
../Core/Src/system_stm32g0xx.c:235:10: error: 'RCC_CFGR_SWS_LSI' undeclared (first use in this function); did you mean 'RCC_CFGR_SWS_HSE'?
case RCC_CFGR_SWS_LSI: /* LSI used as system clock */
^~~~~~~~~~~~~~~~
RCC_CFGR_SWS_HSE
../Core/Src/system_stm32g0xx.c:239:10: error: 'RCC_CFGR_SWS_LSE' undeclared (first use in this function); did you mean 'RCC_CFGR_SWS_LSI'?
case RCC_CFGR_SWS_LSE: /* LSE used as system clock */
^~~~~~~~~~~~~~~~
RCC_CFGR_SWS_LSI
../Core/Src/system_stm32g0xx.c:243:10: error: 'RCC_CFGR_SWS_PLL' undeclared (first use in this function); did you mean 'RCC_CFGR_SWS_Pos'?
case RCC_CFGR_SWS_PLL: /* PLL used as system clock */
^~~~~~~~~~~~~~~~
RCC_CFGR_SWS_Pos
../Core/Src/system_stm32g0xx.c:264:10: error: 'RCC_CFGR_SWS_HSI' undeclared (first use in this function); did you mean 'RCC_CFGR_SWS_LSI'?
case RCC_CFGR_SWS_HSI: /* HSI used as system clock */
^~~~~~~~~~~~~~~~
RCC_CFGR_SWS_LSI
make: *** [Core/Src/subdir.mk:33: Core/Src/system_stm32g0xx.o] Error 1
"make -j8 all" terminated with exit code 2. Build might be incomplete.
13:33:42 Build Failed. 6 errors, 0 warnings. (took 695ms)
Solved! Go to Solution.
2020-11-27 05:23 AM
Hello @DKo.15udela ,
I have already passed this issue along to our CubeMX team for fix (See this discussion).
Thank you for your contribution
Imen
2020-11-27 05:23 AM
Hello @DKo.15udela ,
I have already passed this issue along to our CubeMX team for fix (See this discussion).
Thank you for your contribution
Imen
2020-11-27 05:41 AM
Thank you, Imen, this is exactly the same issue. I am sorry for creating a duplicate thread.
2020-11-27 05:45 AM
You are welcome :smiling_face_with_smiling_eyes:
Imen
2020-12-21 05:46 AM
Same issue here. STM32CubeIDE 1.5.1and STM32Cube FW_G0 V1.4.0 on MCU STM32G071G8Ux
Still no solution?
2021-01-06 07:00 AM
Hello,
I am also experiencing this same issue.
When will this be corrected?
2021-04-02 03:19 AM
Just updated the HAL without expecting it to crash my prokject. Is there a solution? How can I revert to the previous version?
2021-04-18 03:28 AM
Same problem here with STM32G030. Please fix this asap. Thanks
2021-04-18 06:45 AM
Same problem, but temporary solution see
https://community.st.com/s/question/0D53W00000OUZHcSAP/stm32cubefwg0v140-bu