cancel
Showing results for 
Search instead for 
Did you mean: 

uart data mismatch

TejasK
Associate III

I am using stm32f407 and stm32wb series for sending the data usimg uart.
first i send th data using the stm32wb uart to the stm32f407 uart the data is correctly sent.

After receiving the data i will return the data back to the stm32wb from the stm32f407 but this time the data is corrupted.

I am using the hal_uart_receiveto_idle and hal_uart_transmit_it to send and receive the data. 

I will share the code please review and tell me if i need to make any changes.

10 REPLIES 10

@TejasK wrote:

I have not tested using the oscilloscope or logic analyser. 


You really need to do that!

Otherwise, there's no way to tell if the problem is in the receiver, or the transmitter - or both!

 

Here's some tips specifically on Debugging Serial Comms

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.