Ask questions on STM32CubeMX. Discuss code generation and configuration challenges, among other topics.
Most recent activity
I have just spoken with an ST sidekick, and I was informed that STM32CubeMX is currently not supported on Windows ARM64.Thank you for the clarification.
Question moved from this post. Hi @mƎALLEm ,I am using STMCubeIDE with cubeMX, in that there is no such configuration for VREFBUF. is there any alternative way for that?
On a Nucleo-H563ZI with CubeIDE 1.14.0 and firmware package for H5 1.1.1.I managed to get SPI transmit and receive using DMA, triggered by a timer, going not using linked lists. I get my requested number of transmissions and results into my buffers as witnessed on an oscilloscope and a live watchpoint.But when I enable circular mode, no other modifications, in MX_SPI1_Init - HAL_SPI_Init - HAL_SPI_MspInit it sets up NodeConfig.Init.SrcDataWidth = DMA_SRC_DATAWIDTH_WORD; NodeConfig.Init.DestDataWidth = DMA_DEST_DATAWIDTH_HALFWORD;builds the node (whatever that is), inserts it into the correct DMA channel, sets circular mode, basically looks like magic but I can imagine what it is doing. But then the stuff in the NodeConfig doesn't get applied to handle_GPDMA1_Channel1, so later when I finally call HAL_SPI_TransmitReceive_DMA, it gets grumpy around line 2230 because hspi->hdmarx->Init is all zeros still. It never got updated maybe?I think there is a problem with HAL_SPI_M
CubeMX 6.16.1 MacOS 15.7.3 IntelSTM32H563ZITxI have a project using FreeRTOS with 5 tasks.If you go into <Categories><X-CUBE_FREERTOS>Choose <Tasks and Queues> click on one of the tasks. An Edit panel comes up to help you set all sorts of stuff.Click on "Task name" column header to re-sort the list according to task name and click on one of the tasks. The Edit panel comes up for the wrong task.The changes you make get applied to the task shown, but the wrong task gets shown.That is all
I'm attempting to follow https://community.st.com/t5/stm32-mcus/using-the-itm-console-for-printf-redirects-and-lwip-debug/tac-p/850072/highlight/true#M1661 but this always fails. This is on an STM32F303K8T. My reference manual saysand offers an example: "To output a simple value to the TPIU:• Configure the TPIU and assign TRACE I/Os by configuring the DBGMCU_CR (refer toSection 33.17.2: TRACE pin assignment and Section 33.16.3: Debug MCUconfiguration register)• Write 0xC5ACCE55 to the ITM Lock Access Register to unlock the write access to theITM registers• Write 0x00010005 to the ITM Trace Control Register to enable the ITM with Syncenabled and an ATB ID different from 0x00• Write 0x1 to the ITM Trace Enable Register to enable the Stimulus Port 0• Write 0x1 to the ITM Trace Privilege Register to unmask stimulus ports 7:0• Write the value to output in the Stimulus Port Register 0: this can be done by software(using a printf function)"Based on this, and based
Pull field is not set on UART8 GPIO when configured as single-wire.STM32H743 / STM32H753.
I'm using STM32CubeMX for STM32N657x0HxQ controller. I would like to use ST ISP Library to handle MB1854 camera module. But I could not find the X-CUBE-ISP in STM32CubeMX Pinout & Configuration page, which is as follows. So I tried to import x-cube-isp.zip file downloaded from GitHub. But I came across the following error message. My STM32CubeMX version is Version 6.16.1 for Windows 11.
Hello, I'm working with the STM32H7S7L8-DK and i want to use both USB HS and FS in device mode but it seems in cube mx that i'm unable to enable both IRQ If i enable the HS one the FS one isn't generated and same fort the other way Is it a bug and how manage this to get it work?Thanks
Hi,after updating STM32CubeMX, I was no longer able to start the program without admin rights.In the past, I always used STM32CubeMX integrated with STM32CubeIDE and was able to update everything without any admin rights. Starting with version 2.0.0 of STM32CubeIDE, STM32CubeMX was removed, so I installed it separately (STM32CubeMX 6.16.0). For the installation, my company's IT department selected the installation for all users, and until now I have been able to use the program without any problems.I needed to update STM32CubeMX to the new version 6.16.1, and that's where I ran into my first problem: I couldn't update to the new version without admin rights, so I had to contact the IT department to do the update. The big problem is that after the update, I was no longer able to start the program without admin rights, and the quickest solution was to uninstall STM32CubeMX and then install version 6.16.1 directly. Now I can use the application again without any problems, but I would like
Hello!I have encountered a problem - I am unable to create a project for STM32F769I-DISCO board with both FreeRTOS using CMSIS_V2 interface and LwIP with NO_SYS parameter set to "OS Used".In old project that was setup with STM32CubeMX V6.14.0 using STM32Cube FW-F7 V1.17.2 I had no problem with setting both CMSIS_V2 and "OS Used" value.In new project that uses STM32CubeMX V6.16.1 and STM32Cube FW_F7 V1.14.4 I have to use CMSIS_V1 interface for FreeRTOS if I want to change LwIP's NO_SYS parameter to "OS Used".Did something change in recent updates, is it a bug or am I doing something wrong? Thank You for help in advance. Using FreeRTOS with CMSIS_V2Can't change NO_OS parameterCubeMX 6.16.1, Firmware F7_V1.17.4
Hi @TDK ,I have just downloaded and installed the new version 2.0.0 of the IDE and the MX software (since it is no longer integrated). I was working on a project based on the STM32WB5MMG, and everything was working correctly with IDE version 1.19.0 and STM32Cube FW_WB V1.23.0.After opening the project and regenerating the code with the new IDE version and STM32Cube FW_WB V1.24.0, I noticed some issues: in custom_stm.c it generates two times this variables:/* USER CODE BEGIN PM */ /* USER CODE END PM */ /* Private variables ---------------------------------------------------------*/ uint16_t SizeFw_Ver = 1; uint16_t SizeDatetime = 7; uint16_t SizeStatus = 6; uint16_t SizeMonitor = 15; uint16_t SizeEnv_Data = 90; uint16_t SizeFw_Ver = 1; uint16_t SizeDatetime = 7; uint16_t SizeStatus = 6; uint16_t SizeMonitor = 15; uint16_t SizeEnv_Data = 90;2. it doesn't generate any local functions in custom_app.c:/* USER CODE END FD */ /***************************************************
I need to use STM32CubeMX to generate initialization routine for two pins (7,8) on SO8 package of STM32CubeC011 MCU that switches the pin's roles BACK to STLINK mode. I created a new project on STM32CubeMX whose only task is to initialize pins 7 and 8 to PA13/PA14 SWCLK/SWDIO. I wanted to copy the GPIO initialization function MX generated into an existing application which had previously (that is, after start-up) changed the two pins to another mode; after that work is done, the two pins no longer need to be in GPIO mode and can be switched back to STLINK mode to facilitate firmware upgrade/debug/etc.Two screen captures from STLINK32MX are below (pin assignments and project specifications.)The resulting (very short) C language program generates the following code for initialization of the two pins: static void MX_GPIO_Init(void) { /* USER CODE BEGIN MX_GPIO_Init_1 */ /* USER CODE END MX_GPIO_Init_1 */ /* GPIO Ports Clock Enable */ __HAL_RCC_GPIOA_CLK_ENABLE(); /* USER CODE BEGIN M
When I open the official example using the example selector, CubeMX cannot display the graphical configuration of that example. I would like to know if it is possible to display the graphical configuration of the example in CubeMX. Thank you very much, because that would make learning much easier.
Hello!I tried to generate the code for SDMMC using CMake, but was facing an error that did not let me finish building the project. The error was:".../FileX/Target/fx_stm32_sd_driver_glue.c:40:(.text.fx_stm32_sd_init+0xc): undefined reference to `MX_SDMMC1_SD_Init'".Also, using ThreadX and FileX. In FileX I enabled the setting "FX Driver Initializes the SD IP" (set to true).I saw that the MX_SDMMC1_SD_Init function is inside the main.c file, but it is declared with the "static". So, right now, to be able to build the project with CMake, I need to manually remove the "static" from the MX_SDMMC1_SD_Init function definition in main.c file.
Hi,I'm building a BLE application using custom template in STM32CubeMX. I have two services. The first one has only one characteristic with the properties "Read" and "Write without response". The second service has two characteristics, both with "Read" and "Notify" properties.The code generated in "custom_app.c" have the function:void Custom_<Srv2Char1>_Update_Char(void){...} void Custom_<Srv2Char1>_Send_Notification(void){...} void Custom_<Srv2Char2>_Update_Char(void){...} void Custom_<Srv2Char2>_Send_Notification(void){...}However, no function is generated for the characteristic of the first service. I expected to have a function like this:void Custom_<Srv1Char1>_Update_Char(void){...} I performed some tests:Used shorter names for the characteristics.Created two new characteristics, one in service 1 and the other in service 2, both with only the "Read" property enabled.In both cases, no "Update_Char" function was generated.I don’t know if this
Hello, It seems that the pin for TIM1_CH3N should be PE12 as per schematic but CubeMX shows it as PB0. Please correct it and let me know how to fix it at my end for time being.
CubeMX 6.16.0's "Memory Management" Tool assumes Rx_PoolSection size to coincide with the Eth "Rx Buffers Length" - is that correct? I used CubeMX 6.16.0 to create a project for an STM32 H755ZI-Q.Then I opted to use the Tools -> "Memory Management" tool and afterwards enabled the ETH [ethernet] component. This automatically generated the required sections in the "Memory Management" tool. Great.Then I enabled LwIP [with RTOS and CMSIS v2] and generated code.Compiling this code worked - linking however did not. It told me the contents of Rx_PoolSection were too big, i.e. the section too small: EBoxNG3_CM7.elf section `.Rx_PoolSection' will not fit in region `Rx_PoolSection'region `Rx_PoolSection' overflowed by 225668 The buffer for the RX_POOL is declared in CM7\LWIP\Target\ethernetif.c:98:#define ETH_RX_BUFFER_CNT 12U LWIP_MEMPOOL_DECLARE(RX_POOL, ETH_RX_BUFFER_CNT, sizeof(RxBuff_t), "Zero-copy RX PBUF pool");with__attribute__((section(".Rx_PoolSection"))) extern
Hello,I was using STM32CubeMX, but starting two days ago, when I launch the program, only the splash screen appears and the STM32CubeMX does not proceed any further.1. I have tried deleting the program, restarting the computer, reinstalling it, and running it again.2. Adding a new user is not possible; the user creation permission is restricted to the company's IT administrator.I would appreciate any suggestions on additional steps I could take to resolve this issue.
I have a Discovery board B-L072Z-LRWAN1 and I am trying to set up a project using CubeIDE but get the following, So I check to see if the L0 & LRWAN packages are in the repository, Yes, they're there. I click OK & Cube carries on setting itself up & up pops the ioc window. I press configure & generate & get some C code but the build option is greyed out. What am I missing here?
We have a board with a stm32u5. were VDDIO are connected to 1.8 V and the I2C bus have pullup to 3.0 V. Some I2C devices uses 3.0 V logic levels and som 1.8 V. Between which voltage levels shall i measure the rise and falltime that i enter in cubemx. 30%->70% of 1.8 V or 3.0 V .We have possibility to turn off and on some devices on the bus that changes the rise and falltime on the bus. Shall then the longer or shorter rise/falltimes be used?One reason we are asking is that our design engineers wonder why the signal of the clock never is piece wise equal in on and off timing as it is the case with other I2C masters
Hi there,I'm using an N6 with the latest version of IDE and MX with the FSBL/Appli dual project structure as per the FSBL LRUN template, and MX is incorrectly managing code. When using X-CUBE-FREERTOS in Application mode, code generation and cleanup is buggy. I've attached a FreeMarker template error generated WITHIN app_freertos.cWhen removing FreeRTOS from the project, MX fails to remove void MX_FREERTOS_Init(void); and MX_FREERTOS_Init(); from main.c. It also doesn't remove the head app_freertos.h and FreeRTOSConfig.h header files, but does remove the source file. I get the following compiler error:make[1]: *** No rule to make target '/Users/h7/STM32CubeIDE/workspace_1.16.1/N6Project/Appli/Src/app_freertos.c', needed by 'Application/User/app_freertos.o'. Stop.I'm also finding that the files that I have added to the build exclusion list in libraries that I've included in Middlewares/Third_Party are being reset. After a code generation, those files that MX should not be touc
Hello,I have observed this issue in version 6.16.1 across several MCU series (F3, F4, H5, H7), though it appears likely that all earlier versions are affected.The generated .cmake toolchain files incorrectly treat the --specs=nano.specs option as linker-only. This option should be applied globally, as it also affects the system include paths used during compilation. Specifically, it causes the compiler to include arm-none-eabi/include/newlib-nano/newlib.h instead of the standard arm-none-eabi/include/newlib.h.While this mismatch probably does not break ABI compatibility—since the structures provided from the standard headers are larger than those used in the compiled newlib-nano library—it does negate the RAM usage benefits of newlib-nano. This is particularly problematic when using the USE_NEWLIB_REENTRANT FreeRTOS option.Regards,Peter
The application bundle contains Contents/MacOs instead of the required Contents/MacOS. On case-sensitive file systems, this prevents LaunchServices/Finder from starting the app.The binary runs correctly when launched directly from Terminal.Renaming MacOs → MacOS also seems to solve the issue.Seems to be an error in the ST packaging system.
"I am generating code using STM32CubeMX for the STM32WB09, aiming to implement BLE with CMSIS-OS.I am facing an issue where, even after explicitly disabling the Sequencer when enabling CMSIS-OS, CubeMX still generates code that relies on the Sequencer. This results in an application with multiple errors.Upon checking the official examples at https://github.com/STMicroelectronics/STM32CubeWB0, I noticed that the projects utilizing RTOS do not seem to rely on CubeMX (the .ioc files are missing).Is there a known limitation or bug regarding this behavior in CubeMX?"
Hi,I'm probably doing wrong as a newbie in STM32 programmation:I try to generate this configuration code for dma but I can't see any dma.c file in the project folder.(I did refresh the project after generating the code)Thanks for help
ST Community highlights – April to June 2026
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.