STM32CubeMX CMake project build error
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-02-12 1:10 PM
FAILED: CMakeFiles/rtm.dir/Middlewares/ST/threadx/ports/cortex_m33/gnu/src/tx_thread_context_restore.S.obj
C:\ARM-NO~1\14EFD8~1.2RE\bin\AR19DD~1.EXE -DDEBUG -DSTM32U575xx -DTX_INCLUDE_USER_DEFINE_FILE -DTX_SINGLE_MODE_NON_SECURE=1 -DUSE_HAL_DRIVER -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Core/Inc -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../AZURE_RTOS/App -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Drivers/STM32U5xx_HAL_Driver/Inc -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Drivers/STM32U5xx_HAL_Driver/Inc/Legacy -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Middlewares/ST/threadx/common/inc -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Drivers/CMSIS/Device/ST/STM32U5xx/Include -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Middlewares/ST/threadx/ports/cortex_m33/gnu/inc -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Middlewares/ST/threadx/utility/low_power -ID:/code/firmware/rtm/stm32/cmake/stm32cubemx/../../Drivers/CMSIS/Include -mcpu=cortex-m33 -mfpu=fpv4-sp-d16 -mfloat-abi=hard -Wall -Wextra -Wpedantic -fdata-sections -ffunction-sections -O0 -g3 -x assembler-with-cpp -MMD -MP -g -MD -MT CMakeFiles/rtm.dir/Middlewares/ST/threadx/ports/cortex_m33/gnu/src/tx_thread_context_restore.S.obj -MF CMakeFiles\rtm.dir\Middlewares\ST\threadx\ports\cortex_m33\gnu\src\tx_thread_context_restore.S.obj.d -o CMakeFiles/rtm.dir/Middlewares/ST/threadx/ports/cortex_m33/gnu/src/tx_thread_context_restore.S.obj -c D:/code/firmware/rtm/stm32/Middlewares/ST/threadx/ports/cortex_m33/gnu/src/tx_thread_context_restore.S
D:/code/firmware/rtm/stm32/Core/Inc/tx_user.h: Assembler messages:
D:/code/firmware/rtm/stm32/Core/Inc/tx_user.h:271: Error: bad instruction `void App_ThreadX_LowPower_Timer_Setup(unsigned long count)'
D:/code/firmware/rtm/stm32/Core/Inc/tx_user.h:278: Error: bad instruction `void App_ThreadX_LowPower_Enter(void)'
D:/code/firmware/rtm/stm32/Core/Inc/tx_user.h:282: Error: bad instruction `void App_ThreadX_LowPower_Exit(void)'
D:/code/firmware/rtm/stm32/Core/Inc/tx_user.h:286: Error: bad instruction `unsigned long App_ThreadX_LowPower_Timer_Adjust(void)'
ninja: build stopped: subcommand failed.
Solved! Go to Solution.
- Labels:
-
Power
-
STM32CubeMX
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-05-08 5:34 AM
Hello @OParis
The issue has been solved on STM32CubeMX 6.14.0
Saket_Om
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-02-13 5:29 AM
Hello @JFisher
Could you please share your .ioc file with us? This will help us support you more effectively.
Saket_Om
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-02-14 6:48 AM
Hello @JFisher
I reported your issue internally and will get back to you as soon as possible.
Internal ticket number: 203303 (This is an internal tracking number and is not accessible or usable by customers).
Saket_Om
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-02-14 7:33 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-05-07 11:23 AM
I am also having this issue. Was there an update on this topic since February?
Thanks
Olivier
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-05-07 11:56 AM
It looks like you've put in your tx_user.h file stuff that should not be there. It can contain #defines but not C code such as function prototypes.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-05-08 4:44 AM
You are correct Pavel A.
The function prototypes are put in tx_user.h by STM32CubeMX when setting THREADX->"Low Power"->"Enable LowPower Support" to "Enabled"
I am using STM32CubeMX 6.13.0 for device STM32U073KCU6 with MCU Package 1.2.0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-05-08 5:34 AM
Hello @OParis
The issue has been solved on STM32CubeMX 6.14.0
Saket_Om
