2024-01-17 04:45 AM - edited 2024-01-18 02:54 AM
Hi there, using the callback function HAL_UART_ErrorCallback, I am receiving UART errors. However, what is odd is that handle->ErrorCode has 0 value always. That is, there is a mistake but no error code. I believe the STM32L431 UART driver contains a logical mistake.
2024-01-17 05:48 AM - edited 2024-01-17 03:04 PM
Please include your chip part number in your post.
Set a breakpoint in HAL_UART_ErrorCallback and look at the call stack to see where and why the error callback is being called.
2024-01-18 02:57 AM
Hi TDK thank you for response. I have attached the images for your reference in word file.
2024-01-18 06:22 AM
Yeah, you could be right. That's pretty complicated for me to trace the logic. But now that you know what happens, and that ErrorCode is cleared when you restart the transfer, you can use that info to find out what the error is and fix the issue.