Join conversations with your peers and ST experts. Explore the full potential of STM32 microcontrollers for your embedded design.
Most recent activity
I use MCSDK6.3.2 to generate code, when use TIM1 to generate pwm wave, everything is ok. But, when I use TIM8 to generate pwm wave, the code is still TIM1, which is fixed in the code, not according to the pwmc_handle. What is wrong? Is this a bug?
Seems like transparent background is ignored in final blending, any suggestions will be wellcome.If key-coloring is changed on L2, background color will be shown, so I expect the key-coloring is actually working.L1 has a background picture, and is not updated.Changing L2 alpha from 0xFF to 0x80, normal blending showns both L1 and L2 in correct format, so data seems to be correct picked up.L2 is updated pr. frame, double buffered, and is shown flawlessly but L1 is not visible, when L2-alpha is 255. All Frame-buffers are in internal RAM and each in it's own RAM-bank alligned to 32 byte boundery.
Im using the following code that is part of a metal detector I'm building. Im trying to trigger the ADC based on TRGO of TIM2 (I need dma / adc readings every 10us after the of each TX pulse). I expect the TIM2_IRQHandler interrupt to enter 10us (ADC_DELAY_US) after the TX pulse ends (TIM1_CC_IRQHandler). I added a buffer (buffer variable) to keep track of the milliseconds of the events but when I print it on gdb (print buffer) and then subtract tx_end_micros to adc_start_micros, I dont have 10us, as expected:This is a print of the gdb: {{tx_end_micros = 2573435545, adc_start_micros = 2573437222, num_pulses = 2624525, num_pulses_tim2 = 2624526}, {tx_end_micros = 2573436545, adc_start_micros = 2573436542, num_pulses = 2624526, num_pulses_tim2 = 2624527}}Below is the full code:#include <stdio.h> #include "stm32f4xx.h" #include <math.h> // Function Prototypes void SystemClock_Config(void); void GPIO_Init(void); void TIM1_PWM_Init(void); void TIM5_Init(void); void LED_I
Stm32F746G DISCOMy program was written to accidentally flash a value to be stored in the wrong location. the display would be unresponsive so I'd reboot it without issue. My software still worked normally, it's only when it encounters that line. How I think I bricked it was when I ran it though debugging, that's when I couldn't connect it via st link. It would say no stm device found.The strange thing is, I was able to connect to it via a different usb port and unbrick the device. When I ran the debugger again I bricked it the second time. How could this be?It tells me this might not necessarily be solely a hardware issue but something in conjunction with Windows. I've spent all night uninstalling, reinstalling drivers, fiddling with boot0 pin and bootloader, using different settings with st programmer, etc. Under normal circumstances id just buy a new board but I'm not in a position to do so, I need this urgently fixed by this weekend
Hi all,I'm working on an STM32F411 project using STM32CubeIDE (bare-metal, no HAL). I'm setting up a 1ms tick using SysTick_Config() and defining my own SysTick_Handler() to keep a millisecond counter. Here's the issue:When I increment a static volatile global counter inside the handler using '++', the system crashes and ends up in Default_Handler. But strangely, if I assign a constant (e.g. millis = 123;), it works perfectly fine. Moreover, if I increment a local temp variable and increment millis, it'll take it just fine. Here's my code snippet. I'm not using the HAL library for this. Would you know why this would be? I'm using an STM32F411CE6 black pill.Thanks! static volatile uint32_t millis = 0; void SysTick_Handler(void) { // This works: // millis = 123; // This works as well: uint32_t tmp = millis; tmp++; millis = tmp; // This causes a crash into a forever loop in default handler: millis++; (void)(SysTick->CTRL); // Clear COUNTFLAG } // SysTick is initialized like
Dear ST Support Team,I hope this message finds you well.I am currently working on a custom RF design using the STM32WLE5CCU6 in UFQFPN48 package, and I intend to operate in the 433 MHz ISM band with +22 dBm output power.While referring to Application Note AN5457, I found valuable information and examples for PA output matching networks and impedance values extracted via load-pull analysis. However, it appears that the document does not provide any reference impedance data or matching guidelines for 433 MHz at high power levels (+22 dBm) for this specific MCU and package.Therefore, I would like to ask:What is the optimal output impedance (complex conjugate of the load) for the PA in this configuration (433 MHz, +22 dBm, UFQFPN48)?How can I accurately calculate or measure the required PA matching network (L1, C1 values) to transform this impedance to 50 Ω, considering high efficiency and minimal power loss?The circuit I used for impedance matching is as follows:Only the values you see
Hello ST Community,I am developing a custom board based on the MB1389 development board and have encountered some obsolete components used in the reference design. Specifically:NX3L1T3157GM,115 is now obsolete. I plan to use NX3L1T3157GMZ as a direct substitute.BGS13S4N9E6327XTSA1 is also obsolete, and I am considering BGS13SN8E6327XTSA1 as a replacement.I’ve reviewed the datasheets for both substitutes and noted minor differences in parameters such as on-state resistance and channel matching in the NX3L1T3157 variant, and potential RF characteristics in the BGS13S4 replacement.Could anyone from ST or the community advise if these substitutions are fully compatible with the MB1389 design, or if there are specific implications (e.g., signal integrity, RF performance, PCB footprint) that I should be aware of before finalizing the hardware?
I am currently working on a project where I'm designing a keypad to send HID commands over USB. Now, I want the keys to register as if a keyboard was connected and a a rotary encoder to control mouse scroll wheel operations. To confirm, is this possible with a composite class such that it enumerates as a keyboard+mouse? Also, if anyone has experience with HID, is it possible to send power commands from the STM to the computer if a key is pressed?
I am trying to configure the HS OTG port on the STM32H747I-DISCO dev board, but setting "Use external vbus" seems to be not enough. I can measure 0.8V on the CPEN line (measured from R11) but I don't see anything on the OUT line of the voltage switch (measured from the positive terminal of C7) and LD7 does not turn on. Is 0.8V the expected output voltage for CPEN? I do not see a value for TYP on the USB3320C-EZK datasheet. Is there more configuration I am missing?
I can not get any output on PB9 after setting TIM16_Init:void MX_TIM16_Init(void) { /* USER CODE BEGIN TIM16_Init 0 */ /* USER CODE END TIM16_Init 0 */ TIM_OC_InitTypeDef sConfigOC = {0}; TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig = {0}; /* USER CODE BEGIN TIM16_Init 1 */ /* USER CODE END TIM16_Init 1 */ htim16.Instance = TIM16; htim16.Init.Prescaler = 32000; htim16.Init.CounterMode = TIM_COUNTERMODE_UP; htim16.Init.Period = 65535; htim16.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1; htim16.Init.RepetitionCounter = 0; htim16.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_ENABLE; // TIM_AUTORELOAD_PRELOAD_DISABLE; if (HAL_TIM_Base_Init(&htim16) != HAL_OK) { Error_Handler(); } if (HAL_TIM_OC_Init(&htim16) != HAL_OK) { Error_Handler(); } sConfigOC.OCMode = TIM_OCMODE_TIMING; sConfigOC.Pulse = 0; sConfigOC.OCPolarity = TIM_OCPOLARITY_HIGH; sConfigOC.OCNPolarity = TIM_OCNPOLARITY_HIGH; sConfigOC.OCFastMode = TIM_OCFAST_DISABLE; sConfigOC.OCId
STM32G473CB has 3 DAC channel outputs. a. Can these three DAC channels output a 100KHz triangle wave signal at the same time? b. In addition to the triangular wave, can the output signal output an irregular 100KHz waveform? thanks
I was able to flash the BLE full extended and run the Ble Transparent Mode in the dongle correctly. But when I want to use the Thread Cli Cmd application it simply won't work. I flash the correct stack (thread ftd bin v1.22.0 (at 0x0808B000 as the Release notes says) and the FUS version is 1.2.0 (from release 1.22.0). The APP_THREAD_CheckWirelessFirmwareInfo() returns p_wireless_info->StackType = 0, so the Leds starts blinking in error. This happens when after uploading the stack I press Start FUS and then proceed to debug. But if I press Start Wireless stack (as I had to do with the nucleo and the ble_thread_dyn stack), when I debug and boot CPU2 it won't send the Ready Notification (which it correctly does when it start with the fus). So the problem is that from the FUS I cannot start the Thread Stack but when I read the Stack version from the CubeProgrammer it says the correct one. Also if I follow this: from CubeProg Start Wireless Stack - Run App (
I found this module B-UWB-MEK1 but seems like it cannot be purchased. Are there any chances that it will be released soon? Are there any alternatives for UWB position tracking? Or wireless position tracking in general?Thanks for help.
Hello,I'm new to stm32 microcontrollers. I'm trying to figure out how to configure LPTIM1 in counting mode, external clock in using cubeMX. Is there any examples on how to set it up?Is this even possible?Thanks in advance.
I was reading this conversation and found the comment about an example showing support of Audio Class with USBX and ThreadXhttps://community.st.com/t5/stm32-mcus-embedded-software/has-anyone-managed-to-get-a-usbx-audio-device-working-on-stm32/m-p/112225/highlight/true#M5290For some reason, the example is disappearedIs there a reason on why it has been deleted? Is there a way to get it?
Hi, I am using STM32G0B1KC ad usb device. I will show you all the conficuration for USB_DRD_FS and USB_DEVICE middleware.I am using the internal HSI48 for the USB clock.When I connect the device to my PC, the device is not recognized.Can anyone help me?Thank you
Hello everyone, I'm working on a BLDC motor project that drives an overhead (tilting) door using the STDRIVE101 gate driver, configured via MC Workbench.The power stage uses STL110N10F7 MOSFETs, and the motor supply voltage is 24V.PWM switching frequency is set to 20 kHz. :collision: Issue I'm facing unexpected triggering of the VDS (Short Circuit) protection, especially: Right at motor startup When I disable and then re-enable the VDS protection while the motor is running, the fault is immediately triggered :gear: Current configuration: VSCREF = 1.32 V → so VDSth = 1.32 V Digital Filter Duration = 111.11 ns SW Dead-time = 800 ns Charge Boot Capacitor = 10 ms / Duty = 0% PWM frequency = 20 kHz MOSFETs: STL110N10F7 Startup current: around 5 A DT/Mode pin is tied to GND → meaning fixed internal dead-time is selected (per datasheet) CP pin is also tied to GND → bootstrap auto-recharge is disabled I also measured that the FAULT signal remains active for ~10 ms aft
Trying to get SPI1 to work on the NUCLEO-H7S3L8.Starting a new project from the Board Selector works with no problem, however starting from the MCU Selector, the HAL_SPI_Transmit gets stuck at in stm32h7rsxx_hal_spi.c in the while loop at line 4008.Eventually we will be using a custom board, so need to figure this out. Any ideas?Thanks,:)
I am using custom STM32G4 board and generated code using the MCSDK 6.2.0. I am observing that the SysTick_Handler(void) function is called before the peripheral initializations, and it is leading to hardware fault.int main(void) { /* USER CODE BEGIN 1 */ /* USER CODE END 1 */ /* MCU Configuration--------------------------------------------------------*/ /* 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(); /* USER CODE BEGIN SysInit */ /* USER CODE END SysInit */ /* Initialize all configured peripherals */ MX_GPIO_Init(); MX_ADC1_Init(); MX_ADC2_Init(); #ifdef DACENABLED MX_DAC1_Init(); #endif MX_CORDIC_Init(); MX_OPAMP1_Init(); MX_OPAMP2_Init(); MX_OPAMP3_Init(); MX_TIM1_Init(); MX_TIM4_Init(); MX_FDCAN1_Init(); /* USER CODE BEGIN 2 */ MX_MotorControl_Init(); /* Initialize interrupts */ MX_NVIC_Ini
Hello,we are using Sensorless FOC with open loop starting of the BLDC motor. The Motor is starting reliably under normal and heavy load conditions. But without load the I got startup failure. Any idea what paramter should be checked or improved?MC SDK 6.2PLL Observer
Hello,I am trying to upload the user firmware using BFU(1 slot) and Linux minicom, it always failed to complete to transfer a UserApp.sfu. I have read the UM2767 and followed all steps. But it works well on Windows Tera Term.I am testing on both of Nucleo55 eval board and custom board and using STM32Cube_FW_WL_V1.0.0(SBSFU version 2.4.0), not succeed.I have looked for the similar issues, couldn't get the workaround.There are some similar issues:https://community.st.com/s/question/0D53W00000HMk4nSAD/for-sbsfu-v240-send-firmware-file-by-linux-minicom-ymodem-failedhttps://community.st.com/s/question/0D53W00000Eba1XSAR/download-firmware-by-ymodem-failed-at-linuxLast article tells me this issue would be fixed in SBSFU v2.4.0, but I am failing.This is what I've done:defined MINICOM_YMODEM in app_sfu.hErase flash and upload the BFU.binset minicom 115200bps, 8N1, HW flow control: None.ymodem protocol setting:+------------------------------------------------------------------------------+ | Nam
I am currently working on implementing Firmware Update Over-The-Air (FUOTA) using the NUCLEO-WL55JC1 board with the STM32CubeWL SDK, version 1.3.0. The LoRaWAN server being used is AWS IoT Core for LoRaWAN.Here is a summary of the issue I am facing:I have successfully created a multicast group and initiated a FUOTA task from the AWS IoT Core.The multicast session is established correctly, and the device performs the necessary handshaking steps without any errors.At the scheduled time, the end device (NUCLEO-WL55JC1) switches to Class C as expected.I observe that the device enters RX mode and shows RxDone status, indicating that it is listening for downlink data.However, no FUOTA fragments are received by the device, and hence the update does not proceed.On the AWS side, the fragments appear to be sent continuously.The message shown in the image is the last log received on the end device after switching to Class C.I have attached the FUOTA log from the end device.Any insights or suggest
Hello, how is everyone doing ? I am making this post because I just received a Riverdi STM32 Embedded display for my last ever studying project, as I will use it to replace 7-seg, buttons and keybord. I made a simple connection for the power supply (I soldered two wires on the connector, to avoid cutting the given cable, as I want to use it later in the final version of my project. My problem is that when I turn on the power, the screen switches on but only displays a black screen at maximum brightness. I tried reseting the device with the back button, and also created a simple TouchGFX project to display a png image and the memory flash of the microcontroller with ST-Link v2 works fine but once the flash is done, the screen goes back to the very bright black screen state. I have made some research but have not found anything interesting, so I make this post hoping that someone already had this issue or has a solution. In the meantime I have also contacted Riverdi, but I want
Hi We are developing a product that uses an STM32 microcontroller. In the microcontroller’s firmware, we have implemented a password that the user must enter at startup. If the user forgets the password, how will the program run? (Note: No software or hardware fallback has been implemented for this issue, and the source code is not accessible.)
I'm working on sensor data transfer via BLE to mobile app (like nrf connect). My STM32WB board gets connected with the app, but the data is not transmitted. When I give functions in the main while loop for transmitting, it stop the device advertisement at mobile app. How to transfer the data to mobile app? I need to send continuous sensor data to mobile app.I've also tested timer function as well. But still, it's impossible for me to transfer the data. I'm attaching the image of mobile app connection, there you can see that the value is 0. There, I need sensor data to be printed.Can anyone help me to resolve this issue? Thanks 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.