We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello!
I want to use "printf debugging" in my application. It is based on LPC1768 + JTAG, and I am using the RL-ARM.
I tried to include the <stdio.h> in my program and added the 'printf("Hello World\n");' statement. But when I run the program in debug mode, it 'goes into the weeds' as soon as it reaches 'printf' statement.
On the net, they say I should 'retarget' some stdio functions. Could please someone explain what does it mean, and how it is done?
P.S. As my tool does not support the SWD (what a shame! only JTAG) I can't use Serial Wire Viewer features and going to printf to UART.
Take a look at the following examples in MDK-ARM for LPC17xx which use printf to UART (includes retarget.c): - Keil\ARM\Boards\MCB1700\Blinky (without RTOS) - Keil\ARM\Boards\MCB1700\RTX_Traffic (with RTOS)