Skip to main content
Associate III
November 25, 2024
Solved

USART3 selection disabled in CubeMx

  • November 25, 2024
  • 1 reply
  • 2606 views

I need UART to use printf, but it's showing as disabled. How can I enable it, and I also need an example code for printf.

 

syedhashmiraza_0-1732538343982.png

 

Best answer by mƎALLEm

If you pass the mouse on USART3, you will get the warning and the information about the issue:

SofLit_0-1732540636778.png

There are IO conflicts with FMC or/and LTDC.

So you need to go to the pinout view and type USART3. All USART3 pins will toggle. Then select the pin that you need to use for UART3.

SofLit_1-1732540915673.png

Attached a project where I configured USART3 on PB10 and PB11.

But becarefull, for this discovery you need to use USART1 not USART3 over STLINK Virtual comport as said in this thread for printf:

https://community.st.com/t5/stm32-mcus-embedded-software/how-to-use-printf/td-p/733254

And if you need to use USART3 you need to check the HW and manage the conflicts on the board by referring to the schematics.

Hope that answers your question.

 

1 reply

mƎALLEm
Technical Moderator
November 25, 2024

Again, please put a correct title for your posts. "uart" doesn't make any sense.

For your question: Look at the warning. It seems there is a GPIO conflict between USART3 and something else ..

Please share your ioc file.

"To give better visibility on the answered topics, please click on ""Accept as Solution"" on the reply which solved your issue or answered your question."
Associate III
November 25, 2024

hello iam using stm32f429i-disc1 in this how to enable usart1?

syedhashmiraza_0-1732539504339.png

 

mƎALLEm
Technical Moderator
November 25, 2024

I've already said there is a conflict in your config and I've requested to share your ioc file. 

 

"To give better visibility on the answered topics, please click on ""Accept as Solution"" on the reply which solved your issue or answered your question."