Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [stm32]

The STM32 is the third ARM family by STMicroelectronics. It follows their earlier STR9 family based on the ARM9E core, and STR7 family based on the ARM7TDMI core. The STM32 is based on the ARM Cortex-M family of cores.

0
votes
0answers
6 views

ADC Performance analysis of STM32f401re Nucleo board

I am very new to STM32 and ARM MCU. I am trying to measure the ADC speed(conversion time) and noise of STM32. I know to calculate manually. I am trying to verify this. I am using TrueStudio IDE. Any ...
2
votes
2answers
96 views

What's the difference between a generated hex file and a binary file in embedded systems?

I have an STM32 project (let's call it blinky). This project is developed using Keil IDE. It blinks an LED every 1 second. When I build it, a HEX file is generated. Let's say I want to upgrade the ...
0
votes
1answer
32 views

STM32 Power connections question

When incorporating the STM32F7 MCU onto your own board design, is it necessary to connect supporting circuitry (analogue supply filtering etc) to the VDDA, VCAP pins if not using any of the analogue ...
1
vote
3answers
98 views

Microcontroller overheating when sensor is plugged in

I am building a board based around an STM32L051C6 microcontroller, which will measure a hall effect sensor (AH3362Q) and count the time in between the edges the sensor sees. The sensor is powered from ...
0
votes
3answers
72 views

STM32 ADC Input voltage

What happens to STM32F407 ADC if i give it an input voltage higher than maximum VDDA that is mentioned in datasheet equals to 3.6 volts? It will harm the micro?
1
vote
2answers
62 views

Minimum connections needed between stm32 MCU and the st-link programmer? [duplicate]

My MCU is stm32L432kc. I've concluded that we need a minimum of 4 connections: SWCLK, SWIO, vcc and gnd. Can someone from here confirm that? And another question is I'm confused how to connect the ...
0
votes
1answer
52 views

STM32 Ports Clock

Why do we need to ENABLE a GPIO clock by RCC_AHB register when we are using of that GPIO as a Peripheral Input/Output pin? For instance for STM32F407 ADC1, it has its own clock that can be enabled ...
-2
votes
1answer
30 views

Arduino STM32 bluepill generate PPM

does anyone knows is there a way to generate PPM (CPPM/PPMSUM) on STM32 Bluepill Arduino? Tnx in advance?
0
votes
1answer
51 views

STM32L476 Discovery ADC output is not changing even though the input voltage is

The output value of the ADC seems to flicker between 539-549 (in a range of 0-4095) no matter what voltage is on the input pin. The voltage on the input is usually between 0V - 4V. This might be a ...
0
votes
0answers
20 views

STM32H7 DMA2D MEM2MEM rectangle coordinates

Question: how do I specify rectangle copy parameters of source (x1, x2, width, height) and destination (x2, y2) buffer using DMA2D registers, in memory to memory mode? My problem is that I cannot ...
0
votes
0answers
24 views

STM32F072 TIMER PWM + DMA : Not working as expected

I am using TIMER2 + CHANNEL 2 PWM to generate 800 Khz wave. The idea is to vary the duty cycle of this wave as per a statically generated pixel bit array (1 SK6812 pixel = 32 bit GRBW = 32 bytes of ...
0
votes
1answer
40 views

Compiler error when using HAL functions for I2C communication

I am using the board STM32F3 and I am trying to establish I2C communication between the microcontroller and the accelerometer LSM303DLHC by using the HAL functions. This is the code: ...
1
vote
2answers
68 views

SPI using STM32's DMA sends one word too much

On an STM32F103 I configure SPI in 16bit wide mode and set up a DMA transfer to transmit one byte: ...
6
votes
1answer
588 views

Inaccurate timer interrupt STM32

I wrote a simple program to toggle an LED on and off using the TIM1 interrupt on an STM32F0 discovery board. CLK Freq = 48MHz Prescalar = 48000 Auto Reload Register = 1000 Using the following ...
0
votes
1answer
33 views

STM32F091 timer as a prescaler for another timer

I would like to chain two 16-Bit timers to each other to make a 32Bit timer. Just like the example in the datasheet [RM0091 figure 147 page 429] but with different timers. I found these two sites: ...
0
votes
0answers
30 views

stm32f030 and ad9833

There are a lot of examples how to make sine generator with arduino. Use ATMega 328, AD9833 and that's OK. My project use STM32F030 and AD9833. I prefer to use HAL and in this case don't use crystal ...
0
votes
1answer
45 views

GPIO connected as open-drain to opto-isolator's cathode

When connecting GPIO output pins (RPi, uC, ...) to an opto-isolator, the classical way I know is the following (at least I understand that it can roughly be depicted like that): simulate this circuit ...
0
votes
2answers
68 views

Generate and flash a binary file for STM32

I created a bootloader image for my STM32 and I stored it in a specific area of the memory. I have a new Keil project which represents the application layer. By default, Keil generates a HEX file. ...
3
votes
3answers
89 views

STM32 CAN bus receive interrupt is sometimes not fired, and CAN transmit sometimes times out

I have two STM32 boards connected via a CAN bus. They periodically transmit a message to each other. For some transmissions however, HAL_CAN_Transmit returns with ...
0
votes
0answers
55 views

Can I use PICKIT3 instead of STLINK for programming STM32F103C8?

Can I use PICKIT3 for programming STM32F103C8 instead of STLINK ?
0
votes
0answers
37 views

Injected adc2 channel combined with regular channels adc1 dma stm32f103

I have 7 adc channel must be measured. 4 channels are continuously measured by dma and adc 1, 3 of them are very important measured in special moment. I want to mesured this channels by injected ...
1
vote
1answer
118 views

What is HAL_SPI_TransmitReceive purpose and how it works

I am trying to understand how does this function works even though there are so many people complaining about it. My questions are these: 1) What is the difference between using this in my code: <...
3
votes
0answers
110 views

STM32F103C8T6 fake?

I have a curious problem: Prequel: I "designed" a clone of the Black Magic Probe v2.1, which I like a lot but has IMHO some shortcomings (e.g. the 1.27mm-pitch connector to name just one). I got a ...
0
votes
0answers
37 views

STM32F429 SPI issue

I am trying to get SPI working on STM322F429-disco board. Here is the setup: SPI2 is setup as a master with Soft NSS and SSOE enabled. GPIOG Pin11 is being used manually for Chip select. SPI4 is ...
0
votes
1answer
92 views

Small microcontroller with USB host peripheral [closed]

I'm trying to find microcontroller with low pin coutn that has USB host capabilities. I know this can be done with big PIC24 or PIC33 microcontrollers, but I wonder if there are others chips that ...
0
votes
1answer
112 views

STM32L011 jump to bootloader from user code

I'm trying to make it so that my STM32L011 can jump from user code to the ST bootloader that allows flash to be reprogrammed over USART2. This is hypothetically the same question as STM32F091 Jump to ...
0
votes
1answer
50 views

Reading STM32F timer value

I am trying to implement a hardware timer for STM32F and read the value from it. So far, this is my implementation: ...
0
votes
1answer
81 views

Call member function from interrupt in STM32 [closed]

I have created a new STM32 project using cube. I have changed main.c to main.cpp and enabled ...
1
vote
0answers
61 views

STM32F4 ADC oscillating

I am trying to read the ADC of a STM32F4. The code skeleton was generated by CubeMX, the HAL library is used. The read values are feasible but have periodic noise, as seen here: The plot was ...
-1
votes
1answer
105 views

Voice encryption over TRRS headphones

-- Edit 2 --- This question is different from Connect STM32 BLUEPILL to the TRRS connector on the computer But just in case for not falling into double posting I deleted that post. (This post hes ...
0
votes
1answer
43 views

Evaluation A/D and D/A converter

If I need to read and write data over TRRS to and from headphone (i.e. I read from standard (iphone/galaxy) headphone mic. and write to standard headphone earphones). This is a schema of what I want ...
0
votes
1answer
55 views

strange RFM95 SPI behaviour with STM32L4 [closed]

I am using CubeMX and HAL to program an STM32L4. I am trying to communicate with RFM96 module using SPI, but I am getting nonsensical results. According to the RFM96 datasheet, in order to read a ...
0
votes
1answer
56 views

Deal with DC offset

I have STM32 BluePill and Teensy 3.2 , they both read analog 0 < x < 3.3V. I want to read earphone microphone sound but the mic produce +-2.5V (with ~200mA, but this is a different problem). ...
0
votes
1answer
75 views

STM32 STUtility read out protection

I developed some hardware with an STM32F4 and firmware and want now to protect the firmware as good as possible when the product goes out. Since I use two flash sectors for virtual EEPROM memory, I ...
2
votes
2answers
81 views

Just read a Register

I am using a STM32F103CBT6 as I2C Master. After sending the I2C Adress of the Slave I need to clear the Addr bit in the SR1 register. The Datasheet states: "ADDR: Address sent (master mode)/matched (...
1
vote
2answers
74 views

Program FPGA using STM32

I am interested in using an STM32 to flash an sof or pof file onto a Cyclone IV FPGA. The sof/pof will be stored in SPI flash memory, and the plan is to use the STM32 as a programmer. I haven't been ...
1
vote
2answers
154 views

Combine C and C++ in STM32 application development [closed]

Generally, developing embedded systems applications is based on abstraction. We expose some functions from lower layers that can be used in the application layer. My question is: Can I develop the ...
0
votes
1answer
56 views

STM32F030F4 Timer3 doesn't work

I use STM32F030F4 in TSSOP-20 package and the timer doesn't work. I try to find an example for STM32F103 and it work very good. Here is the code sample that I use: ...
2
votes
1answer
78 views

STM32 cant get DMA on PWM

I wish to drive a set of NEOPIXELS (ws2812b) using the STM32F4 discovery board, so far i managed to get a 800 kHz PWM signal using the CubeMX. And And the following code: ...
0
votes
0answers
37 views

Microchip MRF24WN0MB datasheet for use in STM32

We have designed a board where a Microchip MRF24WN0MB WiFi is connected to an STM32L082 ARM micro-controller through SPI. I can generate code with STM32CubeMX (compiled with Eclipse SW4STM32) and run ...
0
votes
2answers
63 views

Why is buffer received over USB is not aligned on transmitted buffer length?

I stream some data from STM32H7 USB (VCP) -> to PC, and after stream is finished I just send "end\0". And on PC side I just look at the start of received data block and if there is "end\0", I just ...
0
votes
1answer
32 views

stm32 uart issue serial monitor vs logic analyzer

I am writing data serial monitor via hal_uart_transmit and it works fine, but when I monitor same serial bit pattern in logic analyzer I see extra two bits have the logic high state, why is that? for ...
-1
votes
0answers
74 views

STM32 I2C communication hangs

I'm currently try to use the MS5611 pressure sensor (sitting on a CJMCU-117) over I²C with libopencm3 on a STM32F103C8. Since the i2c_transfer7() of libopencm3 ...
1
vote
2answers
157 views

STM32 ADC+DMA occurring only once

I'm trying to poll the value of the ADC and store it in a variable using DMA but the variable store the value of the ADC1->DR only once(when the program start). ...
1
vote
1answer
99 views

Stm32f103 blue pill and stlink power

When two or more of these modules have their 5v pins hooked up to a common 5v rail (power off) and I connect an 4-pin SWD st-link to the programming pins of one, I'm finding that all modules (and ...
0
votes
1answer
61 views

STM32F411VE ADC interrupt not working

My code works fine without interrupt (I tried polling the ADC value) but when I enabled the interrupt, it didn't work - while debugging in Keil, it never reaches the ...
0
votes
1answer
54 views

Understanding parts of this BLDC driver schematic

I have a couple of question on ST's STSPIN32F0A 3-phase BLDC driver and I was hoping someone can help me figure out some parts of the schematic. The schematic shows the STSPIN32F0A (pg. 1) connected ...
-2
votes
1answer
87 views

Why do people say STM32Cubemx is full of bugs? [closed]

I have worked with stm32cubemx for 2 years now, and I have found on forums people have mentioned that stm32cubemx is full of bugs? Why is that?
-2
votes
1answer
93 views

How to read temperature with STM32F103C8T6? [closed]

How can I read the temperature using an NTC thermistor with an STM32F103C8T6 board??
0
votes
1answer
171 views

UART - Writing and reading AT commands

I am working with a B-L072Z-LRWAN1 board and a 8pya00-simcom-evb v1.02 board with SIM7000E. This SIM module operates through AT commands and I need to send these commands through an UART connected ...