Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
Hello,I am designing a board with an STM32H755ZIT6 and want to verify whether my power architecture is safe.Power architecture:Battery inputTwo buck converters:3.3 V buck → MCU VDD5 V buck → LDO + voltage reference → VDDA and VREF+Operating case:For a certain battery voltage range:3.3 V buck is enabled5 V buck is disabledResult:VDD = 3.3 VVDDA and VREF+ = 0 VRelevant datasheet sections:Power supply management (3.5):When VDD > 1 V, all power supplies are independent (except VDDSMPS).Absolute maximum ratings (6.2):“All main power (VDD, VDDA, VDD33USB, VDDSMPS, VBAT) pins must always be connected to the external power supply, in the permitted range.”All conditions appear to be met, but I want to make sure I’m not missing anything, especially since I remember other STM32 families where powering VDD without VDDA is problematic.Question:Is it safe and within spec on the STM32H755 to have VDD powered while VDDA/VREF+ are unpowered, assuming no analog peripherals are used?I would like to co
Hello everyone!That works:int main(void) { ... init_SPI1(); for(;;) SPI1_Send(); }And that doesn't:void TIM2_IRQHandler(void) { SPI1_Send(); TIM2->SR &= ~TIM_SR_UIF; // reset UIF bit in the status register of the timer }Why?Thank you very much!
Hello!I'm working on a project to use some bar-displays 284x76 pixels using ST7789 driver and I'm struggling for about 2 weeks to solve this issue. Everything is perfect using SPI DMA HAL_SPI_Transmit_DMA() if the buffer is in RAM.But if I define a struct like this in file image.h:typedef const struct { const uint32_t width; const uint32_t height; const uint32_t bytes_per_pixel; const uint16_t pixel_data[]; // Array flexibil (C99) } ImageRGB565_16bit; Then in FCU.h I have:#include "images.h" extern ImageRGB565_16bit FCU01; extern ImageRGB565_16bit FCU02; extern ImageRGB565_16bit FCU03; extern ImageRGB565_16bit FCU04; extern ImageRGB565_16bit FCU05; And loading images like this FCU.c:ImageRGB565_16bit FCU01 = { 284, 76, 2, { 0x0000, 0x0000, 0x0000, .. } };When I run the code I'm getting this result on Serial port:FCU Background with alpha 0.2 FCU = 0x80313a4 FCU.pixel_data = 0x80313b0Which looks like the struct resides in FLASH memory.But the HAL_SPI_
Im an engineering student and wanted to dive into PCB designs, so I started off with a PCB design for a vibration monitor system that i first built on arduino. This is my first ever PCB design which I made using reference/data sheets and whatever resources I could find online. Before I started routing I was wondering if could get some feedback on my current design especially for the power supply and decoupling placement, crystal and NRST implementation and general PCB placement issues before routing. Any advice is much appreciated. I am usingSTM32F103C8T for my MCUMPU6050 for the sensor.Screenshots of the Schematic, PCB and pinout are below.
HelloIs there a book about Cortex M7 like Yiu J. The Definitive Guide to ARM Cortex M3 and Cortex M4 Processors ?
Hello I'm trying read sector numer 0 from SD card. I use 4-bit mode for sd card reading. My MCU is on Nucleo development board. Card is correctly initialized but when I'm trying read sector I get zeros in buffer and maybe 10 random not-zero bytes. What do I incorrect?After restart I get the same values when I use the same sd-card. But when I use other card - I get other incorrect data.
Hello, I'm trying read core temperature. I use NUCLEO-U575ZI-Q board. I wrote code: RCC->AHB3ENR |= RCC_AHB3ENR_PWREN; PWR->SVMCR |= PWR_SVMCR_ASV; RCC->AHB2ENR1 |= RCC_AHB2ENR1_ADC12EN; ADC12_COMMON->CCR |= ADC_CCR_VSENSEEN; ADC1->CR &= ~ADC_CR_DEEPPWD; ADC1->CR |= ADC_CR_ADVREGEN; while(!(ADC1->ISR & ADC_ISR_LDORDY)); ADC1->CR |= ADC_CR_ADCAL; while (ADC1->CR & ADC_CR_ADCAL); ADC1->CR |= ADC_CR_ADEN; while (!(ADC1->ISR & ADC_ISR_ADRDY)); ADC1->DIFSEL = 0; ADC1->PCSEL = ADC_PCSEL_PCSEL_19; // preselection ADC1->SQR1 = (19 << ADC_SQR1_SQ1_Pos); ADC1->SMPR2 |= (7 << ADC_SMPR2_SMP19_Pos); // max sample time ADC1->CR |= ADC_CR_ADSTART; while (!(ADC1->ISR & ADC_ISR_EOC)); uint16_t raw = ADC1->DR; volatile float temperature_c = ( (float)(raw - TS_CAL1) * (130.0f - 30.0f) ) / (float)(TS_CAL2 - TS_CAL1) + 30.0f;Unfortunately it doesn't work correctly. ADC1->DR returns
I am using an STM32L433 with a W25Q128JVSIQ flash.I can read and write data but the W25Q does not seem to respond to the power down command.When I send the power down command 0xB9, reading data from the W25Q should not be possible until the release command 0xAB is sent. However, I am not sending this release command but can read data from the W25Q, which indicates it did not enter power down. Below is a scope capture of the power down command and it looks correct...I am using the following driver for the W25Q...https://github.com/mengguang/w25qxxBelow is the function I wrote to power down the W25Q... #define W25QXX_POWERDOWN 0xB9 void w25qxx_powerDown(W25QXX_HandleTypeDef *w25qxx) { uint8_t tx[1] = {W25QXX_POWERDOWN}; cs_on(w25qxx); w25qxx_transmit(w25qxx, tx, 1); cs_off(w25qxx); }I even tried adding a delay (1ms) before the CS pin is raised high after the 0xB9 command has been sent, but it still did not enter power down.With a previous setup I had many
IAR version: 9.70.2Board: MB1930-N6570-C02Project: STM32Cube_FW_N6_V1.2.0\Projects\STM32N6570-DK\Templates\TemplateBoard is in DEV mode, LED2 is on after reset.Hi, I'm unable to debug the template project, once debug session is launched the core just stucks in the bootrom:Also there are some error in the log:Sat Jan 31, 2026 12:25:55: IAR Embedded Workbench 9.70.2 (C:\iar\ewarm-9.70.2\arm\bin\armproc.dll) Sat Jan 31, 2026 12:25:55: Loaded macro file: C:\iar\ewarm-9.70.2\arm/config/debugger/ST/STM32N6xx_DBG.dmac Sat Jan 31, 2026 12:25:55: Loaded macro file: C:\iar\ewarm-9.70.2\arm/config/debugger/ST/STM32N6xx_Trace.dmac Sat Jan 31, 2026 12:25:55: Loaded macro file: E:\mcu\STM32Cube\STM32Cube_FW_N6_V1.2.0\Projects\STM32N6570-DK\Templates\Template\EWARM\FSBL\setup.mac Sat Jan 31, 2026 12:25:55: PC-locked license - IAR Embedded Workbench for ARM Sat Jan 31, 2026 12:25:57: Connected to ST-LINK/V3 [SWD mode 1000 kHz] [Access port: 1] Firmware V3.J17.M10 (Probe no: 002900304142
Dear Sir/Madam,We used the STM32F429ZIT6 processor in a project we carried out for the railway sector, and as stated in the link below, we currently need a SIL certificate to be able to submit it to the auditing firm.Link: https://www.st.com/resource/en/product_presentation/stm32_stm8_functional-safety-packages.pdf
Hi all, Im currently designing my own pcb with a STM32WBA65CIU6 MCU in the UFQFPN48 package.Im doing this for the first time (still gaining all the knowledg needed) and currently ran into the following problem:I'm having trouble understanding the footprint and EDA symbol given for the STM32WBA65CIU6 on the product site and shop. According to those, eg OSC32 are Pins 16 and 17:But according to the data sheet and also in CubeMX the OSC32 should be pin 19 & 20: Is this not a problem and can be solderd anyway? Also some other pin names are also missmatched :\Thanks for the help :)
After obtaining the motor configuration parameters using the P-NUCLEO-IHM03, I applied the same motor parameter values to the EVSPIN32G4-DUAL board, which is used to drive two motors.However, when operating the motors with these settings on the EVSPIN32G4-DUAL, an overcurrent error occurs.Could you please explain the possible reasons for this overcurrent condition?In particular, I would like to know whether differences in the power stage, current sensing topology, or dual-motor operation could cause this issue, even when the same motor parameters are used.Thank you for your support.Best regards,Pelino
Hi,I'm developing a secure boot application for STM32H563ZI microcontroller. I started with a very simple application following ST template code and tutorials like this one: https://wiki.st.com/stm32mcu/wiki/Security:How_to_start_with_STM32CubeMX_OEMiRoT_Boot_path_on_STM32H563 Everything runs as expected when I try to run my application using the NUCLEO-H5 board. However, this is not true when I do the same provisioning process in my H5 custom board. The only difference I can see between the two tests is that in the custom board I'm using the STLink-V2 programmer, while the Nucleo is programmed by the embedded STLINK-V3EC.Here are some additional points:1) in both cases the provisioning script reaches the end, saying "The board is correctly configured".2) in the custom board, I see the flash full of zeros after provisioning; I checked it with stm32CubeProgrammer3) I have no problems in flashing firmware through stm32CubeProgrammer or stm32CubeIde in my custom board
I'd like to use the DTCM ram in my code; how can I do ? Thank you
Hello everyone, I am using a custom board with STM32H750 and I am trying to develop a file system with FILEX. The file system' s media is a uSD card with 10 MB/s baudrate which is communicating with the micro thanks to the SDMMC peripheral. The SDMMC peripheral's configuration is copied from one of the many examples that are available in STMCubeMX ( it has a 50 Mhz clock, 4 bit mode, no power mode save and no transceiver).The uSDcard has been formatted through the api given by FILEX (fx_media_format) following the information available during uSD card initialization ( for example sector size is 512 bytes, number of sectors and so on...).I am using the drivers given by ST for FILEX (in my case SD with IDMA) and I am trying different media size buffer (512, 1024 and 4096) which I allocate in AXI SRAM ( SDMMC1 IDMA can access only in AXI SRAM).I am experiencing two different behaviour: If I am doing a reading operation the SDMMC is very fast while writing operation is
I’m working with an STM32G473QETx.Does the IWDG window value cause the MCU to reset if the watchdog is refreshed too often (i.e., refreshed too early)?if I set the IWDG window value to something smaller (e.g., 1600), will the MCU reset if I refresh the watchdog more frequently than expected?Any clarification on how the IWDG window works on the STM32G4 series would be appreciated.
I work on an STM32F407G-DISC1 pedometer project, in which the program is supposed to use built-in lis3dsh accelerometer via SPI to detect and count steps and display the number of steps on the screen (ILI9341 SPI).I have tested my screen code, and it works properly, so problem lies in how I use accelerometer or detect steps.To detect steps, I read lis3dsh registers with 100HZ frequency by making a call to SPI from a 100HZ timer interrupt. These snippets are interrupt and timer configuration respectively.void HAL_TIM_PeriodElapsedCallback(TIM_HandleTypeDef* htim) { if (htim->Instance == TIM2) { if ((draw_ready == 1) && (accelerometer_ready == 1)) { accelerometer_read_all_axes_dma(xyz_data, &hspi1); } } //else if (htim->Instance == TIM3) { // if (draw_ready == 1) { //steps_count += 1; //update_lcd_flag = 1; // } //} }static void MX_TIM2_Init(void) { /* USER CODE BEGIN TIM2_Init 0 */ /* USER CODE END TIM2_Init 0 */ TIM_ClockConfigTyp
When using USB CDC to communicate via USART, and interacting with USART data, in code is it recommended to interact with it at the USB side, or to interact with it at the USART side?From what I can tell, both offer both polling and interrupt methods. The USART offers DMA access, but apart from that it's not clear what, if any, tradeoffs there are between USB CDC and USART.
Github link to code Hi everyone, I am currently working on a project with the NUCLEO-L432KC board, trying to interface a generic SPI MicroSD Card module (the standard blue one, powered via 5V). I am stuck with the FatFS error FR_NOT_READY (Error 3) during f_mount. After extensive troubleshooting, I suspect a hardware failure on the MISO pin (PA6), but I would like a sanity check on my diagnosis before I remap the pins. Hardware Setup: Board: NUCLEO-L432KC (STM32L432) SD Module: Generic SPI adapter (Powered via 5V VIN pin) Wiring: CS: PB6 (D5) SCK: PA1 (A1) MOSI: PA7 (A6) MISO: PA6 (A5) <-- The problematic pin Software Configuration: IDE: STM32CubeIDE FatFS: _MAX_SS and _MIN_SS set to 512. SPI1: Master, Prescaler 256 (Low speed for init), CPOL Low, CPHA 1 Edge. The Issue & Diagnostics: The communication fails at the very beginning. When sending CMD0 to wake up the card, the SPI RX buffer always returns 0x00 instead of 0xFF (Idle) or 0x01 (Su
I've downloaded archive "en.STM32CubeExpansion_Crypto_v4.0.1.zip", now I'm trying to install it in STM32CubeMX with "From Local..." feature, but I'm getting error. How can I install the library in CubeMX?Thank you.
Hi Team, We are using the STM32WB55CGU6 for one of our application. Since, the product has internal bluetooth functionality, we are usin for our application. However, the expected range is not meeting with the application that we anticipated. Kindly review the attached circuit and provided your insights. Regards, Abinaya.M
Would writing to the crossbar registers (SETx1R, RSTx1R, SETx2R, RSTx2R of all 6 timers) on every PWM cycle (max 200kHz) affect long term reliability? I'm running this in an interrupt routine for a power converter and I'm wondering if doing this would make sense to have a more consistent processor delay. Preload is enabled on all 6 timers and master timer. Register updates on timers 1-6 occur on master timer register update.
Hello,in our application, running on a H533RET6 and with no TZ enabled, we need to close debug ports in production.I preliminarly did some tests using CubeProgrammer: I generated password-based credentials (obk+bin files, which as far as I understand from AN6008 is the only option when not in TZ) and successfully managed to lock the device by moving from PRODUCT_STATE Open (0xED) to Provisioning (0x17), supplying the .obk file and then lock the device (PRODUCT_STATE = 0x72). After verifying that debug ports were closed, I unlocked the device by making a discovery and providing the bin file, with the device returning into Open state. Note that the first 3 32-bit words of my obk file are:0x00, 0x01, 0xfd, 0x0f, 0x60, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00Showing that the address base is the secure OBK base address and that the encryption is on (as it should be in my device, again as far as I understand).So far so good, but know I would like to move at least the encryption process
My ST32N6 Discovery apparently works very well, however, when I enter the AI demo, the camera screen goes black, and two red LEDs light up on the RGB LEDs next to the connector.If I remove the camera, the DEMO alerts that there is no camera.There is no LED on the camera module to indicate its status.Are there any tests I can do to check if the camera is damaged?Unfortunately, I can no longer return it, as it has been more than 60 days since I received it and only today was I able to take the time to do a more in-depth study of the camera.
I'm trying to enable USART transmission (TX only for now) via DMA, but when I call HAL_UART_Transmit_DMA, the transfer doesn't seem to start at all and HAL_UART_TxCpltCallback is never called.I've configured everything through CubeMX: enabled USART with DMA, enabled FreeRTOS, and enabled interrupts. Without DMA, transmission works fine using HAL_UART_Transmit, but when I switch to HAL_UART_Transmit_DMA, nothing happens.I can't figure out what the problem might be. Does anyone have any suggestions?Here's my main code:/* USER CODE BEGIN Header */ /** ****************************************************************************** * @file : main.c * @brief : Main program body ****************************************************************************** * @attention * * Copyright (c) 2026 STMicroelectronics. * All rights reserved. * * This software is licensed under terms that can be found in the LICENSE file * in the root directory of this software component. * If no LICENSE fi
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.