Questions tagged [stm32]

The STM32 is a family of microcontrollers from ST Microelectronics, based on the Cortex M0, M0+, M3, M4, or M7 ARM core (depending on the product line).

The STM32 is a product line from ST Microelectronics using 32-bit Cortex-M microcontrollers and/or Cortex-A microprocessors. There are a variety of microcontrollers with different power consumption and performance characteristics. Some microcontrollers also offer DSP and floating point functionality.

In addition to the line of microcontrollers, ST also offers a number of different evaluation boards and development boards. These boards contain a microcontroller on a PCB with additional support electronics and various sample sensors. The STM32CubeIDE Integrated Development Environment supports software development for these products.

Two such product lines are the Discovery kits such as the STM32F0DISCOVERY and STM32F3DISCOVERY boards and the Nucleo product line of prototyping boards.

As of Q1/2023, the family consists of:

MPU

  • STM32MP1 - Cortex A7 & Cortex M4 big.LITTLE

Low Power

  • STM32L0 - Low-Power Cortex-M0+
  • STM32L1 - Low-Power Cortex-M3
  • STM32L4 / L4+ - Low-Power Cortex-M4
  • STM32L5 - Low-Power Cortex-M33
  • STM32U5 - Ultra Low-Power Cortex-M33

High Performance

  • STM32F2 - High-Performance Cortex-M3
  • STM32F4 - High-Performance Cortex-M4
  • STM32F7 - High-Performance Cortex-M7
  • STM32H5 - High-Performance Cortex-M33 (up to 1 GHz)
  • STM32H7 - High-Performance Cortex-M7 (up to 550 MHz)

Main Stream

  • STM32F0 - Mainstream Cortex-M0
  • STM32F1 - Mainstream Cortex-M3
  • STM32F3 - Mainstream Cortex-M4
  • STM32G0 - Mainstream Cortex-M0+ (upgrading STM32F0)
  • STM32G4 - Mainstream Cortex-M4 (upgrading STM32F3)

Wireless MCUs

  • STM32WB - M4/M0 with BLE, Zigbee
  • STM32WL - M4/M0 with LoRaWAN
5104 questions
1
vote
1 answer

Convert interrupts to DMA

I'm trying to play a note through the speaker of my board. Currently, I have an interrupt as follows: void sampleISR(void) { static uint32_t phaseAcc = 0; phaseAcc += a; //this `a` is modified outside analogWrite(OUTR_PIN, phaseAcc); } It is…
Bula
  • 2,398
  • 5
  • 28
  • 54
1
vote
1 answer

EEPROM protocol misconception

I am currently using a michrochip's eeprom ( 24cw160 ) connected with an stm32f4 (11RET) via i2c. The configurations and the connection seem to work as my logical analyzer prints some i2c messages (with ACK) and I can send data and receive data…
Spyros Mourelatos
  • 484
  • 1
  • 8
  • 19
1
vote
1 answer

STM32 USB programming, jump to bootloader for DFU

I was having trouble on the STM32L462xx with setting the device up for flashing over USB without having access to the BOOT0 pin. Going off of the tutorial on the ST site didn't seem to accomplish the task. Has anyone successfully set the STM32L4…
falon89
  • 116
  • 1
  • 5
1
vote
0 answers

How to write/read to FLASH on STM32F302

I am making a code using CubeIDE for a STM32F302K8UX and I need a variable to be persistent across resets. One way I have seen ppl doing it is by making a variable that is saved directly on flash memory (at least this is what I understood of it). I…
1
vote
1 answer

Does HAL_NVIC_SetPendingIRQ call the ISR to execute?

I am really new to STM32 world so I came across this while reading: void HAL_NVIC_SetPendingIRQ(IRQn_Type IRQn); This will cause the interrupt to fire, as it would be generated by the hardware. A distinctive feature of Cortex-M processors it that…
Tilak Sai
  • 21
  • 3
1
vote
1 answer

why 0x40010800 + 0x0C equals 0x40010830?

I tried to access RCC_APB2ENR register as a first step to blink green led on stm32nucleo f103rb then I added 0x0C to 0x40010800(RCC base address). The expected result was 0x4001080C but the actual result was 0x40010830!!! It seems 0x0C was left…
김정우
  • 23
  • 4
1
vote
0 answers

LED Blinks "Too" Fast @ NUCLEO-H755ZI-Q

Hi! According to the STM32H755ZI's manual RM0399, §9.5.6 (pg. 377), the default clock should be 64 MHz (HSI) after reset. Since the same code worked perfectly on other devices like e.g. a NUCLEO-F303K8, I expected the (red) LED to blink with 1 Hz.…
1
vote
1 answer

stm2cubeide - Access denied

I use stm2cubeide software for a course in my studies. I opened a new folder in the c:\users and installed stm2cubeide and a first program that I tried to run. When I try to build that project it shows the following error: Errors occurred during the…
Eitan Rosati
  • 543
  • 5
  • 18
1
vote
1 answer

What is use of RX and TX in ST-LINK/V2

I am using ST-LINK/V2. In this module we have 20 pins: Pin 4 RX Pin 6 TX What is the use of RX and TX Pins? Can I use those pins as serial communication(USART) pins? If it is not possible then what is the use of those pins?
1
vote
1 answer

How can I toggle two LEDs at difference frequencies using SYSTICK on keil for the ST32 processor

I want to toggle each LED one aT 4Hz and one at 3Hz, so far i can only toggle 2 at the same frequency.So far i can do them separately only but i dont know how to write to code to combine them so i can run it all at the same time. // THIS CODE IS FOR…
SHK
  • 11
  • 3
1
vote
1 answer

Read / Write a USB Stick with STM32F103C8

I'm trying to read/write data to a USB flash drive. I have read in the reference manual that STM32F103xx has a USB peripheral but can only act as a device in the communication. From what I understood, I need it to act as a host. Is there anyway to…
1
vote
0 answers

STM32F4xx phase shift of carrier wave (timers)

I just want to generate PWM signals for single phase cascade H bridge inverter. Theortically speaking, I need to shift carrier wave (triangular or sawtooth) in order to get sinusoidal PWM (see picture). I don't know how to obtain these shifted waves…
1
vote
1 answer

Can some constants be stored in .isr_table section? STM32F1 microcontroller

Background I have some microcontroller experience (Atmel AVR, PIC18, PIC32), but I'm pretty new in STM32. I need to maintain/refresh some old project written by another developer who for some reasons can't explain this code. Basically whole project…
Kamil
  • 13,363
  • 24
  • 88
  • 183
1
vote
1 answer

How do I display a 64bit unsigned integer with sprintf?

I'm displaying a 32bit timer value on my putty-console. The timer includes the time in microseconds since startup of my stm32wb55. With following code, it works exaclty like I want: uint32_t time_micro32 sprintf((char*)buf, "Time: %lu…
AnBa
  • 41
  • 7
1
vote
0 answers

STM32 UART multiprocessor mode with address mark detection. Intended data bytes are interpreted as address bytes

I have configured the UART for multiprocessor communication over RS485. I can receive and transmit data correctly. After waking up (RWU=0) when the correct address is received subsequent bytes should be received normally, and not interpreted as…
rub123
  • 51
  • 5