Skip to main content
Associate
Nov 4, 2026 10:20 PM UTC
Question

STM32CubeMX 6.18: FreeRTOS CMSIS-RTOS2 Non-Secure settings lost after reopening TrustZone project on STM32H563ZIT6

Hello,

I believe I have identified a bug in STM32CubeMX 6.18 on STM32H563ZIT6.

## Context
- MCU: STM32H563ZIT6
- Tool: STM32CubeMX 6.18
- Firmware package: STM32CubeH5 1.7.0
- Configuration: basic project, with no specific configuration other than:
  - TrustZone enabled
  - FreeRTOS enabled
  - CMSIS-RTOS2 enabled in both Secure and Non-Secure contexts

My goal is simply to run FreeRTOS with one task for now, and then set up proper memory management and access control, which requires using CMSIS-RTOS2 in the Non-Secure project.

## Observed behavior
When the project is created for the first time, everything works correctly:
- the project is generated successfully;
- the CMSIS-RTOS2 configuration on the Non-Secure side is accessible in the interface;
- the FreeRTOS / CMSIS-RTOS2 settings are correctly present in the `.ioc` file.

However, after saving and reopening the project in STM32CubeMX:
- the CMSIS checkbox on the Non-Secure side is still visible;
- but the CMSIS-RTOS2 Non-Secure configuration menu is no longer accessible;
- if the project is saved again, the CMSIS-RTOS2 Non-Secure settings disappear from the `.ioc` file.

## Impact
This behavior is very limiting, because the only workaround I have found so far to restore access to the CMSIS-RTOS2 Non-Secure configuration is to:
1. remove FreeRTOS from the Non-Secure side;
2. enable FreeRTOS again on the Non-Secure side.

But this causes the complete loss of the existing configuration.

## Reproducibility
The issue appears to be reproducible with a minimal configuration, without any additional complex settings.

## Question
Can you confirm whether this is a known bug in STM32CubeMX / STM32CubeH5?
Is there any fix or cleaner workaround than removing and re-enabling Non-Secure FreeRTOS?

Thank you.

2 replies

Ghofrane GSOURI
ST Technical Moderator
Nov 5, 2026 9:15 AM UTC

Hello ​@Marc_AlpesDEIS 

Could you please provide your IOC?

I will be waiting for your feedback.

THX

Ghofrane

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.
Associate
Nov 5, 2026 11:17 AM UTC

Hello ​@Ghofrane GSOURI ,

Thank you to take my point.
One Confirmation, I use the STM32CubeMX in version 6.18.1 not 6.18

Please find 2 IOC file

  1. with the RTOS config present juste after creation.
  2. A seconde juste after reopen it and perform a save (Ctrl+S).

Marc