HP PCL/PJL reference - Printer Job Language Technical Reference Manual
EN Status Readback Commands 7-43
Job Recovery
PJL provides job recovery capability using the following combination
of commands:
• The JOB and EOJ commands are used to reset the page
count and inform the printer of the boundaries for the job—its
beginning and end.
• The USTATUS PAGE command is used to determine how
many pages are completely printed.
If you must reprint a portion of a job, the spooling application can
re-issue the job using the START option to specify the remaining
portion of the job.
The following PJL job shows an example that provides job recovery if
a problem occurs. Notice that the USTATUS JOB and USTATUS
PAGE commands are sent prior to the JOB command. If a power
failure or another problem interrupts the job, the unsolicited page
status indicates the last completely printed page.
Note The USTATUS JOB command is not strictly required for job recovery.
However, it is useful for tracking jobs by name, not just page number.
The following example uses the command to show the difference
between the page count returned by the unsolicited job status and the
unsolicited page status.
Sending the Initial Job
<ESC>%-12345X@PJL <CR><LF>
@PJL COMMENT Providing for Recovery <CR><LF>
@PJL USTATUS JOB = ON <CR><LF>
@PJL USTATUS PAGE = ON <CR><LF>
@PJL JOB NAME = "1st Shot" <CR><LF>
@PJL ENTER LANGUAGE = PCL <CR><LF>
<ESC>E ... 100-page PCL job ... <ESC>E
~<ESC>%-12345X@PJL <CR><LF>
@PJL EOJ NAME = "End of 1st Shot" <CR><LF>
<ESC>%-12345X