Printf on m52259evb

Hi, I’m new to the FreeRTOS and I’ve being working on using it with a m52259evb from Freescale.
Since on my company we won’t use ColdWarrior, I did some modifications so I could use the Demo files from the 52233 with the 52259 under eclipse. It took me a little time to get the hang of it but now I can turn the evb LEDS on and off (I know it might not sound much but I’m getting used to the board and FreeRTOS).
However, for a short period I used MQX and when I did a printf, I could see the output on a minicom terminal connected to the board serial port. I belive the same should happen with FreeRTOS, but I can’t get the printf to work (it compiles and all but nothing shows up).
I did copy the printf-stdargs.c from the 52259 demo project but still nothing.
Am I missing some sort of configuration? I’m kinda lost here. Thanks a lot
Ariel

Printf on m52259evb

I don’t know the specific platform, but usually onboard hardware modules (like the UART/USART you plan to use) need be configured for operation.
In the USART case things most probably needed are:
-sync/async
-parity
-stop bits
-baudrate
-module enabled/disabled Maybe check the mcu manual?

Printf on m52259evb

Also there *might* already be a configuration lingering from the original demo, but it might be wrong for the selected micro.

Printf on m52259evb

printf-stadarg.c is provided as a very light weight (in both code and RAM) alternative to standard library printf()/sprintf() functions. If you include it in your project it will replace the printf()/sprintf() that comes with your compiler. It is likely that the printf()/sprintf() that comes with your compiler has an option to direct its output to the UART already, if you look for it. If you use printf-stdarg.c then you have to do that yourself. They way to do it is set up a UART with the baud rate and other parameters as already suggested in this thread, then in printf-stdarg.c implement a putchar() to write the char to the UART. You will also have to remove the line “#define putchar(C) c” from the top of printf-stdarg.c, else your putchar() implementation will get #defined to nothing.