Skip to main content
Associate III
April 20, 2026
Question

STM32CubeMX 6.17. 0 not generating correct cmake file for STM32WL33

  • April 20, 2026
  • 1 reply
  • 150 views

Hi ST,

This is just to let you know that STM32CubeMX version 6.17.0 does not generate correct cmake file for the STM32WL33 and this error results in the microntroller not starting up correctly but hangs in function 

SystemInit() in system_stm32wl3x.c.
 
The problems is that the wrong is -mcpu is generated.

The problem can be found in the file -> path/to/dir/cmake/gcc-arm-none-eabi.cmake

# MCU specific flags
set(TARGET_FLAGS "-mcpu=cortex-m4 ") // wrong for the WL33

# MCU specific flags
set(TARGET_FLAGS "-mcpu=cortex-m0plus ") // correct for the WL33

Ola

1 reply

Technical Moderator
April 24, 2026

Hello @@ola 

Let me thank you for posting.

For more investigation, could you provide please your Ioc.File.

Thanks.

Mahmoud

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
olaAuthor
Associate III
April 25, 2026

Hi Mahmoud,

The problem is not the ioc file. The problem is in the auto generation of the cmake file I mentioned in my message.
I have attached the ioc file as per your request.

Ola