Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
Hello!Using h563zi I am trying to update the second bank firmware using an application that has a Secure Part (sectors 0-9) and a Non Secure part with Trust Zone enabled. For easier maintenance the update is done from the Non-Secure part.Settings:SECWM1_STRT = 0x0SECWM1_END = 0x9SECWM2_STRT = 0x0SECWM2_END = 0x9What we do:1) Disable the secure watermark from the second bank (can also be done in STM32CubeProgrammer)ob_program.OptionType = OPTIONBYTE_WMSEC; ob_program.Banks = FLASH_BANK2; // Using 1 for start and 0 for end practically unlocks ob_program.WMSecStartSector = 0x1; ob_program.WMSecEndSector = 0x0; HAL_FLASHEx_OBProgram(&ob_program) HAL_FLASH_OB_Launch(); HAL_NVIC_SystemReset();2) Write the sectors from bank 2 from 0x0 to 0x9 from the Non-Secure application (since the watermark protection is off)3) Do a checksum on the written data (read back from sectors 0x0 to 0x9) and check it4) Check in STM32CubeProgrammer the data manually 5) Enable the secure watermark for th
Hi,while I'm configuring the FMC interface i come cross this memory map and i couldn't understand it. Does the FMC SDRAM Bank 1 have 4 possible regions? if yes, does SDRAM Bank 2 have the same option.what about the External Memory region, are those for SRAMs and External Device for SDRAM?those kinds of questions come to my mind, if someone could help me with.most important question, I want to use SDRAM bank 1 (SDCKE 0 will be enabled) and SRAM1 (NE1 will be enabled), is this possible?i believe i have read this somewhere that it could be done, but not sure, also, is there some sort of limitation of both can be enabled together or i should use SDRAM bank 2 and one of the SRam banks and that will be more reliable and efficient?Thank you and best regards
Subject: STM32F746G‑DISCO | SDMMC + DMA + D‑Cache – hangs at state 5, FR_DISK_ERR / empty files → root‑cause & minimal fixesCube / HAL versionsCubeF7: v1.28.0CubeMX: 6.11Board: STM32F746G‑DISCOMiddleware: FatFs R0.14, _USE_LFN = 3, _MAX_SS = 512Cache: I‑ & D‑cache enabled (default)1 – Read path: card never leaves RECEIVING (0x5)SymptomHAL_SD_GetCardState() polled after HAL_SD_ReadBlocks_DMA() stays at 0x05 → loop never exits.Root causeSD_DMAReceiveCplt() does not re‑enable the DATAEND interrupt, so the SDMMC ISR never runs and HAL state is never cleared.Fix (HAL driver)File: stm32f7xx_hal_sd.c/* inside SD_DMAReceiveCplt() */ __HAL_SD_ENABLE_IT(hsd, SDMMC_IT_DATAEND); /* <- add this line */After this patch the DATAEND IRQ fires, HAL_SD_IRQHandler() sends CMD12, sets hsd->State = READY, and the read loop exits.2 – Write path: f_sync() returns FR_DISK_ERR / file size stays 02.1 Cache coherencyBefore starting a DMA write, the sector buffer FatFs passes to disk_
I have created a custom inverter board using STMC Board Designer. And there is no error reported by Board Designer. However when I use the inverter board to creat a workbench project, it tells me "Current Sensing" item has some errors without details. So I have no idea about what is the exact error and how to solve it.The h723.7z is my inverter board config.And I hope the WorkBench can show more and clearer information of the error or warning in the future version.
I am confused about which clock(s) drive the timers. In the reference manual is says the APB clock drives the timers but there are 5 APB clocks. Also, in STM32CubeMX there is a "Timer Group Clocks". What clocks drive which timers or is the one drives all (Timer Group Clocks)?
I'm trying to develop an application for zigbee for the stm32wb55, but i get some problems when I try to reconnect.The configuration for the coordinator its the next parameters: - config.startupControl = ZbStartTypeForm; - config.extendedPanId = 0x400; - config.panId = 0x7171; - config.shortAddress = 0x0000; - config.networkManagerAddress = 0x7171;The configuration for the End devices are the next parameters: config.startupControl = ZbStartTypeRejoin; config.panId = 0x7171; config.networkManagerAddress = 0x7171; config.shortAddress = 0x01; config.extendedPanId = 0x400;The first time it performs the connection well. But, when the End Device lose the connection (reboot, or whatever it takes), it cannot recconect to the coo
I have questions on the System Memory Boot Mode of the STM32G070CB MCUSetup:Access the System Memory Bootloader Mode every power cycle. Hence, I updated the Option Bytes as below:The MCU contains the Application image only; it does not contain a custom bootloader.Using Cube Programmer, configure the nBoot0 option bytes, able to run as System Memory Boot Mode OR Main ApplicationWhat I tried to do was exit the System Memory Boot Mode and Access the Main Application, but failed:Tried using the UART sending the GO Command with the Application Address 0x0800 0000, but the MCU does not work (no UART Log) Tried using the UART method to send the GO Command with the Application Address stored in the Image like below, the MCU does not work. Tried to uncomment the “USER_VECT_TAB_ADDRESS” in system_stm32g0xx.c.The MCU outputs some unexpected UART log if sending the GO Command with the Application Address 0x0800 0000 &
I am trying to detect both rising and falling edges on a GPIO input using EXTI.I am using a STM32H755 (144 pin) - SYSCLK is 400MHz, but I am using the CM4 core, so the CPU clock is 200MHz. APB Timer clock is also 200MHz.The signal I am monitoring is coupled through an opto-isolator, and having scoped it, seems to have a rise-time of approx. 5us. I am wondering if this is too slow for EXTI rising / falling edge detection?I've been looking at both the datasheet and reference guide for the STM32H755 and I could not find any data on max and min rise times for edge detection to function reliably.
Hello guys,I'm new in LoRaWAN so if my question is dumb - sorry guys. Context:Initial info:custom board with STM32WLE5CCUX family MCU on it;LoRa gateway from P-NUCLEO-LRWAN3 pack;private network gateway;activation type OTAA;What is done:gateway from P-NUCLEO-LRWAN3 has been configured on TTN;End Node is configured on TTN (no problem with traffic monitoring: uplinks/downlinks);I'm having some problems with Join requests to private network gateway. When I'm connecting through gateway from P-NUCLEO-LRWAN3 pack which is in the same room as end node everything works perfectly. But when I'm trying to connect to private network gateway something goes wrong (I have configured different DevEUI for local/private gateways and when I want to switch between them I just change DevEUI). Sometimes End Node is connected after 20 minutes, sometimes after 1h the end node is still not connected to the private network gateway.I know that network coverage is very bad, but other devices someho
How to unbrick a C0 if user firmware reprograms SWD pins as IO? Because by default BOOT0 pin is disabled so there's no way to enter the bootloader unless it's enabled in OPTIONS bytes. I've added a failsafe 2 second delay at bootup before running any GPIO config, but I'm curious if there's any other way to unbrick. Or if RDP1 is enabled, how to change it back to RDP0 if you can't get in via SWD or into bootloader because BOOT0 isn't enabled? Or am I missing something?BOOT0 pin by default is disabled in OPTION bytes, but you can't enable it, or erase the firmware/flash if SWD is not working...I'm using STM32C071 but I assume it's all C0 if they don't have the BOOT0 pin enabled by default.
Whether the two buses can be used at the same time? Winbond's SDRAM is used to find a high probability of reading and writing errors in SDRAM data。 but there is no problem with using ISSI. If you don't read or write to the external SRAM, it's fine。
I am currently using the v1.6.1 of STM32CubeIDE and a STM32G473 MCU.I have implemented an I2C bus and have noticed a major bug with the I2C_WaitOnFlagUntilTimeout functions. There is this condition:if (((HAL_GetTick() - Tickstart) > Timeout) || (Timeout == 0U)) which is supposed to guarantee that the program doesn't get stuck into the while loop above (while (__HAL_I2C_GET_FLAG(hi2c, Flag) == Status)), but the tick value stop incrementing as soon as the program enters the function for a reason I don't understand. I have tried to increase the preempt priority of System tick timer (by lowering the value) but it didn't change a thing.Does anyone know how to fix that?
In the STM32WL55 reference manual (RM0453 Rev 1) section 5.8.5 states "Get_Status(status) can be issued at any time"However, there seem to be many situations where this command will result in a reserved value for the "CmdStatus" field.A minimal reproduction of this can be done by setting the radio into standby (RC 13MHz), followed by a Get_Status command. In this scenario Get_Status deterministically returns 0xA2, which corresponds to a bit value of 1 for the CmdStatus field, which is reserved per the reference manual.Another example is after transmitting data with Set_Tx; the status will show 0xE2 (Mode = TX, CmdStatus = 1) before the transmission has completed, and 0xAC (Mode = StandbyRC, CmdStatus = Complete) after the transmission has completed.1) What does a value of 1 in the CmdStatus field of the Get_Status() command correspond to?2) Are there any conditions when the result of Get_Status() is invalid?
I'm currently testing the BLE_LLD examples provided by st. I have two Nucleo Boards one running BLE_LLD_Lowpower and one running the BLE_LLD_Pressbutton example. That example works fine and I can change whatever is transmitted.If I use the same BLE_LLD_Lowpower example on one of my own PCBs with a STM32WB5MMG6 module I can only make the example work if I provide 3.3V. If I change the supply voltage to anything else than 3.3V it only transmits one package. But as soon as it enters the LL_PWR_MODE_STOP2 low power mode and wakes up from it, it seems to be stuck at some point. If I debug said example at 1.8V it keeps on running. (I think it won't go into sleep mode).If I run both examples unchanged and run the Lowpower example at 1.8V I get the same results.Is there an explanation for said behaviour? Any help appreciated
I have compared my platforms using PDM microphones related to PDM to PCM and filtering:Platform 1:STM32H747 (Portenta H7), with SW PDM2PCM filter (and optional to add post-processing)Platform 2:STM32U5A5 with ADF filter (in MCU) or external PCMD3180 chip.My favorites:STM32U5A5 with ADF: but unfortunately just mono MICPCMD3180: still room for improvements, e.g. using "channel summing" for +6dB SNR or tweaking the filtercoefficientsIn general: all filters are pretty similar. The major differences are on:the DC offset they have left (STM32U5A ADF needs for sure a HP filter)the harmonics created (distortion): just with a post-filter (e.g. on PDM2PCM) I could improvethe noise in high frequency spectrum (above 10KHz): STM32U5A5 ADF is the winner hereHere the result comparison (should be an animated GIF to see the differences):So, my conclusion: if I need a PDM MIC - use the STM32U5A5 ADF (if just one MIC needed), otherwise use external chip (PCMD3180).
Hi @Romain DIELEMAN, @Osman SOYKURT, @LouisB We are using TouchGFX library, now for almost 5 years. We are very satisfied with the product and its's regular updates/improvments and new featuers. However we have one limitation: the current library does not officially support the Clang compiler. We are using SEGGER compiler - Clang for our projects so I needed to do some workarounds for current gcc library to got it working with it. Would it be possible to add support for Clang compiler in future releases? This way it would also be directly compatible with the SEGGER compiler and no other workarounds would be required. I am looking forward to your positive response and the continued evolution of the TouchGFX library.
Hi everyone,I’m working on a project involving the STM32F030R8 microcontroller, and I came across this custom board design: https://www.pcbway.com/project/shareproject/ARMando__STM32F030R8_board_.html Has anyone here used this specific board before, or can anyone provide insights on how to effectively get started with it in the STMduino environment? I'm especially interested in:Setting up the toolchain for STM32F030R8 with STMduinoTroubleshooting any common issues that might arise during developmentSuggestions for libraries or peripheral setups that would be helpful for this microcontrollerAny advice or shared experiences would be greatly appreciated!Thanks in advance!
I bought few STM32C071G8U6N from Mouser few month ago.As I know, the SRAM size in spec is 24K, but I will get error message as below when ZI-data over 8KB"Error: L6406E: No space in execution regions with .ANY selector matching xxx.o(.bss)."Program Size: Code=33736 RO-data=360 RW-data=132 ZI-data=6724 And the data in iirDataQueue will change into 8192 or around 65535 unexpected.. Following is my code(work fine on other platform), (iirData is no error). memmove((uint16_t*)&dspMem.iirDataQueue[0], uint16_t*)&dspMem.iirDataQueue[1], (ADC_DATA_QUEUE_LEN - 1) * sizeof(dspMem.iirDataQueue[0])); dspMem.iirDataQueue[ADC_DATA_QUEUE_LEN - 1] = dspMem.iirData; We have also been using other series of products for a long time, such as STM32L4, but none of them is as frustrating as STM32C071. Could you please provide me with some direction to debug? Thanks.Environment:CubeMx 6.15.0 + STM32C0 1.4.0Keil MDK-ARM 5.29.0.0STM32C0xx_DFP 2.2.0
Hello, I have a project to measure the frequency (10Mhz) on an PA5 input and PWM output on PA6, with the counting triggered on PA0 (1PPS), CPU STM32F411, my problem is that the value TIM2 is always wrong, I must have around 10Mhz, I think that the configuration of my Timer 2 is not good but I don't see where the problem is.File attached.Best regards.Sébastien..
Hello,I'm working on an STM32 project using FreeRTOS with the CMSIS-RTOS v2 wrapper, and I’d like to integrate SEGGER System View to monitor and analyze my tasks. However, most of the tutorials and blog posts I’ve found only cover integration with native FreeRTOS, not with CMSIS-RTOS v2.Could anyone guide me on how to properly set up SEGGER System View with CMSIS v2? Any sample code, steps, or documentation references would be greatly appreciated.Thank you!
Hello All,I have used STM32757IEval board for my initial GUI application development. Which is working fine on Eval board with Touchgfx and stm32IDE.Now we have to use other 10"1 inch Display to be to run the Developed Application.The main change what we see is the Eval board STM32757I Eval uses DSI for Display and Touch sense.The 10".1 display used LTDC Parallel (RGB 888), we are trying to create one sample project using STM32CUBE IDE but there are compiling errors, the path and files are set but still no progress. If I try to open the .touchgfx file using Touchgfx Tool I am able to run the same project on simulator. Now I guess there should be some Proper way to do it, as the errors never goes off.I doubt the folder structure, or some required files are missing. You might know well.It would be helpful if you could let me know what should I try to make it run successfully. Regards,Shiv
Hi, I wonder if someone could help me with my setup.@Tesla DeLorean @Amel NASRI @Andrew Neil I am currently trying to use touchGFX to design my GUI in a custom board. Before trying to use touchGFX, I set up the LTDC and FMC to use an external SDRAM to hold the buffer and it works fine (I can draw on the screen). However, I've been struggling to setup the touchGFX and being able to only get some random pixels. I noticed from the templates that an external flash is being used to hold initial assets generated at touchGFX, but my board does not have an external flash right now.Is it possible to run touchGFX from internal flash, and use only external sdram for the framebuffer?I'll share the configurations I have so far:And here is my ld file:/* ****************************************************************************** ** ** @file : LinkerScript.ld ** ** @author : Auto-generated by STM32CubeIDE ** ** @brief : Linker script for STM32F469IITx Device from STM32F4 series
Hello,I'm slowly losing my sanity so I figure I'd make a post here. I set up SAI4 to interface with BDMA, hoping to retrieve data from the onboard MEMS microphone and store it in a buffer in RAM_D3. Ideally I'd like for that data to be processed by the CPU, but I can't even get the buffer to fill up.The following code produces the output below:audio_buffer[0] = 5; audio_buffer[1] = 6; audio_buffer[2] = 7; audio_buffer[3] = 8; // ... // Inside main loop: printf("SAI State: %d \r\n", HAL_SAI_GetState(&hsai_BlockA4)); printf("SAI Error: %lu \r\n", HAL_SAI_GetError(&hsai_BlockA4)); printf("SAI Buffer Address: 0x%08lx\r\n", SAI4_Block_A->DR); printf("DMA State: %d \r\n", HAL_DMA_GetState(&hdma_sai4_a)); printf("DMA Error: %lu \r\n", HAL_DMA_GetError(&hdma_sai4_a)); printf("Pointer location: %p \r\n", audio_buffer); printf("Audio Buffer Data:\r\n"); for (int i = 0; i < 10; i++) { printf("[%d]: %d\r\n", i, audio_buffer[i]); } As you can see, SAI4 is in HAL_SAI_ST
Hello All, @TDK, @STTwo-32, @Peter BENSCH I am using STM32F407G-DISC1 with SN65HVD230 CAN Board Network Transceiver Evaluation Development Module connected to PCAN.Connections are as followsSTM32F EVK pin PD0(CAN1_RX) to Rx of SN65HVD230 STM32F EVK pin PD1(CAN1_TX) to Tx of SN65HVD230 3V and GND is connected as well.SN65HVD230 CANH to Pin 7 (DB9 of PCAN)SN65HVD230 CANL to Pin 2 (DB9 of PCAN)Common GND connected as well (Pin 3 DB9 of PCAN) to EVK GND.I have a script to transmit and receive message from the EVK, speed is set to 1 Mbps, i am able to transmit data from EVK to PCAN and the same is displayed in PCAN View. But the problem i am facing is i am not able to receive any data sent by PCAN to EVK.I am trying to send a Standard CAN message, no Extended frame, no RTR, just 0x7FF(ID), DLC - 8, Data 01 02 03 04 05 06 07 08 cycle time is 50mS. And the same filters are set for Rx Mailbox in my script.Please let me know any suggestions or if i am mis
Every time I debug my project for STM32H747 (created with TouchGFX), the debugger opens a bunch of random files, different each time.It does that BEFORE even finishing uploading the project to the board. Before I even get "Verifying" on the console.Then it stops at MPU_Config() in main.c.It doesn't do that in projects created with STM32CubeIDE, just with a TouchGFX project.It's super annoying, is there any way to stop that beavior?
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.