AnsweredAssumed Answered

STM32F0-disco printf USART

Question asked by Alexandre Poincet on May 23, 2018

Hi, I'm working with the STM32F0 Discovery board.
I have a problem to use printf function with the USART.

I'm using the classical way to redirect printf function (redefine _io_putchar and added _write function).
So printf works great when I use the IDE to compile and flash (I use SW4ST32).

But when i try to compile and flash in command line using the same commands as the IDE, the printf function does nothing. The _write function works but is not called by printf.
To compile in command line i get all the .o files generated by the IDE and i compile the main file and then link everything together.


So my question is, What could be the reason for printf to not call the _write function ?