Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
So I have a scroll list with several elements and snapping set to true. The scroll list can show up to 3 elements on screen with no scrolling.I can move the scrolling list both by scrolling and clicking two buttons (up and down) that basically use the animateToItem to move the scroll list to the first or last element.Now, because I have to update an image according to the element shown on the scroll list, I need to know if the first element or the last element of the scroll list is visible.Is there a way to do that or do I need to implement it myself?
Hello,What is the simplest and best way to implement encrypted firmware update via DFU? I plan on building a custom bootloader but have not found any recent existing projects. I tried STM32-AES-Bootloader but it is setup for STM32F10 and I am using STM32F373 and am not sure about what memory settings/config I need to go with to make it work. I need it to work with CubeIDE as well ( STM32 project ) so I've started a new bootloader project to build my own instead of re-using an existing solution. ( unless there is something that will work well with STM32F373 )My uC currently detects an API 'switch to DFU' command, sets a magic value in memory and resets the hardware. I added reload function on bootup and jump to my app if the magic value is not found. This all works well but it's not encrypted. Any advice on how I should proceed?
Hello all, I am really new to TouchGFX and can't find a solution to my problem. I want to increase or decrease a displayed value on my screen by clicking on a button. I think I have to read the value each time by using getWildcard(). But now I have a data type conflict as I can't just handle it as an int and increase it. In the following you can see a picture of my screen. Thank you in advance :)
nucleo-h7s3l8 x-nucleo-67w61 I don't know how to connect them.Could you please show it in pictures?Thank you.
We try generate signal defined by toggle table , but command do nothink. (except ARR toggles) if (HAL_TIM_OC_Start_DMA(&htim2, TIM_CHANNEL_4, &tim_values[0], idx) != HAL_OK) { Error_Handler(); }have 1.7.0 U5 firmware some known issue ? Or what is required to right setup this.We try add enable GPDMA etc. No change. For ARR is one toggle no based on table. Seems we skip some trigger setup or U5 HAL is buggy .? Pls help. Simply we have table and require toggle for example 20 words table in time.Actual config:main ... /* Initialize all configured peripherals */ MX_GPDMA1_Init(); MX_CRC_Init(); MX_RAMCFG_Init(); MX_DSIHOST_DSI_Init(); MX_LTDC_Init(); MX_TIM3_Init(); MX_USART2_UART_Init(); MX_DCACHE1_Init(); MX_ICACHE_Init(); MX_DMA2D_Init(); MX_GPU2D_Init(); MX_DCACHE2_Init(); MX_TIM2_Init(); MX_TouchGFX_Init(); /* Call PreOsInit function */ static void MX_TIM2_Init(void) { /* USER CODE BEGIN TIM2_Init 0 */ /* USER CODE END TIM2_Init 0 */ TIM_ClockConfigTy
Hello everyone,Does anyone have experience with changing the function of a pin in program?(Not CubeMX tool) I'm currently using the STM32H5 MCU to develop a motor drive inverter.For rotor angle feedback, we’re considering two options: Encoder (ABZ) and Hall sensors.As shown below, when configuring TIM2 in Encoder + Index mode, it occupies PA0, PA1, and PA4. However, if TIM2 is configured in Input Capture mode (for Hall sensors), it uses PA0, PA1, and PA2 instead.We want to let the user select the desired feedback method (either Hall or Encoder), and then have the firmware initialize the corresponding pin configuration at runtime. So, my question is: how should I config the CubeMX configuration from the beginning, and how can I implement the function initialization in code to change different function?Has anyone had experience with this type of setup?"
I am using the X-NUCLEO-CCA02M2 expansion board with the Nucleo-H755ZI-Q, and I’ve confirmed that the MP34DT06J microphone is receiving the correct clock signal. Proper VDD and ground are also supplied to the mic. However, when I probe the DOUT line with an oscilloscope, there is no data output observed. Is there something I might be overlooking?
Hi ST Community,I'm encountering an issue using the following function in STM32Cube HAL v1.11.3: HAL_UARTEx_ReceiveToIdle_DMA(&CLI_PORT_HANDLER, (uint8_t*)&cliPortRxBuff, sizeof(cliPortRxBuff)); HAL_UART_RegisterRxEventCallback(&CLI_PORT_HANDLER, (pUART_RxEventCallbackTypeDef)CLI_Serial_RxIdle_Complete); In this version, I observed that the callback registration depends on huart->RxState:if (huart->RxState == HAL_UART_STATE_READY) { huart->RxEventCallback = pCallback;} However, RxState is not in the HAL_UART_STATE_READY state at the time of registration, which causes the callback not to be assigned—leading to broken UART behavior.In contrast, previous versions (e.g., v1.11.0) checked gState, which allowed this registration to work as expected.Questions:Why was RxState chosen for the condition in v1.11.3 instead of gState?What is the recommended workaround or best practice to ensure the callback can be registered successfully in this new version?Appreciat
hi all,i am developing a project using stm32u585 microcontroller which can connect to the external devices using ethernet and USB protocols.i need to put the controller in sleep or any low power mode when ever a sleep command is reached through the USB communication and its need to be wake up when any command through the USB. i am new to the controller sleep part .is it possible to implement this if so can anyone please give some reference regarding the same.and am using azure RTOS environment for the development(threadx,netx,usbx).the same needs to implement on ethernet side as well since i am using an external chip for the ethernet and its using and external interrupt for transmitting and receiving data i can use that in case of ethernet. but in case of USB i didn't got any reference to work with any low power mode of the controller. (need to use the commands send through USB for put into sleep as well as wakeup from sleep).any reference regarding it will be a great help.
Good day!I have custom board with cpu stm32l562. I am prepared all data and global license. CPU prepared by script file from package STM32CubeExpansion_SFI_v1.5.0 L5.This operation is OK.But after if start programm by Cube Programmer ( v 2.19 ) - i have error all times.I am add log with this errors...Help me, please. 12:25:13 : SFI parsing file started ...12:25:13 : SFI header information :12:25:13 : SFI protocol version : 212:25:13 : SFI total number of areas : 412:25:13 : SFI image version : 012:25:13 : SFI Areas information :12:25:13 : Parsing Area 1/4 :12:25:13 : Area type : F12:25:13 : Area size : 8056012:25:13 : Area destination address : 0x804000012:25:13 : Parsing Area 2/4 :12:25:13 : Area type : F12:25:13 : Area size : 6566412:25:13 : Area destination address : 0xC00000012:25:13 : Parsing Area 3/4 :12:25:13 : Area type : F12:25:13 : Area size : 12812:25:13 : Area destination address : 0xC03E00012:25:13 : Parsing Area 4/4 :12:25:13 : Area type : C12:25:13 : Area
Hi all,TouchGFX version: 4.16.1I have a slider that allows user to change the timer values. I have registered two callbacks (1) setNewValueCallback and (2) setStopValueCallback.When using simulator, when I simply click(no release yet) on some value on a slider that is different than the current value, I get a new value callback once. When I release the mouse button, I get another new value callback(which is expected based on the code I see in Slider.cpp), followed by stop value callback - total of three callbacks happen. This works without any issues in the simulator.On target, it works for the most part but every now and then I run into issues where when I click on a slider value, the slider jumps to zero position. I have also seen it jump to max position. I added some events in the both of those callback handlers to debug this further. When this issue is not happening, I see three debug events as expected as explained earlier in simulator case(two new value callback events and one St
Hello everyone,I have recently updated my project's TouchGFX version from 4.23.2 to 4.24.0. After the migration, I am no longer able to generate code from the TouchGFX Designer.The process fails during the "Generate Assets" step every time I click "Generate Code". I receive the following error message in the log:The error points to the rgb_compression setting. I have checked my application.config file, and the configuration is set to "no", as shown below:What I have tried so far:Manually changing the rgb_compression value in application.config to something else and then back to "no".Deleting the generated folder and trying to regenerate everything.Running "make clean" from the simulator directory.I reinstalled it in version 4.24.2.None of these steps have resolved the issue. It seems like the asset generator in version 4.24.0 is either misinterpreting this valid setting or there's a new required configuration that I'm missing after the update.Could someone please advise on what might b
In looking at AN3155, USART protocol used in the STM32 bootloader, the following diagram describes the MCU's write protect command sequence from the device side:There is a comment at the bottom which indicates that only certain F and L series chips perform the system reset. I am working with a STM32U585QI, and I also see that this chip appears to perform a system reset when executing the write protect command. Is that correct and this comment is just wrong, or am I seeing this unexpectedly?
Hi everyone!I'm trying for the first time to create a project using TouchGFX without using the Designer. My short term is objective is as simple as to see in the screen numbers generated by a function created in main.c or model.cpp.1) Is there a template of files and folders to implement touchgfx from scratch?2) What are the configurations in the .ioc in order to use the screen and touchgfx?I've already installed and activated TouchGFX in the Mx/middleware but I had several build errors due to non-existing or incomplete files.I'm using CubeIDE and the stm32h750B_dk board.Thank you in advance for all your support.Kind Regards,TJAttachements: .ioc configurations, file tree and compilation errors
Hi, Programmed sparkfun thing plus stm32f4 i2c bus in slave mode and sending the serial data to the i2c bus. The bus is hanging after some point of time. Any help will be appreciated. Thanks,
I recently acquired the STM32F469NI-Discovery board as it purported to support most of the functions that I wanted - GUI, USB OTG, SD card, etc. However, on bringing it up, it did not load and remained blank. (Customer support has not been supportive in getting the demo software loaded.) I have been able to run simple TouchGFXDesigner projects with ST332Cube. But, when I try to add simple functionality, I find that what's in he .ioc file does not agree with what's on the board (in the schematic). The best I have been able to do is determine that the promised sample code is not available.Can someone recommend a newer board that has better support? The larger the display, the better. I can work with almost any daughter board configuration (Arduino, etc.) as long as it is well documented. A primary requirement is that the source code for the examples be easily accessed.For those interested, this is to be used as a front-end controller for custom lab test equipment. The GUI is primarily to
Hi all, I am currently trying to configure the NUCLEO-F072RB to work with an EVM board from TI via SPI. I am very new at using STM32 and I am not quite sure how to go about it. 1) I have already used CubeMX to do the recommended settings. Do I also need to write the control registers in spi.c as indicated in the F072RB reference manual? For example: void configSpi_SSM(void) { //CONFIGURE SPI1_CR1 REGISTER //CLEAR BITS SPI1->CR1 &= ~((1u << 15) //FULL DUPLEX MODE |(1u << 13) //NOT INTERESTED IN CRC CLACULATIONS, DISABLE CRC |(1u << 10) //NOT INTERESTED IN SIMPLEX MODE |(1u << 7) //MSB FIRST |(7u << 3) //RESET BITS THAT DIVIDE THE FREQUENCY BEFORE SETTING THEM AGAIN ); //SET BITS SPI1->CR1 |= ((1u << 9) //SOFTWARE SLAVE MANAGEMENT |(1u << //INTERNAL SLAVE SELECT |(4u << 3) //DIVIDE SPI FREQUENCY BY 32 |(1u << 2) //MASTER MODE |(0u << 1) //CLOCK POLARITY OF 0 |(1u << 0) //CLOCK PHASE OF 1 ); //CONFIGUR
We are using the STM32L071KZU6 in one of our designs and are facing an issue with bootloader communication over I2C. Specifically, some boards fail to enter the bootloader or respond on the I2C bus, while others function normally. Below are the details of our observations:The MCU is programmed by a CX3 host over I2C.On some boards, the MCU does not respond to the I2C address with an ACK during bootloader flashing.We have monitored BOOT0, nRST, and I2C lines on both working and non-working boards, and the signal waveforms appear identical.In boards where the issue occurs, once the device successfully flashes even once (randomly), it continues to function correctly thereafter with no further flashing issues.We have tried various I2C clock frequencies, ranging from 400 kHz down to 10 kHz, with no consistent improvement.All other electrical and mechanical aspects (including pull-ups on I2C, supply stability, and reset timing) have been reviewed
I am currently working or a project with microcontrollers STM32 and this is my current situation:- I want to send from my NUCLEO f4476ZE the desired speed via UART to my other controller which is B-G431B-ESC1 discovery kit with STM32G431CB MCU.- I have this discovery kit connected to the motor (I can make it run with the CubeIDE project generated from the Motor Control Workbench that i have created with this Discovery kit and a Maxon 251601 motor). The problem that I have is that i don't know which structure of message should I send from the Nucleo to the ESC1 for the ESC1 to read and interpret it correctly to move the motor at the desired speed of the message.I was trying sending this as desired speed:char tx_buff[32]; int velocidad = 1500; while (1) { sprintf(tx_buff, "SPD%d\n", velocidad); HAL_UART_Transmit(&huart2, (uint8_t*)tx_buff, strlen(tx_buff), 1000); HAL_Delay(1000); }And for the receiver I wanted to add this: HAL_UART_Receive_IT(&huart2, &rx_buf[rx
I'd like to setup the DMA engine to use double buffer mode, but on different size buffers. It seems that there is only one NDTR register per stream, and the user manual says this can only be written to when the stream is disabled.So combining this information, is it the case that both buffer lengths must always be the same size?
Hi,I want to know how I can implement a generic SPI Display with a ST7789V driver with TouchGFX. I saw several tutorials but no of these was clear for me. I know that I must setup TouchGFX with generic display, get a Display Driver and then add some code to TouchGFX. But what does this mean in detail?Can someone please explain to me step by step how to do the implementation?BRMatthias
Hi,I'm currently trying to get Bluetooth working from Zephyr. I'm working with the Zephyr sample codezephyr\samples\bluetooth\peripheral_dis.I'm using a Nucleo-WB55RG board. Using STMCubeProgrammer I've loaded the FUS at 0x080EE000 and the file stm32wb5x_BLE_Stack_full_fw.bin at 0x080D0000. The chart in the release notes doesn't appear completely with any of the browsers I've tried so I may be using the wrong addresses, but it's the best I can do.The log from STMCubeProgrammer shows:17:25:54 : STM32CubeProgrammer API v2.19.0 | Windows-64Bits17:26:03 : UR connection mode is defined with the HWrst reset mode17:26:03 : ST-LINK SN : 066EFF56498177486722122217:26:03 : ST-LINK FW : V2J39M2717:26:03 : Board : NUCLEO-WB55RG17:26:03 : Voltage : 3.26V17:26:03 : SWD freq : 4000 KHz17:26:03 : Connect mode: Normal17:26:03 : Reset mode : Hardware reset17:26:03 : Device ID : 0x49517:26:03 : Revision ID : Rev X17:26:03 : Debug in Low Power mode enabled.17:26:03 : UPLOADING OPTION BYTES DATA ...17:26:0
Hi everyone,I'm working on an STM32f103 project using Keil MDK (uVision) and could use some advice and practical insights from those who've handled intensive flash write requirements before.My use case:I need to reliably store and retrieve a single `double` value (8 bytes) in the STM32's internal flash memory. The challenge is that I have to support at least 3 million write cycles to this value over the product's lifetime—well above the typical endurance of a single flash page (which is around 10,000 cycles per page on my device).Constraints:- No external memory: The hardware is fixed; I have to use internal flash only.- Keil MDK: Development is in Keil uVision- Memory available: I can dedicate about 30 of the 128 internal flash pages for this purpose, which should provide enough headroom for wear leveling.Requirements:- Core functions: - Write a double value to NV memory with wear leveling.- Read the last stored value at startup and on demand.- Robust wear leveling: The solution
Hi, I'm using NuttX as RTOS on my STM32 board. I have a timer set in the DTIMER register, and in the interrupt handler of the SDMMC, if it detects a timeout, the way the code handles it is that does this: 1. disable all transfer related interrupts // flags to the SDMMC mask register. 2. Set "Stop transmission" command to the CPSM command register. 3. Set to the Interrupt clear register the following: STM32_SDMMC_ICR_DATAENDC | // DATAEND flag clear bit STM32_SDMMC_ICR_DCRCFAILC | // DCRCFAIL flag clear bit STM32_SDMMC_ICR_DTIMEOUTC | // DTIMEOUT flag clear bit STM32_SDMMC_ICR_RXOVERRC | // RXOVERR flag clear bit STM32_SDMMC_ICR_TXUNDERRC | // TXUNDERR flag clear bit STM32_SDMMC_ICR_DBCKENDC // DBCKEND flag clear bit However, the problem I'm having is that the IDMA control register remains enabled, and if I try to reset it myself to 0, when I read it back it's still enabled. Before a new I/O is attempted on the sd card, the following registers are (re)set: 1. Set IDMA control regis
Hello,I'm kind of newbie in the STM32 world, I'm more used with another brand of 32bits microcontroller that also have a "parrallel port" for interfacing external ram device.My concern is about the FMC on the STM32H7.I want to read/write a 16bits device.Currently I'm using this configuration (almost the default one) :My code for testing a write operation :.... I can't see any problem in the code but when I check signals with an oscilloscope, I can see that the CPU is issuing 4 consecutive write operation : A0 / A1 are also increasing as if the CPU is writing to 4 different places.How can it be possible.I have seen in the datasheet that when AXI bus and external bus is different size, it can occurs. But in that case how to perform a correct 16 bit operation ??Other people seems to have this kind of trouble but nobody replied with a solution :https://community.st.com/t5/stm32-mcus-products/h7-series-fmc-question/td-p/131535https://community.st.com/t5/stm32-mcus-embedded-softwar
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.