2025-06-29 7:09 PM - last edited on 2025-06-30 7:18 AM by mƎALLEm
Please enlighten me. I added FreeRTOS to my STM32CubeIDE project using IOC. I discovered that I had to choose either CMSIS_V1 or CMSIS_V2 as the FreeRTOS Mode, else FreeRTOS would not be included. I chose CMSIS_V2. I then noticed the FreeRTOS Configuration pane and added a task, timer, and Queue. Upon finding the generated code, I noticed they are created with osThreadNew, osTimerNew, , and osMessageQueueNew. I was expecting xTaskCreateStatic, xTimerCreateStatic, and xQueueCreateStatic instead.
Are the three set of functions somehow the same, or is one a wrapper for the other, or what? Can I still use the FreeRTOS Reference Manual, or do need to find and consult the CMSIS_V2 OS manual instead? Or, maybe I did something wrong.
2025-06-30 7:03 AM - edited 2025-06-30 7:18 AM
Hello,
CMSIS_V1 and CMSIS_V2 are CMSIS wrappers for RTOS implementation. So the application is RTOS agnostic. See CMSIS-RTOS2.
To my knowledge you can still use FreeRTOS APIs but I don't have idea about the impact.
So I recommend to use CMSIS wrappers to prevent any issue.
You can inspire from the examples provided for FreeRTOS in github: https://github.com/STMicroelectronics/STM32CubeF4/tree/master/Projects/STM324xG_EVAL/Applications/FreeRTOS
Hope it helps.