Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
Hello. I'm using B-G431B-ESC1 to operate drone motorThe operation was successful using FOC, but from 28,000 RPM and above,it changes to - speed as seen on the Pilot screen. (When the rpm becomes negative, speed control becomes impossible.)In fact, using betaflight, I have seen it go up to 45,000 rpm.Any idea how I can change the minus speed or what I need to change??
TL;DR: The receiver ESP32-LoRa node is showing garbage values instead of accelerometer values. The STM32 - LoRa sender node does read correct values from the MPU6050 sensor, as we confirmed that through PuTTY. .ioc configuration Context: So I am trying to program an STM32F411CEU6 module to read accelerometer values from MPU6050 (a 6-axis motion sensor). Then what I am trying to do is send those values to an ESP32 module. I am using Ra-02 SX1278 LoRa boards as the transceiver for the communication. We verified that the values were read properly by printing the MPU6050 sensor readings to the serial port. At the receiver end, we used Sandeep Mistry's LoRa.h library for programming the ESP32 in Arduino IDE. Clock Configuration for ref.Issue: The receiver end was receiving garbage values when we tried to monitor the sent values. Even the code in void setup() was taking a while to execute. I believe the issue is with configuring the LoRa parameters between the sender and recei
Can anyone help me understand how these two arrays have been made#define M1_ANGC {-116,-363,-611,-843,-1091,-1338,-1571,-1833}#define OFST {0,17,51,99,167,252,348,474}these arrays are used in MTPA calculation with y=mx+c equation.These are the motor parameters for which the array has been calculated. Your assistance will be appreciated.
Hello community members, I am using a STM32H5 with acitvated MPU region. I want to check and test dection of nullpointer access.Because of safety reasons. I have configured and activated the mpu so far. When doing a write access to the declared null pointer, the MemManageFault Handler is called as expected. uint32_t *m_pTest = nullptr;*m_pTest = m_value; // -> MemManageHandler is called (as expected)when doing a read access, the BusFaulthandler is calledm_value = *m_pTest; // ->BusFaultHandler is called (not my expectation)//here my mpu configuration and settingsSCB->SHCSR |= SCB_SHCSR_MEMFAULTENA_Msk |SCB_SHCSR_BUSFAULTENA_Msk |SCB_SHCSR_USGFAULTENA_Msk;/* Configure the MPU to prevent NULL-pointer dereferencing ... *///check nullpointer access Region1MPU_InitStruct.Enable = MPU_REGION_ENABLE;MPU_InitStruct.Number = MPU_REGION_NUMBER1;MPU_InitStruct.BaseAddress = 0x00U;MPU_InitStruct.LimitAddress = 0x200U;//512Byte for exampleMPU_InitStruct.AttributesIndex = MPU_ATTR
Hello,I am below Hardware and Software setup:Hardware:MCU Board: NUCLEO F401REPower Board: X-NUCLEO IHM08M1BLDC Motor: Portescap 22ECP45-8B-154.01 (specifications_22ecp45.pdf attached)Software:MC Workbenach v6.4.1I am using sensorless FOC (STO-PLL) in WorkBench tool. I am trying to increase the speed of the motor to its MAX 47000 RPM. But, I am getting only 7200 RPM with Parameters from Motor Datasheet in MC Workbench tool. I have changed the HW to short 3-SHUNT and removed mentioned capacitors.Below are my parameter configurations: Max speed I am getting on Motor Pilot:I queried Motor for the Max speed of the motor. They replied it is achievable by using 14 mNm Torque. I have few questions:1. In the Motor profiler tool, reaches upto 12000 RPM then giving Speed Feedback error. What configurations can set to run profiler tool successfully?2. Does ST HW (F401RE + IHM08M1) support 47K RPM @24V for the Motor?3. With ST workbench tool having Sensor
I designed a board that uses a STM32H750 with a USB3300-EZK that has stopped communicating over USB. It's been having intermittent issues for the last day or so (sometimes I'd need to power cycle the board before it would show up, but then it would work flawlessly). Earlier today, I plugged it into a Raspberry Pi, and then it died fully. I've plugged it into that Pi before without issue.Despite probably hundreds of cycles at this point, I haven't gotten the USB to work again. The PHY is generating a stable 60MHz clock, and DIR is low. I haven't observed any communication on the D0..8 lines. That leads me to believe the problem is with the STM32.I am using pc2_c and pc3_c, which are supposed to work with USB, although I've heard they're more susceptible to (static?) damage.I do have a second board that I can switch to, although I don't have a third prototype, and it really would be good to figure out what happened here so I can prevent it from happening again.
I found in my tests that for the same sequence of operations (Radio.SetChannel -> Radio.RadioSetTxGenericConfig -> Radio.Send), the time required differs significantly between waking up from STOP2 sleep mode and waking up from Sleep mode. Here is Radio workflow:Startup -> Sleep -> Calibration -> Standby Here is the test code, with two additional modifications.void app_fsk_send(void) { if (!s_radio_init_flag) { Radio.Init(&s_radio_events); s_radio_init_flag = true; } TxConfigGeneric_t tx_config; uint8_t syncword[] = {0xC1, 0x94, 0xC1, 0x00, 0x00, 0x00, 0x00, 0x00}; if (!s_radio_init_flag) { Radio.Init(&s_radio_events); s_radio_init_flag = true; } priv_prbs9_generator(s_payload, 16); tx_config.fsk.ModulationShaping = RADIO_FSK_MOD_SHAPING_G_BT_1; tx_config.fsk.FrequencyDeviation = 40000; tx_config.fsk.BitRate = 100000; /* BitRate */ tx_config.fsk.PreambleLen = 4; /* in Byte */ tx_config.fsk.SyncWordLength = 3; /* in Byt
CubeIDE: v2.0.0CubeMX: v6.16.1Debugger: ST-LINK/V2 V2J46S7Hello,I'm attempting to setup a dual core project using STM32H757XIH MCU on CubeMX. I've generated and imported the project for CubeIDE. I've configured the Trace and Debug -> DEBUG for "Serial Wire" with M7 and M4 selected with Cortex-M7 as the initializer. I've configured one pin (PJ10) to be an output for a user LED.I've attempted to follow AN5361 "Getting started with projects based on dual-core STM32H7 microcontrollers in STM32CubeIDE" when configuring the debug profiles for the M7 project and M4 project while leaving the rest set to default.I've attached the logs to this post. Am I missing something when configuring the processor? Let me know if I need to add anymore information on my configuration.
On the STM32N6, half the ram is attached to this NPU RAM on it's own bus. Are there any downsides to using this ram for non neural net applications. Use case I would like to use the NPU ram for just frame buffers. From what i can tell the memory is continues so i could put a memory buffer across potentially 2 different AXISRam sections. Just asking if i would be able to use DMA operations with the DMA2d or the GPU2.5D engine. Or if i could DMA peripheral like SPI or LTDC from these buffers Related posthttps://community.st.com/t5/stm32-mcus-products/npu-sram/m-p/808103#M279969
In our project I use STM32H573VIT6 LDO uC. We have a problem with the PB14 pin. We use 3 pins for LED control (PB10, PB13 and PB14, see photo). The problem with the PB14 is that the LED lights up dimly without code initialization. If PB14 is initialized as Output, Open Drain, No Pullup-Pulldown, it lights up dimly in the OFF state and normally in the ON state. With Output Push-Pull initialization it works normally, i.e. in the OFF state the LED does not light up and in the ON state it lights up normally. 1. What could be the problem? 2. Should I use PB14 at all and is there a potential risk of later problems?
I am trying to use the DA function of the STM32H573. I can successfully write the OBK file (with TrustZone disabled) and regression via STM32_Programmer_CLI.exe. However, I encountered an issue when trying to read the plaintext of the OBK payload in my code. I am unable to obtain the correct plaintext through SAES and DHUK.Here is part of my code:int32_t OBK_Flash_ReadEncrypted( void *pData) { uint32_t Offset =0x0100; uint32_t Length = 0x60; uint32_t i = 0U; CRYP_HandleTypeDef hcryp = { 0U }; uint32_t SaesTimeout = 100U; uint8_t DataEncrypted[MAX_SIZE] = {0U}; uint8_t *p_source = (uint8_t *) (FLASH_OBK_BASE_S + Offset); uint8_t *p_destination = (uint8_t *) DataEncrypted; uint32_t a_aes_iv[4] = {0x8001D1CEU, 0xD1CED1CEU, 0xD1CE8001U, 0xCED1CED1U}; for (i = 0U; (i < Length); i++, p_destination++, p_source++) { *p_destination = *p_source; } __HAL_RCC_SBS_CLK_ENABLE(); __HAL_RCC_SAES_CLK_ENABLE(); /* Force use of EPOCH_S value for DHUK */ //WRITE_REG(SBS_S->EPOCH
I've got an STM32U385 on a custom board that is unresponsive.The software is based on the OEMiROT trustzone example.The sequence of events that lead to this, as nearly as I can remember were:1.) Set up the device with provision.bat, with RDP level 2. This worked fine. The device ran as it should.2.) Regress the device using regression.bat, this process failed, but left the device in an accessible state for the debugger.3.) I connected the boot0 pin to VDD, connected with the programmer in hot plug mode, set RDP to 1.4.) I set RDP to 0 and TZ enabled to 0, which worked.5.) I disconnected the boot0 jumper, and tried loading code normally, it then failed at address 0x80004000. Reading out that address with the programmer revealed that it was not programmed, but instead remained all 0xff's. I tried several times to program, always with the same result, the first part of memory, up to address 0x80003fff programmed correctly, and the rest failed.6.) I tried running the regression script agai
Hello everyone,I am trying to implement SBSFU (Secure Boot Secure Firmware Update) on NUCLEO-G474RE using STM32CubeExpansion_SBSFU_V2.7.0.Initially, everything was working fine and I was able to program the board normally.What I didI followed the SBSFU documentation and examples.While configuring SBSFU, I modified Option Bytes, specifically Write Protection (WRP) addresses to match the SBSFU memory layout.After applying the option bytes, the problem started.Current problemNow I cannot program or erase the MCU anymore.I get the following errors:1.In STM32CubeIDE'Launching SBSFU (1)' has encountered a problem.Failed to execute MI command:load ...\SBSFU.elfError finishing flash operation2. In STM32CubeProgrammerFull chip erase failsMass erase fails with error:Error: Mass erase operation failed. Please verify flash protection3.I also tried:Full chip eraseErase selected sectorsHardware reset / power cycle“Under reset” connection modeFactory reset via STM32CubeProgrammer→ All fail with
STM32G491KEU3 on custom board. Using STM32CubeProgrammer to read/change option bytes.With BOOT_LOCK unchecked I use STM32CubeIDE to flash and debug my project. However SysTick_Handler() is never called, so HAL_GetTick() always returns the same value (zero). With BOOT_LOCK checked, HAL_GetTick() returns incrementing tick counts as expected.I thought I understood the ref manual description of BOOT_LOCK. Does BOOT_LOCK do other things?
Hi,we are trying to get a 800x800 display to work with the STM32U5G9VJT6Q, using either RGB888 or RGB565 in Video Mode (Burst).According to what we read it is definitely possible. Did we miss something?Could someone please confirm that is definitely possible?Much appreciatedThank you
Hello,I am using STM32 Motor Control SDK / MC Workbench with sensorless FOC (STO + PLL) to drive a low-speed, high-inertia 24V 40W BLDC fan motor.Power Board: X-NUCLEO-IHM07M1Issues observed:Motor rotates stably but produces intermittent (not continuous) rubbing noise, mainly after settling at certain RPM.Large speed oscillations are visible in Motor Pilot (speed dial deviation).Motor does not reach max speed even when increasing current limit in MC Workbench.Reducing Iq PI gains(cut off frequency) does not significantly reduce the noise.Very low PLL gains are required for stable rotation; higher PLL gains cause oscillation or loss of speed feedback.pilot_register_observationQuestions:For low-speed, high-inertia fan motors, what is the recommended observer / speed LPF cutoff frequency parameters?Can I reduce this intermittent noise and speed oscillation and run smooth motor control without noise?Which parameters should be prioritized to:Reduce speed oscillationsEliminate intermitt
A development collaborator on the application is trying to improve the performance of transmitting the payload between the app and the board containing the STM32WB55 microcontroller via BLE. He is asking if he can increase the size beyond 20 bytes in order to reduce the upload time, which is currently 40 seconds (ideally, he wants to reach 6 seconds, the same way I did using the ST BLE Sensor app). The AN5247 documentation recommends writing in 20-byte increments as shown in the image below, and he would like to know if he needs to perform an ACK after each 20 bytes or if he can send directly. Any help would be appreciated.
Hello, does anyone help me with example for devkit with FatFs on uSD card? Thanks
Hi,based on the ST example where the 640kB RAM is splitted into 2 * 320kB for secure/non-secure application, I want to change this to 32kB/608kB for secure/non-secure app. After modification of the linker files for the secure/non-secure app, the non-secure app runs into an hardfault right at the start. The error is that some ns access is done in secure area in SRAM1 (at address 0x2001f840).I first started the project on the STM32H563 eval board and simply copied the settings of MPU and GTZC over to the STM32H562. These settings are working on the STM32H563, so I can properly jump there into the non-secure app.Are there any difference in setting the memory areas for secure/non-secure/priviledged feature?Here are the settings.linkerfile non-secure:define symbol __ICFEDIT_region_RAM_start__ = 0x20008000;define symbol __ICFEDIT_region_RAM_end__ = 0x2009FFFF;linkerfile secure:define symbol __ICFEDIT_region_RAM_start__ = 0x30000000;define symbol __ICFEDIT_region_RAM_end__ = 0x30007FFF;v
Hello guys.I have an STM32WB5MM-DK disco board and im trying to get familiar with the ble stack. What i want to do is create a p2p server, poll an onboard i2c temp sensor for data and send that data through ble. What i did at first (successfully)was to set the device as a p2p server, set the user button as an EXT line and set the irq to schedule a task. That task transfered a random number through ble.What i tried to do next was to set the interrupt handler schedule a task tha would poll for the i2c data and schedule another task that would send said data, which didn't work. The address of the onboard i2c sensor is 0x70. I attach my .ioc file My callback function void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) { if (GPIO_Pin == B1_Pin) { UTIL_SEQ_SetTask(1U << TASK_BUTTON_1, CFG_SCH_PRIO_0); } APP_DBG_MSG(" Buttn press\n\r"); return; }I've added the name of my tasks on the app_conf.h file/**< Add in that list all tasks that may send a ACI/HCI command
Hello.How can we enable brown out for this processor and the brown out voltage?Thank you.
Hi, I am working on STM32F469NI using the USB OTG HS peripheral in CDC (VCOM) mode. When using USB CDC without DMA, the VCOM works fine. However, when I enable Internal IP DMA (from CubeMX → USB_OTG_HS → Parameter Settings → Enable internal IP DMA), the USB CDC communication stops working after some time. Setup details: MCU: STM32F469NI USB mode: Device (CDC VCOM) PHY: Internal FS PHY DMA Mode: Internal IP DMA enabled for USB_OTG_HS Running on custom board Observed behavior: On PC, the VCOM port is detected correctly. Initially, data transfer works fine. After some time (or after repeated Tx/Rx), the communication hangs completely. No data transfer occurs until reset. If I disable Internal IP DMA, the issue goes away. What I tried: Checked buffer alignment (made Tx buffers 4-byte aligned). Verified HAL callbacks (CDC_Transmit_FS etc.) are still being called. Questions: Is Internal IP DMA for USB HS CDC fully supported on STM32F469NI? Are there know
Hey all, I have been debugging a nasty issue that I have been having over the last couple of days. I am using the STM32n657I0 MCU. The issue that I observed were random crashes in my code. Luckily the problem was well reproducible. What I observed was that sometimes the ITCM memory was suddenly not accessible anymore, or some data had changed. To make certain that my code was not modifying the ITCM contents I configured the MPU to disallow write operations to the ITCM memory. Also I am not yet using DMA or anything like that, which could write to the ITCM. After the bug triggers, I cannot read the ITCM memory anymore with the debugger or the processor, all other memories are still working and actually execute, which prints a nice crash log to serial. When you encounter failing memory or other strange issues you would think maybe the core is unstable. So, I tried to decrease the frequency, which did not change the behavior at all. (I went from 800MHz to 200MHz). I also
We are currently working on a project with the STM32U5 series running FreeRTOS and need to integrate the USB Mass Storage (MSC) class for adding pendrive / thumbdrive support. While exploring solutions, we noticed that CubeIDE doesn't directly support USB class configuration for USB host, and AzureRTOS's USBX seems to be the default recommendation. However, switching to AzureRTOS is not feasible for our project since FreeRTOS is deeply integrated into our system. So we’d like to know: * Can you please provide USB MSC stack for freertos as well for stm32U5 ?* If not, do you recommend any third party USB stack for this purpose?* Do you recommend the integration of TinyUSB open source stack ?
Hello everyone, I am currently working on a project using the STM32U5G9ZJT6Q mcu with USB UVC. For my setup, I am providing: 32 MHZ external clock to phy 144 MHZ system clock In the documentation(TRM and CubeMX), the maximum external phy clock specified is 32 MHZ. However I need to achieve a 60 MHZ PHY Clock, which seems to be supported by the hardware but isn't explicitly listed in CubeMX or the reference manual. My questions are: Is it possible to configure the external PHY Clock to run at 60 MHZ? If so, does anyone have an example configuration or code snippet to achieve this? Any insights or suggestions would be greatly appreciated! Thank you in advance.
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.