Ask questions on STM32CubeMX. Discuss code generation and configuration challenges, among other topics.
Most recent activity
Please tell me how this pulse value is used in the TIM->PWM Generation CHx.How this value effect the Pwm generation.
When I used the Freertos with STM32L433 which the code was generated by CubeMX. In the system, the ADC, I2C, SPI1 used the DMA function. I found that the code will be occasionally into configASSERT(pxQueue ) and being stalled there.but sometimes it works well (most situation is powered up.)Who know why it caused this issue? how to mitigate?
Hi,Currently we are using STM32H753XIH6 controller. In controller datasheet pin name B6 type is given as VSS but in cubemx it is given as NC. Please clarify which type is correct for B6 pinThanks
Hi ,I`m trying to build a project with STM32CubeMX and use FATFS for SDMMC ,then print it with UART on screen.Here is the configuration on CubeMX.(If I configured wrong way,then you can tell me! I`ll appreciate that)I have built it for many times, but when I ran on my development board, it could`t open directory root and came out error like FR_DISK_ERR.I have checked my card and it work well,so I exclude the problem.I want to figure out that I configure it wrong way or not.Hope anyone can help!Really Appreciate !!
I want to report an error. I use lastest version cubemx v5.3.0. And lastest lib "STM32Cube MCU Package for STM32F1 Series 1.8.0".I use Makefile to build. Not keil.Every time (except first time) I generate code. There is an error in Makefile:I have wait for several months. Please fix it. Thanks!
The "MX_RTC_Init" function called by default from the main.c resets the RTC's date and time to zero values (by default) or to some other predefined constant values.The standard practice is to set a bit in one of the backup registers after setting the date and time and to check the existence of the bit after enabling the backup domain and RTC - if the bit is set then don't touch the date and time.There are no user code sections in MX_RTC_Init to try and change its logic, so what is the recommended way of implementing "don't change the date and time if it is already set" in a Cube generated LL project with RTC enabled?Thank you.
Hello!I am working with following softwares ,and I want to realize CAN communication via example in STM32Demos(D:\MATLAB\STM32-MAT\STM32\STM32demos\Test\CAN\F429I-DISC1\F4_CAN_LoopBackInterrupt)matlab 2018bSTM32CubeMX 5.1.0STM32-MAT/TARGET 5.1.0Question:There is a error with CAN_IT module when running the example. As follows,The attached are the Simulink model and the. IOC configuration file for STM32CubeMX.
I have developed a wireless receiver based on the STM32L072CBT6 mcu but I have ran into a very weird problem.The receiver can be powered either from mains power or from USB (both converted down to 3V3). When I power it from USB it will always start without any issues, but if I try to run it from mains power (230vac via AC DC converter down to 3V3) it will mostly not start unless I touch a specific spot near the MCU.Now here comes the weird behaviour..... If I comment MX_USB_DEVICE_Init(); out of my main.c it will always run. I have tried debugging it but it behaves very erratically, it stops in different spots within MX_USB_DEVICE_Init();.Furthermore this is the second revision of the board, which means like 90% of the hardware was changed, and both boards had the same issue which leads me to believe its not a hardware issue.Both power sources are powering the MCU via the same LDO, the only difference is that when the device is usb powered the LDO transforms the voltage from 4.7 V to 3
Hello,I ran into a problem with a STM32F051K6T and cannot figure out where the problem is.With Cube I configure the controller with UART (TX-only 115.2kBd) and polling on ADC_IN0.The generated code for uVision compiles and loads errorfree.But even the "hello world" in section "USER CODE BEGIN 2" won't come. the controller crashes earlier and enters an endless loop with:__HAL_RCC_HSI14_ENABLE();in: SystemClock_ConfigWithout the ADC it runs.Exactly the same set-up I can run on an F103, F334, and L412 without problems.Version of Cube is 5.2.0 and uVision V5.27.1.0.Any idea?Regards, Manitux
In STM32CubeMx H7(v1.5.0) the example of ADC_DifferentialMode for NUCLEO-H743ZI is showing that we can measure difference voltage range of 6V6 in this mode and readme,txt file is also clearly telling us that we can vary the input voltage from -3V3 to +3V3 at both input VIN+ (PB.01) and VIN-(PB.00) of op-amp. But doing this the output voltage swing of op-amp will be +6V6 to -6V6 which are clearly out of range values.Can someone clarify that. Even though the datasheet tells us we cannot connect a negative voltage at analog input. Isn't this should be like thatThe ADC is configured to convert continuously ADC_CHANNEL_5 (VinP) connected to PB.01 and its correspanding VinN connected to PB.00. User can connect ADC_CHANNEL_5 pins (PB.00 ( Pin 34 in CN11 connector), PB.01 (Pin 24 in CN12 Connector)) to external power supply and vary voltage between 0 to 3V3. uwConvertedValue variable contains the 32-bit conversion result and swInputVoltage yields the signed input voltage in mV between -3V
I just migrated to CubeMX Rev 5.3.0. I'm developing a project for the Nucleo STM32F429ZI board. My target toolchain is Keil MDK-ARM V5. I'm using mostly the LL function libraries. I'm using the latest FW_F4 V1.24.1 package. Bug: As soon as regenerated the code using the latest CubeMX and recompiled, I soon discovered that my SysTick doesn't fire off at the correct frequency of 1KHz. I did a File Diff on my main.c source file to see what was modified in the startup code for the system clock init and I found that the following two lines of CubeMX-generated init code were now missing from the end of the SystemClock_Config function in my main.c: LL_Init1msTick(180000000); LL_SYSTICK_SetClkSource(LL_SYSTICK_CLKSOURCE_HCLK);I cut and pasted them back into my source code from my source backup, recompiled, and now everything works again. As this is auto-generated code, it now disappears everytime I regenerate my project code from within CubeMX.
Hello, I've been learning and using CubeMX a lot for project generation. I work with VS code and compile via make through the generated makefile and it is going pretty good.Now I have to work with the SensorTile and I really wish to use the cube configurator with it. Nevertheless I can't find the Tile among the selectable boards, is it possible to add CubeMX support for it? Thanks
With STM32G4 the use of counters to decode signals from quadrature encoders has been significantly improved. Furthermore we can use the comparators to detect the counting front and save external pins avoiding to make the signal come out from the comparator to let it enter the timer input connected to TI1 (for example).Unfortunately in the settings of STM32CubeIDE (and STM32CubeMX) when the "Encoder Mode" is selected in the timer, there is no possibility to change the source of the signals sent to "tim_ti1fp1" and "tim_ti2fp2", and two hardware pins are automatically enabled in the GPIO:In reality, using the "TIMx_TISEL" register, it is possible to select the source for the TIx signal and send the counting signal internally from the comparator (for example). All this is a beautiful thing because it avoids the external passage of the signal and the useless waste of pins.The question is: why in the "IC Selection" line is set to "Direct"and it is not possible to select also the other remap
I tried to install the en.patch_cubefw_f0.zip package from the "From Local ..." menu in the "Embedded Software Packages Manager" and I receive the message "Missing dependency for this package. - STM32Cube FW_F0 V1.10.0". Unfortunately, the "missing" package is already installed and used for my actual project.I finally install it by copying the folder STM32Cube_FW_F0_V1.10.0 and renaming it by STM32Cube_FW_F0_V1.10.1 in the repository folder used by STM32CubeMX. After that, I add the files included in the en.patch_cubefw_f0.zip in this new folder. At this point, when I open the "Embedded Software Packages Manager", the patch 1.10.1 is installed and the normal version 1.10.0 is still there for my old project that I don't want to migrate.I ask this question to know if this could be check by the development team to be fixed before realesing new patches. If you know a better place to ask this question, just let me know.
Hello,I upgraded cube on version 1.5.3 and function HAL_TIM_PeriodElapsedCallBack stopped working.I found out that program never goes trough function HAL_TIM_PeriodElapsedCallBack .I think that the problem is in initialization , because you need to enable timer interrupt: __HAL_TIM_ENABLE_IT(&htim4, TIM_IT_UPDATE); HAL_TIM_IC_Start_IT(&htim4, TIM_CHANNEL_1);Best regards, Niko
When ProjectManager.NoMain=true is set and I reopen the ioc file. The setting is changed to false again.CubeMx Version 5.2 and before.
Hi. I am using CubeMX 5.3.0 code generation for the STM32F767VITx. Because of an unrelated bug in Cube FW V.1.15.0, I am currently using Cube FW V.1.14.0 (not migrated). When a project from CubeMX 5.1.0 is loaded, FreeRTOS is automatically disabled. When clicking the box to enable FreeRTOS, an infinite loading cursor is displayed, the "Configuration" panel never shows up, and FreeRTOS is not enabled. When running CubeMX as a jar from the terminal the following two errors are displayed, the first error on the first time FreeRTOS is enabled and the second on all subsequent attempts to enable FreeRTOS.Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at com.st.microxplorer.plugins.ip.freertos.FreeRTOS.setApiInUse(FreeRTOS.java:451) at com.st.microxplorer.plugins.ip.freertos.FreeRTOS.setConfigurationState(FreeRTOS.java:726) at com.st.microxplorer.plugins.ipmanager.gui.BlockDiagram.setConfigState(BlockDiagram.java:2033) at com.st.microxplorer.plugins.ipmanager.gui.Bl
I just recently migrated to CubeMX 5.3.0 (and later to 5.4.0) and after generating my project I was surprised to find that my cmsis_os.h and portmacro.h were not found. After investigating It appears that they are removed from the GPDSC file as shown in the picture where I have dif'd the original GPDSC with the one generated by 5.3.0. Also attached is my IOC file.Update: Also the CMSIS Middlewars/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM7 directory automatically disappears when generating this file. I'm fairly certain this is a mistake.Thanks,Martin
Hello,I am starting a project using STM32CubeMX v5.3.0 and looking at using the STM32H745ZI. If I set up the following options:RCC Low Speed Clock (LSE) to "Crystal/Ceramic Resonator"RCC CRS SYNC to "CRS SYNC Source LSE"DEBUG Debug to "JTAG (5-pins)" - to match the device power on statethen I get a yellow exclamation warning on RCC and CRS SYNC is highlighted with the warning "CRS SYNC conflict with DEBUG Debug JTAG (5 pins) or/and USB Should be enabled".Can I ignore this warning? I would have thought in this configuration, with CRS SYNC being sourced from LSE that I do not need the CRS SYNC pin which is shared with JTDO and no warning should be issued. Even with CRS SYNC disabled (although I do not see how that is achieved from the reference manual) the warning is still shown.Or does STM32CubeMX just bundle up all the possible warnings, errors and remedies and display them, even if you have settings that would not cause the conflict? I can see in the CRS SYNC drop down that using the
Hi! I'm often working with STM32 MCUs and use CubeMX for project creation since it's very useful for such purposes. But what is bothers me the most is that CubeMX generate sections for usercode, where I should write.I understand that it was made for maintaining purposes, but I would like to be able to turn this generation off and just give me blank project with all necessary libraries. I would like to see more flexible code generation settings if it possible, please.I wait for such update for very long time. It would be just great to see this in next update!
Hello *,in CubeMX 5.3.0 there is no way selecting the option "Copy all used libraries in the project folder" in the project settings. In 5.2.1 projects, where the option was formerly selected, it is still selected but the option is grayed out.
Hi, I performed a clean re-install of CubeMX and am now having network connectivity problems.Machine: Win10 Home (v1809)CubeMX Version: v5.3.0Install Loc: C:\Sw\stm\STM32CubeBoot Error: Updater Settings:Update Manager:I can browse online and ping google.com fine. How can I get the internet connection restored and my CubeMX installation updated?
..
I'm using the latest STM32CubeMX Version 5.3.0 (July 2019). I'm trying to wrap my head around the general project structure. Let's take for example a NUCLEO-F767ZI project generated by CubeMX.I'll go through a few conclusions I've drawn so far.1. The Drivers/CMSIS folderThe folder Drivers/CMSIS seems to be full of Templates and Examples. They are not part of the build.Take the folder Drivers/CMSIS/Core/Include : all its files are duplicated into Drivers/CMSIS/Include. Only Drivers/CMSIS/Include is included in the build (see Makefile), folder Drivers/CMSIS/Core/Include doesn't participate. From this, I conclude that Drivers/CMSIS/Core and Drivers/CMSIS/Core_A are merely Templates/Examples. Is that correct?Let's now observe the folders Drivers/CMSIS/RTOS and Drivers/CMSIS/RTOS2. It looks like these folders contain wrapper code for realtime operating systems, to make them compatible with the CMSIS standard. From my understanding, there are two versions of that standard for realtime opera
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.