To redirect stdout or stderr, use an override command, e.g.
OVRPRTF STDERR QSYSPRT
To see the STDOUT and STDERR after they've flashed on the screen, I have a little command called DSPSTDOUT:
Here's the command:
CMD PROMPT('Display stdout')
Here's the CPP for the command. It must be in activation group *NEW:
H dftactgrp(*no) actgrp(*NEW) bnddir('QC2LE')
D printf pr extproc('printf')
D msg 2a const
D newline C X'1500'
C callp printf(newline)
C return
Barbara Morris