cancel
Showing results for 
Search instead for 
Did you mean: 

UART on STM32F411VET6 (Discovery)

Đạt
Visitor

I am starting to experiment with stm32f411vet6 (discovery), I have passion for STM32, looking forward to learn and help.

When I turn on UART 6 and test, the default pins are PA9 and PA10, however it doesn't work (some error characters like question mark appear and don't work anymore). However when I switch PA9 and PA10 to PB3 and PA15, UART 6 works fine.

I tried setting PA9 and P10 with output feature then PA9 and PA10 work properly. So what are the possibilities why PA9 and PA10 don't work with UART mode? And how to test it?

Thanks!

3 REPLIES 3

Welcome to the forum.

For best results, please see: How to write your question to maximize your chances to find a solution.

 

Here are some STM32 getting started tips:

https://community.st.com/t5/stm32-mcus-products/for-better-learning-stm32-programming-and-debugging/m-p/719468/highlight/true#M260690

 


@Đạt wrote:

When I turn on UART 6 and test, the default pins are PA9 and PA10, however it doesn't work (some error characters like question mark appear and don't work anymore).!


How, exactly, do you observe this?

The commonest reason for "junk" characters is wrong baud rate:

https://learn.sparkfun.com/tutorials/serial-communication/all#:~:text=If%20all%20the%20receiving%20device%20sees%20on%20its%20receive%20line%20is%20garbage%2C%20check%20to%20make%20sure%20the%20baud%20rates%20match%20up

Other parameters (eg, frame size) must also match.

Chris21
Senior II

PA9 and PA10 may be used for some purpose on the Disco board, review the schematic / user manual.

Karl Yamashita
Principal

PA9 and PA10 are connected to the USB circuitry. When working with development boards, you need to make sure the pins you are using are not connected to other circuitry.

 

KarlYamashita_0-1744070445722.png

 

 

Don't worry, I won't byte.
TimerCallback tutorial! | UART and DMA Idle tutorial!

If you find my solution useful, please click the Accept as Solution so others see the solution.