Your fputc
sends bytes directly to the UART, which goes to the RS232 connector on board. If you want to see the output of your fputc
, you need to connect a cable between the board and the PC and see it with a client such as hyperterminal.
When you talk about the trace capabilities, it generally means that the adapter (J-Link in your case) creates high throughput communication between the program and the debugger and follows the execution of the program. There are other debug functionalities. For example if you compile with semihosting, the program executes the system calls (_write
, _open
, ...) that are intercepted by the debugger that executes them on the host machine.
So in my experience either you call printf
, don't override the fputc
and compile with semihosting, and expect the output on the debug window, or you send to UART, connect the RS232 to the PC and see it on hyperterminal.
I see you found a third method which uses the trace capabilities. I believe the semihosting option is a more general solution because it can be applied also on a setup that doesn't have trace capabilities but just JTAG (or SWD) connection.