Community news, upcoming events and general discussions
Threads: 32 Posts: 82
Get technical support from the community
Threads: 1147 Posts: 6326
Threads: 16 Posts: 58
Tell us how to make XDK better!
Threads: 35 Posts: 117
Share and discuss community member projects
Threads: 53 Posts: 256
How can I save the conosle output to a .txt file from the Workbench?
I'm trying under debug configurations -> common but it this seems to only start the JTAG debugger and log output from there. I have the same issue with run configuration -> common.
Hello Brennan, Unfortunately, there is no option to redirect the console output from the XDK-Workbench to a file, while only using the options from the XDK-Workbench. To redirect the output, you would have to directly read the XDK's Virtual COM Port output. This could probably be done with a python script. The easiest way, at least on a Linux-based machine, would be to use the terminal command:
$ cat COM_PORT > log.txt
This basically redirects all traffic from COM_PORT to log.txt. According to this Stackoverflow Post the Windows terminal command:
type com1: >> log.txt
should do the same. The exact COM port you have to use (instead of com1 as seen in the command) is printed in the console when you connect the XDK to the PC. Keep in mind that you have to start the terminal command manually after the XDK's application started. Please tell me if this was helpful, and do not hesitate to ask further questions. Kind regards, Franjo