Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
Hello,How do I enable 8MB external SPI Flash on the WBA65+RVA15MD using TouchGFX Designer?Thanks.
I am using the STM32G474 in STM32CubeIDE with the built-in CubeMx environment. MX_DAC1_Init() to setup the DAC1_Ch1. Internal VREF+ is 2.9V. When it is buffered DAC, I get output very close to 2.9V at max(4095). However if i switch to unbuffered mode, the output is only 1.4+V(about half of 2.9V) at max setting of 4095. There was no mention in the reference manual RM0440 about the change in gain for buffered or unbuffered DAC. Is this normal?
Can somebody tell me whether I am, or not, powering this STM32H725RG in the right way?As far as I know, after reading several times the specs, the 68 pin package doesn't have LDO (SMPS only).I've built my first board this way and the MCU got burnt. Thanks.
Hi everyone,We’ve been using the XCUBE-SBSFU bootloader in our industrial-grade project and recently noticed that SBSFU is now labeled as a legacy bootloader. It seems the new recommended bootloader is based on MCUBoot. Additionally, I’ve come across information on STiRoT, which implements a root of trust similar to what SBSFU legacy already offers.This has left us with a few questions, and we’d greatly appreciate any clarification:Why has SBSFU been marked as legacy and replaced? Were there specific limitations or issues with SBSFU that led to this change?How do we transition to MCUBoot? The MCUBoot website mentions it doesn’t currently support STM32 controllers, and the ST wiki says support is “coming soon.”What role does STiRoT play? It seems similar to SBSFU legacy but is relatively new. Is it a better option? Should we consider switching to it, and if so, why?Any insights or guidance would be greatly appreciated.Thanks.@Jocelyn RICARD I’ve noticed your valuable input on SBSFU
Hi Everyone,I'm following the: How to enable RDP-like product state flash protection in STM32H5 microcontrollersexample using an STM32H573xx devkit and an ST‑Link. I ended up bricking my devkit while attempting the regression step. My ST provisioning integrity status:0xf5f5f5f5I have another dev kit available for testing, but I haven't been able to find an H573xx example that uses the HAL code base. If anyone can point me to a HAL-based example for the STM32H573 series implementing JTAG protection. Many Thanks!
I'm trying to read a NTC temperature sensor, but the readings I'm getting are very inconsistent and at times just way off. I have nucleo on the way but this testing I'm doing is on a blue pill.The sensor is sitting in a cup of water, so temperature should be very consistent. Here is the readings I'm getting which are done at 1 second intervals, I don't need speed. The temperature of the water is about 21C. The sensor accuracy is rated +/- 1.4C at 25CTemp k: 293. c: 20.8Temp k: 293. c: 20.7Temp k: 294. c: 21.2Temp k: 292. c: 19.5Temp k: 307. c: 34.1Temp k: 295. c: 22.3Temp k: 294. c: 20.8Temp k: 293. c: 20.7Temp k: 294. c: 21.5Temp k: 293. c: 20.7Temp k: 294. c: 21.3Temp k: 294. c: 21.4Temp k: 293. c: 20.8Temp k: 293. c: 20.5Temp k: 294. c: 21.1Temp k: 292. c: 19.7Temp k: 266. c: -6.5Temp k: 293. c: 20.5Temp k: 293. c: 20.8Temp k: 291. c: 18.8Temp k: 266. c: -7.1Temp k: 293. c: 20.6Temp k: 294. c: 21.3Temp k: 294. c: 21.3Temp k: 293. c: 20.6Temp k: 294. c: 20.9At
Hello, I have a problem to display the screen on my board, it is always blank white screen. Below is a simple Screen:It shows as a blank white screen on my board, please find attached relevant files lest it is a hardware problem. Please advise. Best regards
Hi there, I want to use the AS5048A SPI encoder with the STM32 Motor Control Work bench SDK to precisely control a 3 phase GL30 KV290 Motor. I noticed STM motor control work bench only supports quadrature encoders and I can apparently use custom code to make an absolute encoder work. Is there any information about how to do this?
Hello!I am facing some problems with implementing TLSv1.3. I have enabled NX_SECURE_TLS_ENABLE_TLS_1_3 and NX_SECURE_TLS_TLS_1_3_ENABLED from CubeMX.I added these into my code:extern const NX_SECURE_TLS_CRYPTO nx_crypto_tls_ciphers_ecc; extern const NX_CRYPTO_METHOD *nx_crypto_ecc_curves[]; extern const UINT nx_crypto_ecc_curves_size; extern const USHORT nx_crypto_ecc_supported_groups[]; extern const UINT nx_crypto_ecc_supported_groups_size; // ... UINT tls_setup_callback(NXD_MQTT_CLIENT *client_pt, NX_SECURE_TLS_SESSION *TLS_session_ptr, NX_SECURE_X509_CERT *certificate_ptr, NX_SECURE_X509_CERT *trusted_certificate_ptr) { // ... /* Initialize TLS module */ nx_secure_tls_initialize(); /* Create a TLS session */ ret = nx_secure_tls_session_create(TLS_session_ptr, &nx_crypto_tls_ciphers_ecc, crypto_metadata_client, sizeof(crypto_metadata_client)); if (ret != NX_SUCCESS) { return ret; } /* Force the use of TLS 1.3 */ ret = nx_secure_tls_session_protocol_v
Post edited by ST moderator. In next time please use </> to share your code. Thank you for your understanding. hi, I am using stm32U5's uasrt2 DMA RX , DMA interrupt coming, usart idle int coming, ROR value right, but rx_buffer was not refreshed by DMA, here is my part of code. /* USER CODE BEGIN PV */ uint8_t loop_TX = 0xaa; uint8_t loop_RX = 0x0f; /* USER CODE END PV */ ............................. /* MPU Configuration--------------------------------------------------------*/ MPU_Config(); /* Reset of all peripherals, Initializes the Flash interface and the Systick. */ HAL_Init(); /* USER CODE BEGIN Init */ /* USER CODE END Init */ /* Configure the system clock */ SystemClock_Config(); /* GTZC initialisation */ MX_GTZC_Init(); /* USER CODE BEGIN SysInit */ delay_init(); HAL_Delay(100); /* USER CODE END SysInit */ /* Initialize all configured peripherals */ MX_GPIO_Init(); MX_GPDMA1_Init(); MX_SPI2_Init(); MX_USB_OTG_FS_PCD_Init();
Dear Sirs, we have a SPI CRC problem we thried heavily to solve, but no success.We broke it down to just send one byte of data, so the CRC is known in advance and it is easy to debug.Here the description what we did:DevicesMaster: STM32F7 (SPI1)Slave: STM32F4Communication mode: SPI full duplexData width: 8 bitCRC enabled on both sidesCRC ConfigurationCRC polynomial: 0x07Data size: 8 bitMSB firstOnly one data byte used for testingTest frameData byte transmitted by slave:0x55Expected CRC (CRC-8, polynomial 0x07):0xACSPI clockThe SPI clock on the master is set to the lowest possible speed:Prescaler = 256Therefore there should be no timing issue with the CRCNEXT bit being set during the last data frame is clocked.We use HAL 1.3.3 and HAL_SPI_TransmitReceive_IT on the master sideObserved SPI signals (oscilloscope)On the SPI bus we observe exactly the expected sequence:0x550xACSo the slave transmits the correct CRC value.Master behaviourWhen the first SPI interrupt occurs on the master
I am struggling to wakeup STM32N6570-DK from standby mode with user button (WKUP3).I created an isolated CMake + VSCode test project and share it in zip file. Based on latest CubeMX 6.17.0 and STM32N6 HAL 1.3.0. There is application and FSBL but I only use FSBL and do not jump into Application. My intention is that after wake-up, MCU launches Boot ROM that launches FSBL.The core part of the code is:static void EnterStandbyMode(void) { PWREx_WakeupPinTypeDef sWKUPConfigs = {0}; /* Prevent any disturbing interrupts */ __disable_irq(); /* Enable the Wake-up pin functionality */ sWKUPConfigs.WakeUpPin = PWR_WAKEUP_PIN3; /* PC13 (User button) */ sWKUPConfigs.PinPolarity = PWR_PIN_POLARITY_HIGH; sWKUPConfigs.PinPull = PWR_PIN_PULL_DOWN; HAL_PWREx_EnableWakeUpPin(&sWKUPConfigs); HAL_PWR_ClearWakeupFlag(PWR_WAKEUP_FLAG_ALL); /* AN5946 and errata say that BSEC should be enabled to go stand-by. */ __HAL_RCC_BSEC_CLK_SLEEP_ENABLE(); __HAL_RCC_BSEC_CLK_ENABLE(); /* Set init
Are there any expansion boards with Quad SPI NOR Flash chips? I am interested in using it with a NUCLEO-WB55RG board.Preferably it should use the Macronix 25L6433FM2I-08G chip, but that is not a hard requirement. This chip is found on the X-NUCLEO-GFX01M2 board, but it is implemented as a standard single SPI interface.Thanks
Hi all,I’m working on porting a firmware from a Microchip PIC18F66J50 to an STM32C071.The original device communicates successfully with Windows and Android devices over USB, through an app developed in Flutter (Android Studio) using the QuickUsb library.On the STM32 side, I’m now using the USBX stack. After quite a bit of work, I managed to get the USB communication fully working with Windows — enumeration and protocol exchange both succeed.However, while the device correctly enumerates on Android, the protocol communication fails.Since the Android app already works perfectly with the original Microchip-based device, I assume that no changes are needed on the app side. This suggests that the issue lies in how the STM32 presents itself to Android (possibly in the USB descriptors or class/interface setup).Has anyone experienced similar issues with USBX on Android, or are there known differences in how Android handles vendor-specific protocols compared to Windows? Thanks for your he
I want to be able to program the external flash via VCP. So far, I have taken the combined code from the CM4 and CM7 core, then using memory address 0x90000000, I write to the QSPI using the BSP function: if (receiving_ext_flash) { if (BSP_QSPI_Write(0, Buf, qspi_write_address, Len) != BSP_ERROR_NONE) { CDC_Transmit_FS((uint8_t*)"QSPI Write Error\r\n", strlen("QSPI Write Error\r\n")); receiving_ext_flash = 0; return; } qspi_write_address += Len; } Has anyone tried doing something like this? I have not been able to get this to work. Thanks!
Is there any way to optimize the IPD BALFHB-WL-01D3 to work at 865MHz at 22dbm for STM32WL55? And is there any hardware design guide for power of STM32WL like it is there Hardware design guide for STM32L0 application note AN4467.
Trying to run timer2 to set pwm signal for the BLUE LED (PA5).The MCU is STM32U083MCT6 and I used rm for STM32U083MC series (https://www.st.com/resource/en/reference_manual/rm0503-stm32u0-series-advanced-armbased-32bit-mcus-stmicroelectronics.pdf)I set each bit and register separately to be sure that everything is set correctly, but still miss something related to TIM2.What settings to check related to TIM2 and what is the best approach to configure timers of this MCU?
I used stm32g030c8t6 , I want to create the External loader by stm32cubeIDE, but I don't understand how to create,Are there any operation instructions? flash:w25q64 , interface is SPI-2
I all,I have a question regarding the EVSPIN32G4 board, specifically concerning the feedback resistors used in the current sensing network (default value: 11 kΩ).I am considering replacing them with 150 kΩ resistors. My main concern is whether this significant change will trigger the Overcurrent Protection (OCP) prematurely or cause stability issues with the internal op-amps.Has anyone experimented with such values, or are there specific hardware limitations I should be aware of?Best regards, Jules
Hello Everyone,I recently purchased STM32H7S78-DK.I'm looking for the code that runs on the discovery kit.As I understood from my collogue there should be an application that defines all the peripherals via cubeMX.I've downloaded the repository for this DK but all I see is examples that covers some of the peripherals and not one application that defines all the peripherals. I would if someone can share with the link for this application that define all the peripherals.
Hi everyone,I am working on a custom board based on the STM32U575RGT6 (TrustZone enabled, FreeRTOS). I have successfully ported the SBSFU example originally provided for the B-U585I-IOT02A.My configuration is:MCUBOOT_APP_IMAGE_NUMBER = 1 (Single combined S and NS image)No external loader.To meet my application needs, I added a custom FLASH_STORAGE area at the end of the flash for EEPROM emulation. To do this cleanly, I modified flash_layout.h to dynamically compute the available FLASH_NS_PARTITION_SIZE based on the remaining space.The Problem: When I use MCUBOOT_OVERWRITE_ONLY, the OTA update (via Y-Modem) works perfectly. However, when I try to use the Swap mode (by commenting out #define MCUBOOT_OVERWRITE_ONLY), the firmware download succeeds, the board reboots, the bootloader validates the signature, starts the swap process, but then crashes with a status write fail:FWUPDATE --- Démarrage de la mi
Hello everyone, I’m working on the STM32G474RE and trying to generate two independent PWM outputs using the HRTIM peripheral. To get started, I followed this tutorial: wiki.st.com/stm32mcu/wiki/Getting_started_with_HRTIM For my first PWM output, I used: Timer: HRTIM1 Channel: CHA1 Compare Unit: CMP1 This one works perfectly , the duty cycle changes correctly when I update the compare value. The problem When I tried to add a second PWM output, I followed the exact same steps as for the first one, except I used: Channel: CHC1 Compare Unit: still CMP1 (as shown in the tutorial) However, this second output (HRTIM1_CHC1) is always stuck at 50% duty cycle, no matter what compare value I write. Even if I set the compare value very low or very high, the output waveform stays at 0.5 duty cycle. What I checked The GPIO pin for CHC1 is correctly configured in alternate function mode. The timer is enabled and running. The compare register is being updated (I
Split from: Evaluation of Encoder Signal Level Shifting Approach as that was a different issue, and has been solved.I am also working with this same issue, in my case i have a encoder operating at 24V, and signal in comparable frequency i have implemented a simple voltage divider, the circuit works just fine, but as i don't have equipment to measure the noise and also i would prefer to have galvanic separation to my MCU, so in this case is there any good suggested level shifter or optocoupler, should i combine the both strategy of voltage divider and optocoupler or just 1 is fine (from perspective of noise and safety)?
Dear ST Support Team,I am currently working with the STM32N657X0H3 microcontroller.We are attempting to use the internal 4.2 MB continuous SRAM (starting at address 0x34000000) as the framebuffer for LTDC.The procedure followed is:• Writing pixel data into internal SRAM at 0x34000000• Configuring LTDC_Layer1->CFBAR with the same framebuffer address• Enabling LTDC and RGB outputHowever, when using the internal SRAM (0x34000000) as the framebuffer, the RGB output signals remain inactive.When we configure the framebuffer in DTCM memory (as mentioned in the reference manual), the RGB signals become active and function as expected.However, the DTCM memory size is very small and not sufficient to hold a full framebuffer for our display resolution. Therefore, using DTCM is not a practical solution for our application.We have verified the following:• AXI read/write test passes successfully• Framebuffer base address is correctly configured• LTDC timing configuration is correct• RGB pin confi
Hi, I am using STM32CubeMX 6.16.1 with a STM32H503RB and I have exactly the same problem : RCC is configured with LL library (not HAL), here is the SystemClock_Config() function generated by STM32CubeMX : void SystemClock_Config (void) { LL_FLASH_SetLatency(LL_FLASH_LATENCY_5); while (LL_FLASH_GetLatency() != LL_FLASH_LATENCY_5) { } LL_PWR_SetRegulVoltageScaling(LL_PWR_REGU_VOLTAGE_SCALE0); while (LL_PWR_IsActiveFlag_VOS() == 0) { } LL_RCC_HSE_Enable(); /* Wait till HSE is ready */ while (LL_RCC_HSE_IsReady() != 1) { } LL_RCC_LSI_Enable(); /* Wait till LSI is ready */ while (LL_RCC_LSI_IsReady() != 1) { } LL_RCC_PLL1_SetSource(LL_RCC_PLL1SOURCE_HSE); LL_RCC_PLL1_SetVCOInputRange(LL_RCC_PLLINPUTRANGE_2_4); LL_RCC_PLL1_SetVCOOutputRange(LL_RCC_PLLVCORANGE_WIDE); LL_RCC_PLL1_SetM(12); LL_RCC_PLL1_SetN(250); LL_RCC_PLL1_SetP(2); LL_RCC_PLL1_SetQ(4); LL_RCC_PLL1_SetR(2); LL_RCC_PLL1P_Enable(); LL_RCC_PLL1_Enable(); /* Wait till PLL is read
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.