Summary: Filters for mode select on HP LaserJet 5SiMX

From: Shiu Tin <shiu_at_rsphy1.anu.edu.au>
Date: Wed, 9 Jul 1997 13:03:00 +1000 (EST)

Original Message:

>
> We have just acquired a HP LaserJet 5SiMX printer with HP Jetdirect card.
> We have setup to print to it on the OSF systems using cap and is
> trying to setup a script to select various mode for the print job
> such as trays, duplex printing etc. We tried to extract the PS
> code required to select mode on the printer from HP with no success.
> HP (at least the one from Australia) will not supply the information
> and their jetadmin software only supports Sun and HPUX.
>
> My question is:
>
> Has anyone managed to extract the appropriate code necessary to select
> modes (including tray, duplex etc) on the HP LaserJet 5SiMx printer
> or know where or how to obtain the necessary information?
>

The simplest solution for us is to insert the appropriate postscript
commands as supplied by Nick Hill to the postscript document. We
are setting a script to do just that.

Thanks to:
Kimble Britten Webb
Nick Hill
Lewis L. Lasser

The following are the replies received:
--------------------
From: Kimble Britten Webb <kimble_at_maths.unsw.EDU.AU>

look at the lprng package & CTI filters

The software may be obtained from
   ftp://dickory.sdsu.edu/pub/LPRng (Main site)
   ftp://ftp.iona.ie/pub/plp/LPRng
   ftp://ftp.cs.umn.edu/pub/LPRng
   ftp://gwynne.cs.ualberta.ca/pub/LPRng
   ftp://ftp.informatik.uni-hamburg.de/pub/os/unix/utils/plp/LPRng
   ftp://ftp.uni-paderborn.de/pub/unix/printer/plp/LPRng
   ftp://ftp.beckman.uiuc.edu/pub/plp/LPRng
   ftp://ftp.zod.wau.nl/pub/mirror/plp/LPRng
   ftp://ftp.lps.ens.fr/pub/software/plp/LPRng


To join the LPRng/PLP mailing list, please send mail to
  lprng-request_at_iona.ie
with the word 'subscribe' in the BODY


that maybe of some use
        kimble.

--
Kimble Webb                                  kimble_at_maths.unsw.edu.au
School of Mathematics                        ph:  +61 (2) 9385-3238
University of New South Wales NSW 2052       fax: +61 (2) 9385-1071
Australia
------------------
From: Nick Hill - RAL DCI Systems Group <NMH1_at_axprl1.rl.ac.uk>
There are various ways to do this as you can imagine. However it is pretty 
straight forward and not a great mystical art to do this. 
The printers have a  printing language independant job control language (PJL)
which can do various things. If you look at any print files from HP windows
drivers you will see lines like "<ESC>%-12345X_at_PJL bla bla" which are PJL
commands. Then there are ways of doing what you want in both PCL and
PostScript.
I do not have a 5Si but have various 4Si printers and I don't believe at this 
level they will be any major differences. In the 4Si User Reference Manual 
that cam withe the printer there are various PJL listed in one of the 
appandices.  If you want the full set of PJL commands then you need to get the
manual from HP. My 4Si manual claims it is called the Printer Job Language
Technical  Reference Manual which comes as part of the PCL Technical Reference
Docs  package. The PCL and PostScript commands to do what you want are also in
the appendices. If you want more examples of how to use the PostSvript 
commands then get the postscript printer description file (PPD) for the 5Si 
from which you can copy the sectrions of PostScript code that you require. 
You can get usually get these from the HP web site of from the Adobe web or 
ftp site. 
The 5Si printers are PostScript level 2 so there are various advanced level 2 
functions to do all sorts of page setup features. If you just want to set 
duplex/simple mode and tray selection there are some very basic commands you 
can use. 
Simplex or Duplex mode is set as follows:
statusdict begin false setduplexmode end 
or
statusdict begin true setduplexmode end 
Tray select
statusdict begin <number> setpapertray  end 
number=0 for upper tray
number=1 for lower tray
There are also commands for named paper sizes such as lettertay, legaltray, 
a4tray etc
You just send them to the printer before the PostScript file to be printed. 
There is however one thing you must remember. These settings are per job and 
get canceled at the end of a print job. You must therefore make sure there is 
no <cntrl>D at the start of the PostScript file to print as this will be seen 
by the printer as EOJ. For example if the printer is set default to simplex 
printing then you sending:
%!
statusdict begin true setduplexmode end 
to the printer first will switch it to duplex. (The %! tells the printer that 
you are going into PostScript mode if you have autoswitching enabled) You then
send the users PS file which starts
^D
%!PS-Adobe
bla
bla
which will print simplex as the ^D at the start cancels out your duplex
commands. Many PC print drivers put the ^D in at the start to clear the printer
to a known state first. However this can be turned off in some cases but you
may need to guard against it.
Have fun,
Nick Hill
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
DCI, Rutherford Appleton Laboratory,                  Tel: +44 (0)1235-445598
Chilton, Didcot, Oxon, OX11 0QX, England.             Fax: +44 (0)1235-446626
N.M.Hill_at_rl.ac.uk            http://www.cis.rl.ac.uk/people/nmh1/contact.html
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-------------
From: Lewis L. Lasser <lewis_at_dmi.stevens-tech.edu>
We have recently purchased a duplexing option for our HP LaserJet 5M
  (uses a jetdirect card).
I have successfully inserted the following piece of code into several
  documents to get double sided output
	[{
	  << /Duplex true /Tumble false >> setpagedevice
	 } stopped cleartomark
I don't know where to officially find this type of information (but
  would love to know ...); to obtain this code i had my officemate
  produce a double-sided document in ms word - i then scanned the
  document looking for anything promising.
I hope this code fragment works.
If you find out anything interesting let me know.
					lew
					lewis_at_dmi.stevens-tech.edu
---------------------
Received on Wed Jul 09 1997 - 05:11:58 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:36 NZDT