Skip to main content
ALeut.1
Associate II
July 30, 2022
Question

STM32F429I Discovery UART5 Data receive

  • July 30, 2022
  • 2 replies
  • 1563 views

Hello. According to the task of my project, I connect the GY-25 sensor to the STM32F429I Discovery board. The sensor consists of a gyroscope and an accelerometer, as well as a microcontroller that processes the raw data. After processing, the built-in microcontroller sends data in pulse blocks of 8 bytes. I configured the UART5 of the STM32F429I board to work with this sensor. Problem: Sending commands to the sensor is correct, but receiving - with errors. The output format of the sensor is 8 bytes of information, of which the first 0xAA and the last 0x55 are fixed, and the remaining 6 can take any value. Initially, I received data by the value of the flag, then switched to interrupts. Checking for start and stop bytes fails. Either the code received by the microcontroller is not correct, or the interrupt is not working. I am attaching a screenshot with UART5 settings. Isn't UART5 cut down or partially used somewhere else? I forgot to mention that I enable UART5 interrupts in the main program.

0693W00000QMWrjQAH.png

This topic has been closed for replies.

2 replies

Tesla DeLorean
Guru
July 30, 2022

It lacks support for synchronous clocking of data.

From an asynchronous data and interrupts it should function materially the same as other USART and UART.

Don't do excessively complicated tasks in the interrupt / callback routines.​

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
ALeut.1
ALeut.1Author
Associate II
July 30, 2022

In the interrupt procedure, I read data into a global array of 8 elements. The rest of the calculation is in the main program.