FreeRTOS Vs CMSIS-RTOS API for STM32?

Hi, I wish to use FreeRTOS on STM32F4xx series microcontrollers. I've previously ported FreeRTOS in a project with other target MCUs to implement the FreeRTOS functions. It worked very well. Now with STM32 MCUs, I realize you can include a layer (CMSIS) on top of the FreeRTOS layer, does there exist a detailed guide of these CMSIS functions and when to use it? what are the advantages and disadvantages of using this layer? Also, I read that CMSIS-RTOS V2 has issues with recent updates.
No description
2 Replies
Navadeep
Navadeep7mo ago
Having similar doubt but there is hinting that it helps with portability and switching incase of adversities https://forums.freertos.org/t/freertos-and-cmsis-rtos-use-or-not-use/16056/2
FreeRTOS Community Forums
FreeRTOS and CMSIS-RTOS (use or not use?)
CMSIS-RTOS lets you change what RTOS you will be using with minimal other changes. The cost is that you will be programming to a minimum common capability expected out of an RTOS. The biggest advantage to doing so is if something happens to the RTOS you started with, you can easily switch, but that seems unlikely with FreeRTOS. The other possib...
Saßì
Saßì7mo ago
Certainly! The CMSIS (Cortex Microcontroller Software Interface Standard) provides a layer of abstraction for Cortex-M processors, allowing software developers to write consistent and portable code across different microcontroller vendors. CMSIS-RTOS is a part of CMSIS that defines an API for real-time operating systems, and FreeRTOS has a CMSIS-RTOS API layer. CMSIS Functions in FreeRTOS: CMSIS-RTOS Wrapper Layer: The CMSIS-RTOS layer in FreeRTOS provides a standard interface for RTOS functionalities, making it easier to port code between different RTOS platforms. Advantages: Portability: CMSIS-RTOS provides a standardized interface, enhancing portability between different RTOS kernels. Vendor Independence: Code developed using CMSIS can be more easily adapted to other Cortex-M microcontrollers from different vendors. Disadvantages: Abstraction Overhead: The CMSIS layer introduces an additional abstraction, which might slightly impact performance compared to using the native FreeRTOS API directly. Feature Limitations: While CMSIS provides a common set of functionalities, some advanced features of specific RTOS kernels might not be accessible through CMSIS. CMSIS-RTOS V2: Issues with Recent Updates: Like any software, CMSIS-RTOS undergoes updates and improvements. It's essential to check release notes and documentation for the specific version you're using to understand any reported issues or improvements. Documentation: For detailed information on CMSIS-RTOS functions and when to use them, you can refer to the ARM documentation. The official CMSIS documentation is available on the ARM website. FreeRTOS Documentation: Additionally, FreeRTOS provides documentation on integrating with CMSIS, which includes guidance on when and how to use CMSIS functions in the context of FreeRTOS. Community Forums: For the most current information and community insights, it's often helpful to check the FreeRTOS community forums where developers share their experiences and solutions. When using CMSIS-RTOS functions with FreeRTOS on STM32F4xx series MCUs, it's crucial to consult the documentation provided by both ARM (for CMSIS) and FreeRTOS for specific details and considerations related to the STM32 platform and any potential CMSIS-RTOS version issues. Always consider the specific requirements and constraints of your project.