This section covers redirection and pipes. You can use these features to change how TCC-RT and some application programs handle input and output.
Internal commands and some external programs get their input from the computer's standard input device and send their output to the standard output device. Some programs also send special messages to the standard error device. Normally, the keyboard is used for standard input and the video screen for both standard output and standard error, but you can temporarily change these assignments for special tasks.
For example, suppose you want a printed list of the files in a directory. If you change the standard output to the printer and issue a DIR command, the task is easy. DIR's output goes to the standard output device, and you have redirected standard output to the printer, so the DIR command prints filenames instead of displaying them on the screen. You can just as easily send the output of DIR (or any other command) to a file or a serial port.
Redirection and piping affect the standard input, standard output, and standard error devices. They do not work with application programs which read the keyboard hardware directly, or which write directly to the screen. Because most Windows applications fall into that category, you will find that redirection and piping are most useful when they are combined with internal commands.
The PEE, TEE and Y commands are "pipe fittings" which add more flexibility to pipes.
TCC's output is normally in ANSI. If you want to redirect output in Unicode, you need to either use the /U startup option in TCC, or the Unicode Output option in TCMD.INI.