STM32CubeIDE is an IDE from STMicroelectronics specifically for the STM32 range of microcontrollers. It supports firmware development in C or C++. It integrates with STM32Cube.
The installer is approx. 685MiB.
Default directories (examples below shown for
<user home directory>/STM32CubeIDE/workspace_1.3.0
<user home directory>/STM32Cube/Repository
SEGGER J-Link drivers, ST_LINK drivers and ST_LINK server software is provided with the installation.
Default File Structure
<root_project_dir> |-- Core | |-- Inc Contains the user header files. | |-- Src Contains the user source code. | |-- Startup |-- Debug Default directory for debug build artifacts. |-- Drivers |-- .cproject |-- .mxproject |-- .project |-- <project_name>.ioc Contains the pinout and hardware configuration of the micro. |-- <micro_name>_FLASH.ld This is the linker script for the micro.
The .ioc File
.ioc file contains information about the target microcontroller and the hardware configuration for your project.
Enabling peripherals via the
.ioc file generates
MX_<peripheral_name>_Init() functions in the
main.c file. HAL driver files are also provided for peripherals. They are written in a object-orientated way (e.g. every
UART related HAL function which take a pointer to the UART object as it’s first parameter).
Git Ignore File
Confusingly, even if you specify the project as a “C++ Project” when creating it, you will be presented with
main.c file. You can rename this to
main.cpp to begin using C++ (this will cause
arm-none-eabi-g++ to be called on
main.cpp rather than
arm-none-eabi-gcc, which will allow you to include C++ code).
The linker is called correctly regardless of the extension of
arm-none-eabi-g++ will be called during the linking step.
However, when you change the peripheral configurations using the
.ioc file and re-generate code, it will also recreate the
This work is licensed under a Creative Commons Attribution 4.0 International License .
- integrated development environments