Working with microcontrollers STM32 requires not only knowledge in the field of electronics, but also the right tools. STM32CubeMX - this is the official software from STMicroelectronics, which simplifies peripheral configuration, code generation, and project initialization for the family STM32. Without this tool, development based on Cortex-M can turn into tedious manual register programming.
However, many encounter problems already at the download stage: where can I find the current version? How to avoid viruses when downloading from third-party sites? Why does the installer give compatibility errors? In this article we will look at all official and verified sources for downloading STM32CubeMX, and also give step-by-step installation instructions, taking into account typical errors on Windows 10/11, Linux and macOS.
Official sources for downloading STM32CubeMX
The only reliable way to get a clean version STM32CubeMX Without the risk of infecting the system, download it from the manufacturer’s website. STMicroelectronics provides software for free, but with mandatory registration. Here are direct links to relevant resources:
- 🔗 Official page STM32CubeMX - here is always the latest stable version (at the time of updating the article - v6.12.0).
- 📦 MyST personal account — after registration, access to the version archive and additional plugins is available.
- 📄 Documentation and release notes — here you can check compatibility with your OS.
⚠️ Attention: By downloading software from torrent trackers or file hosting services (for example, rutracker.org, 4pda.to), you risk getting a modified build with built-in miners or spyware. Even if the antivirus does not swear, such versions may contain vulnerabilities that are exploited when debuggers are connected to the microcontroller.
- From the official website of ST
- From torrent trackers
- From file hosting services (Mail.ru, Yandex.Disk)
- From Linux repositories (apt, snap)
- Other source
System requirements and compatibility
Before downloading, make sure your computer meets the minimum requirements. STM32CubeMX does not apply to resource-intensive programs, but some versions may conflict with outdated libraries.
| Parameter | Windows | Linux (Ubuntu/Debian) | macOS |
|---|---|---|---|
| Supported OS versions | 10/11 (x64) | 20.04 LTS and newer | 10.15 (Catalina) and later |
| Architecture | x86_64 | x86_64, ARM64 (with emulation) | x86_64, Apple Silicon (M1/M2) |
| Java | JRE 8+ (included in installer) | OpenJDK 11+ | OpenJDK 11+ |
| Disk space | 500 MB | 600 MB | 700 MB |
⚠️ Attention: On Windows 7 latest versions STM32CubeMX are not officially supported. If you need compatibility with this OS, download the version v6.3.0 or older, but note that it does not support newer microcontroller lines (for example, STM32H7RS or STM32U5).
For Linux It is recommended to install the software via .deb/.rpm packages or use snap:
sudo snap install stm32cubemx --classic
Step-by-step installation instructions on Windows
Installation STM32CubeMX on Windows it usually doesn’t cause any difficulties, but there are nuances that many people forget about. Follow this algorithm to avoid errors:
- Download the installer from the official website (the file will have a name like
SetupSTM32CubeMX-x.x.x.exe). - Run the installer as administrator (right click →
Run as administrator). - At the component selection stage, leave the checkboxes on
STM32CubeMXAndSTM32Cube Firmware Packages(the latter will be needed to work with peripherals). - Specify the installation path without Cyrillic characters (for example,
C:\ST\STM32CubeMX). - Wait for the installation to complete and be sure to restart your PC - this is necessary to register system variables.
Make sure that the antivirus is not blocking Java processes|
Check for write permissions in the installation folder|
Disable VPN (may block license activation)|
Update drivers for development boards (ST-Link, J-Link)-->
If after installation STM32CubeMX does not start, check:
- 🛠️ Availability
Javain the system variablePATH(checked by the commandjava -versioninCMD). - 🔒 Execute permissions for the file
STM32CubeMX.exe(properties → security). - 🚫 Conflicts with other Java applications (for example, Eclipse or Android Studio).
If the installer gives an error "Failed to create the Java Virtual Machine", reduce the value Xmx in the file STM32CubeMX.ini (by default it is located in the installation folder). Replace the string -Xmx1024m on -Xmx512m.
Installation on Linux: features and life hacks
On Linux installation process STM32CubeMX depends on the distribution. The most reliable way is to use .tar.gz-archive from the official website, but there are alternatives:
For Ubuntu/Debian:
# Установка через snap (рекомендуется)sudo snap install stm32cubemx --classic
# Или через .deb пакет
wget https://www.st.com/content/ccc/resource/technical/software/sw_development_suite/group0/5a/9f/6c/3d/2a/54/47/9c/STM32CubeMX/files/SetupSTM32CubeMX-x.x.x.linux.deb
sudo dpkg -i SetupSTM32CubeMX-x.x.x.linux.deb
sudo apt --fix-broken install
For Arch Linux (via AUR):
yay -S stm32cubemx
⚠️ Attention: On some distributions (for example, Fedora or OpenSUSE) may require manual installation of dependencies:
sudo dnf install java-11-openjdk xorg-x11-server-Xorg xterm
After installation, add a shortcut to launch:
sudo ln -s /opt/ST/STM32CubeMX/STM32CubeMX /usr/local/bin/stm32cubemx
Solving the problem with fonts in Linux
If the STM32CubeMX displays "squares" instead of text, install Microsoft fonts:
sudo apt install ttf-mscorefonts-installer
Then restart the program.
Alternative download methods (if the official site is not available)
Sometimes access to the site STMicroelectronics may be limited (for example, due to a corporate firewall or regional blocking). In such cases, you can use proven alternatives:
- 🌍 Official GitHub repository — here are the sources and links to the latest releases.
- 📦 ARM Keil Pack Installer — contains integrated packages for STM32 (including CubeMX).
- 📚 ST Community Forum — moderators often post mirrors for downloading.
⚠️ Attention: Avoid sites like softonic.com or filehippo.com — they often distribute outdated versions with adware. If you urgently need a specific version (for example, v6.5.0 for compatibility with the project), request it via ST technical support - they will provide a direct link.
Updating STM32CubeMX to the latest version
STM32CubeMX supports two update methods: through the built-in manager or manual installation over the old version. The first method is preferable, but can sometimes fail.
To update through the program interface:
- Open STM32CubeMX and go to
Help → Check for Updates. - If an update is available, click
Download and Install. - Wait for the process to complete and restart the program.
If automatic update does not work:
- Download the new version from the official website.
- Install it in the same folder as the previous one (the installer itself will offer to update the files).
- After installation, check the settings in
Preferences → Firmware Packages— sometimes the paths to packages get confused.
Before upgrading, export your current projects in .ioc - new versions of CubeMX may not convert old configuration files correctly.
Common mistakes and their solutions
Even after successful installation, users encounter errors. Here are the most common of them and how to eliminate them:
| Error | Reason | Solution |
|---|---|---|
Java Virtual Machine launcher error |
JVM out of memory | Edit STM32CubeMX.ini, reducing -Xmx |
Failed to load firmware packages |
Damaged files in a folder Repositories |
Delete folder Repositories and restart CubeMX (it will boot again) |
ST-Link not detected |
Debugger drivers are missing | Install STM32 ST-Link Utility |
Pin conflict detected |
Incorrect peripheral configuration | Check the pin assignments in Pinout View |
If STM32CubeMX hangs when generating code, try:
- 🔄 Disable option
Generate peripheral initialization as a pair of '.c/.h' files per peripheralin the project settings. - 🗑️ Clear program cache (folder
.STM32CubeMXin the user's home directory). - 🔌 Reconnect the development board (sometimes CubeMX “forgets” about detected devices).
FAQ: answers to frequently asked questions
Is it possible to use STM32CubeMX without registering on the ST website?
Technically, yes - the downloaded installer does not require an account to work. However, without registration, you will not be able to download firmware package updates (for example, for new microcontrollers STM32G4 or STM32WB). Also, some features, such as cloud import of projects, will not be available.
How to transfer STM32CubeMX settings to another computer?
Copy the following folders from the installation directory:
db/— contains a database of microcontrollers;Repositories/— firmware packages;workspace/- your projects (files.ioc).
Also export settings from Preferences → Export.
Does STM32CubeMX support microcontrollers from other manufacturers (NXP, Microchip)?
No, STM32CubeMX only works with microcontrollers STM32. For NXP use MCUXpresso Config Tools, for Microchip — MPLAB Code Configurator.
Is it possible to run STM32CubeMX on Raspberry Pi?
Officially no - STM32CubeMX requires x86_64-architecture. However there are workarounds:
- Use Raspberry Pi 4/5 with 64-bit OS and emulator
Exagear(paid). - Run via
Wine(unstable). - Connect via
RDPto a remote Windows PC.
For a light configuration it is better to use alternative instruments like CubeIDE for ARM.
How to speed up code generation in STM32CubeMX?
If generation takes too long:
- Disable unnecessary peripheral devices in
Pinout View. - Reduce the code optimization level in the project settings (
Project Manager → Code Generator). - Use an SSD instead of a HDD - this speeds up work with firmware packages.
- Close other Java applications (for example, Android Studio or IntelliJ IDEA).