Hello
You can find some documentation on how to redirect terminal output to a file in the Debugger_HC12.pdf manual.
Look at Book II HC(S)12(X) Debug Connections > HC(S)12(X) Full Chip Simulation > FCS Visualization Utilities > Terminal component.
There is a section File Control Commands explaining how to use escape sequences to redirect stdout to a file.
All you need to do call TERM_Direct with appropriate set of parameters from your main application.
CrasyCat