2025-04-15 10:34 PM
Hello everyone,
I wanted to check if there is any updated information regarding when STM32CubeMX will officially enable generation and support of C++ code. Currently, I'm still relying on various workarounds to implement projects in C++, which unnecessarily complicates the development process.
Does anyone have new insights or know of an official roadmap from STMicroelectronics?
Adding native C++ support would be a significant improvement, especially for higher performance STM32 microcontrollers like the STM32H7, STM32U5, etc. series. C++ enables better code organization through object-oriented programming, making it easier to manage complex projects.
2025-04-16 12:37 AM
Hello @EniRot99
STM32CubeIDE can help generate C++ projects. You can follow these steps to convert a CubeMX project to a C++ project:
1-Generate the CubeMX project.
2- Open the project STM32CubeIDE
3- Right click on the project --> Convert to C++ Project" option to add C++ nature to the project.
4- Rename "main.c" to "main.cpp".
5- Adjust the project properties to use the C++ compiler and set the desired C++ standard