2023-10-30 3:37 AM
Hello,
I'm struggling with a really strange issue. I'm trying to make UART RX working on a STM32G4 custom board.
I've followed the UART Interrupt tutorial. (https://wiki.st.com/stm32mcu/wiki/Getting_started_with_UART)
I've tested it with Nucleo-G431RB and it works fine.
Now I'm running the exact same code on my custom board and I have nothing, when using the debugger I can see that the interrupt is never fired. I've check hardware connections and everything seems OK.
I've also tried to implement UART_Receive by polling mode => I can see in the debugger that characters are received, so Hardware is OK.
Can someone help me with this issue ?
Thanks
Solved! Go to Solution.
2023-10-31 10:17 AM
Why ST couldn't have used a symbol for the vector table basis into SCB->VTOR is honestly beyond me...
2023-10-31 1:14 PM
Your code you've posted is working on my Nucleo-G431B just fine.
With the exception is that you should use strlen instead of guessing the length of the string. I was getting some null characters when i sent SONAR.
Also remove the flag as i was getting double "msg_available"
Now you're probably wondering why I was able to get your code to work? I saw the link to the tutorial and nowhere did it mention to enable the NVIC interrupt. How ST left that vital information out is beyond me?
We’re moving the ST Community to a new platform to give you a better and more reliable community experience.