Operating System - HP-UX
1849839 Members
2355 Online
104044 Solutions
New Discussion

Remove garbage lines on print out header

 
tom quach_1
Super Advisor

Remove garbage lines on print out header

Dear all,


I'm using HPUX 11.11 with Panasonic dot matrix printer model KX-P3196

installed as dumbplot printer using jetdirect.

on the print out, it always has 4 lines below on its header.

12345X@PJL EOJ
12345x@PJL USTATUSOFF
@PJL INFO STATUS
@PJL USTAUS DEVICE-ON

does someone know how to remove these lines from the print out. i did switches from "with CR to without CR on the dumbplot and it worked before, but with these Panasonic, it did not work anymore.
Attached a print out report so you can see the the error.
Please help!
Thanks,
Tom



2 REPLIES 2
A. Clay Stephenson
Acclaimed Contributor

Re: Remove garbage lines on print out header

Those are Printer Job Language statements embedded in either the interface files or possibly in the application's data stream.

Cd to /var/spool/lp/interface and edit "myfile" where "myfile" corresponds to the queue name. Those statements should be in that file (or in a file of the same name in the model.orig directory just below /var/spool/lp/interface). Look for those statements and comment them out.

If they are in the applications data stream then the application needs to be changed or a filter (awk, Perk, sed, ...) added to the lp interface file to get rid of that stuff.
If it ain't broke, I can fix that.
Bill Hassell
Honored Contributor

Re: Remove garbage lines on print out header

The problem is with the hpnp.model parent script. It looks at a variable called DEVTYPE which is defined somewhere outside the script. The simplest way to remove the code is to change the printer's script in /etc/lp/interface. There is a line that runs the network program hpnpf. Just remove the variable $ONUSTATUS like this:

HPNPFOPT="-j $job+$user $TEOJ $TOJMON $ONUSTATUS $xPORT -x $PERIPH $HPNPFLOG $topazopt"
to
HPNPFOPT="-j $job+$user $TEOJ $TOJMON $xPORT -x $PERIPH $HPNPFLOG $topazopt"

That will prevent the PJL stuff.


Bill Hassell, sysadmin