cancel
Showing results for 
Search instead for 
Did you mean: 

How can I check the STM32Cube FW version used in my project?

Stefanie LAU
ST Employee

Every STM32 comes with a STM32Cube MCU package composed of the STM32Cube hardware abstraction layer (HAL) and the low-layer (LL) APIs, plus a consistent set of middleware components (RTOS, USB, FAT file system, etc). In addition, all embedded software utilities are delivered with a full set of examples running on STMicroelectronics boards. The STM32Cube FW package gathers in one single package all the generic embedded software components required to develop an application on the STM32 microcontrollers.
These STM32Cube MCU packages are available for download on st.com, Github or STM32CubeMX’s GUI.
st.com (click here for a direct link):

StefanieLAU_0-1693990249784.png


ST’s GitHub (click here for a direct link):

StefanieLAU_1-1693990249791.png

STM32CubeMX’s GUI:

StefanieLAU_2-1693990249885.png

There are two methods that can be used to check your project’s used firmware version: using STM32CubeMX’s GUI or through a C file and MCU package release notes, both which will be demonstrated in this article.

STM32CubeMX’s .ioc file method:
To check the current STM32CubeMX project’s firmware version you are using in STM32CubeMX, simply navigate to project manager > project > MCU and Firmware Package as shown below.

StefanieLAU_3-1693990249908.png

By default, STM32CubeMX should have selected the latest version of the firmware package available in your STM32Cube repository.
If you are interested in modifying this default firmware package version to another available firmware package version, please review the published article "How to update my project's current STM32Cube firmware version in STM32CubeMx?
C file and MCU package release notes method:
Sometimes the .ioc file is not available for a project. To figure out the STM32Cube version used for the project, we can use a combination of the project’s c file and MCU package release notes.

Step 1. As an example, we will use a generated STM32F7 project. Let’s begin by locating the stm32f7xx_hal.c file on your computer.  
This file can be found at the following path: C:\Users\stmicroelectronics\STM32Cube\Repository\STM32Cube_FW_F7_VX.X.X\Drivers\STM32G0xx_HAL_Driver\Src

StefanieLAU_4-1693990250151.png

 


Step 2. Open the file and scroll down to line 54. The code starting from line 54 indicates the HAL driver version. Take note of this version number as we will need it in the next step.  

StefanieLAU_5-1693990250148.png

Step 3. Locate and open the release notes file of the STM32Cube package for your project’s target STM32 device.

StefanieLAU_6-1693990249839.png

In step 2, we read that the HAL version used for our project was v1.3.0. We will want to check the drivers table under the contents portion of each update, to look for STM32F4xx HAL v1.3.0.

StefanieLAU_7-1693990250043.png

In this case, we see that for update v1.17.0 the STM32F7xx HAL version is v1.3.0 which matches our project’s HAL version as found in line 53 of the stm32f7xx_hal.c file.
Thus, we can deduce that the STM32CubeF7 version used for this project is v1.17.0.
Please note that it’s always recommended for you to keep up to date with the latest STM32Cube FW package versions, as these packages are constantly under maintenance and updated on a regular basis.


Relevant Links & Documentation:

Editors note: This article was originally published 2023-04-14. The article had 261 views prior to it's republishing.

Version history
Last update:
‎2023-12-07 05:31 AM
Updated by:
Contributors