2021-02-12 7:29 PM - last edited on 2025-10-27 6:57 AM by Andrew Neil
Dear All,
So, i have just implemented Uart receive as an interrupt on the stm32f401re board using the HAL library in STM32cube ide.
I have failed to process characters when they are more than one.
Any advise for me, i will be glad.
Solved! Go to Solution.
2021-02-13 1:23 AM
Should we try to guess what you did in the failing case? Or the type of messages and test cases?
As you fill a buffer with each byte as it arrives under interrupt make a determination if you have completed the message or reached the end of line case. If using as strings NUL terminate the buffer before processing.
2021-02-13 1:23 AM
Should we try to guess what you did in the failing case? Or the type of messages and test cases?
As you fill a buffer with each byte as it arrives under interrupt make a determination if you have completed the message or reached the end of line case. If using as strings NUL terminate the buffer before processing.
2021-02-13 1:55 AM
Thank you @Community member for this advice, Let me give my best shot ot it.
2021-02-14 7:19 PM
hello @Community member , this an appreciation note to you. After your previous response to my post, i searched further on this community , where am still new and came across your piece code your previously shared where you reading 1 byte at a time handling the Nmea sentence. I have borrowed it and implemented it on my end and its working for me well. Thank you.