tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* SUMMARY: Printer escape commands in postscript
@ 2002-04-08 13:22 Myszkowski.Mark
  0 siblings, 0 replies; only message in thread
From: Myszkowski.Mark @ 2002-04-08 13:22 UTC (permalink / raw)
  To: tru64-unix-managers

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: multipart/mixed; boundary="------_=_NextPart_001_01C1DF00.5DED6E80", Size: 10423 bytes --]

This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.

------_=_NextPart_001_01C1DF00.5DED6E80
Content-Type: text/plain;
	charset="iso-8859-1"

My original message is below.  Thank you very much to everyone who
responded.  Richard's message gave us the info that we needed.

-----Original Message-----
From: Richard xxxx
Sent: Friday, April 05, 2002 4:10 PM
To: Myszkowski.Mark
Subject: Re: Printer escape commands in postscript


The problem is that PostScript will reset the tray and you must put the 
command in the PostScript file being sent to the printer like so:

	% for the LaserJunk4, the trays are as follows:
	%
	%	tray 0 = upper cassette
	%	tray 1 = lower cassette
	%	tray 2 = optional envelope feeder
	%	tray 3 = multipurpose tray
	%
	statusdict begin
	%
	% say this for lower tray
	%
	1 setpapertray
	%
	% say this for upper tray
	%
	0 setpapertray
	end
	...

Moset of the above is comments so you really need only three lines:

	statusdict begin
	1 setpapertray
	end

That you need to stuff in near the beginning of the PostScript file
before "EndProlog".  This may be easy or it may not be, we do it here with 
gnu troff jobs using Perl but it could also be done with sed.

  Richard Loken VE6BSV, Systems Programmer - VMS   : "...underneath those 
  Athabasca University				   : tuques we wear, our
heads
  Athabasca, Alberta Canada			   : are naked!"
  ** tech@cs.athabascau.ca **                      :    - Arthur Black



  Richard Loken VE6BSV, Systems Programmer - VMS   : "...underneath those 
  Athabasca University				   : tuques we wear, our
heads
  Athabasca, Alberta Canada			   : are naked!"
  ** tech@cs.athabascau.ca **                      :    - Arthur Black



___
    This communication is intended for the use of the recipient to whom it
    is addressed, and may contain confidential, personal, and or privileged
    information. Please contact us immediately if you are not the intended
    recipient of this communication, and do not copy, distribute, or take
    action relying on it. Any communications received in error, or
    subsequent reply, should be deleted or destroyed.
---

We would like to send commands like 

<ESC>&l2A      (for letter)
<ESC>&l1H      (for upper tray)
<ESC>&l4H      (for lower tray)

to a postscript printer queue like this:

lp536|pedc0961ps|pedc0961ps:\    
        :lf=/usr/adm/lp536err:\  
        :lp=:\                   
        :rm=pedc0961:\           
        :rp=hpstream:\           
        :sd=/usr/spool/lpd536:

Right now the command sequences are ignored but if I change the "rp" value
to "text" then they work fine.  We need this to be a postscript queue
however.  How can we control the tray if the queue is setup for postscript?

Thank you very much,

Mark Myszkowski
mark.myszkowski@wepco.com

------_=_NextPart_001_01C1DF00.5DED6E80
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2653.12">
<TITLE>SUMMARY: Printer escape commands in postscript</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=3D2>My original message is below.&nbsp; Thank you very =
much to everyone who responded.&nbsp; Richard's message gave us the =
info that we needed.</FONT></P>

<P><FONT SIZE=3D2>-----Original Message-----</FONT>
<BR><FONT SIZE=3D2>From: Richard xxxx</FONT>
<BR><FONT SIZE=3D2>Sent: Friday, April 05, 2002 4:10 PM</FONT>
<BR><FONT SIZE=3D2>To: Myszkowski.Mark</FONT>
<BR><FONT SIZE=3D2>Subject: Re: Printer escape commands in =
postscript</FONT>
</P>
<BR>

<P><FONT SIZE=3D2>The problem is that PostScript will reset the tray =
and you must put the </FONT>
<BR><FONT SIZE=3D2>command in the PostScript file being sent to the =
printer like so:</FONT>
</P>

<P>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>% for the =
LaserJunk4, the trays are as follows:</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>%&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; tray 0 =3D upper =
cassette</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>%&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; tray 1 =3D lower =
cassette</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>%&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; tray 2 =3D optional =
envelope feeder</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>%&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; tray 3 =3D multipurpose =
tray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>statusdict begin</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>% say =
this for lower tray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>1 =
setpapertray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>% say =
this for upper tray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>%</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>0 =
setpapertray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>end</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>...</FONT>
</P>

<P><FONT SIZE=3D2>Moset of the above is comments so you really need =
only three lines:</FONT>
</P>

<P>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>statusdict =
begin</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=3D2>1 =
setpapertray</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT =
SIZE=3D2>end</FONT>
</P>

<P><FONT SIZE=3D2>That you need to stuff in near the beginning of the =
PostScript file</FONT>
<BR><FONT SIZE=3D2>before &quot;EndProlog&quot;.&nbsp; This may be easy =
or it may not be, we do it here with </FONT>
<BR><FONT SIZE=3D2>gnu troff jobs using Perl but it could also be done =
with sed.</FONT>
</P>

<P><FONT SIZE=3D2>&nbsp; Richard Loken VE6BSV, Systems Programmer - =
VMS&nbsp;&nbsp; : &quot;...underneath those </FONT>
<BR><FONT SIZE=3D2>&nbsp; Athabasca University&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; : tuques we =
wear, our heads</FONT>
<BR><FONT SIZE=3D2>&nbsp; Athabasca, Alberta =
Canada&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; : are =
naked!&quot;</FONT>
<BR><FONT SIZE=3D2>&nbsp; ** tech@cs.athabascau.ca **&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :&nbsp;&nbsp;&nbsp; - Arthur =
Black</FONT>
</P>
<BR>
<BR>

<P><FONT SIZE=3D2>&nbsp; Richard Loken VE6BSV, Systems Programmer - =
VMS&nbsp;&nbsp; : &quot;...underneath those </FONT>
<BR><FONT SIZE=3D2>&nbsp; Athabasca University&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; : tuques we =
wear, our heads</FONT>
<BR><FONT SIZE=3D2>&nbsp; Athabasca, Alberta =
Canada&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; : are =
naked!&quot;</FONT>
<BR><FONT SIZE=3D2>&nbsp; ** tech@cs.athabascau.ca =
**&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:&nbsp;&nbsp;&nbsp; - Arthur Black</FONT>
</P>
<BR>
<BR>

<P><FONT SIZE=3D2>___</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; This communication is intended =
for the use of the recipient to whom it</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; is addressed, and may contain =
confidential, personal, and or privileged</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; information. Please contact us =
immediately if you are not the intended</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; recipient of this communication, =
and do not copy, distribute, or take</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; action relying on it. Any =
communications received in error, or</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp; subsequent reply, should be =
deleted or destroyed.</FONT>
<BR><FONT SIZE=3D2>---</FONT>
</P>

<P><FONT SIZE=3D2>We would like to send commands like </FONT>
</P>

<P><FONT SIZE=3D2>&lt;ESC&gt;&amp;l2A&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
(for letter)</FONT>
<BR><FONT SIZE=3D2>&lt;ESC&gt;&amp;l1H&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
(for upper tray)</FONT>
<BR><FONT SIZE=3D2>&lt;ESC&gt;&amp;l4H&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
(for lower tray)</FONT>
</P>

<P><FONT SIZE=3D2>to a postscript printer queue like this:</FONT>
</P>

<P><FONT SIZE=3D2>lp536|pedc0961ps|pedc0961ps:\&nbsp;&nbsp;&nbsp; =
</FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:lf=3D/usr/adm/lp536err:\&nbsp; </FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:lp=3D:\&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:rm=3Dpedc0961:\&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp; </FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:rp=3Dhpstream:\&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp; </FONT>
<BR><FONT SIZE=3D2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
:sd=3D/usr/spool/lpd536:</FONT>
</P>

<P><FONT SIZE=3D2>Right now the command sequences are ignored but if I =
change the &quot;rp&quot; value to &quot;text&quot; then they work =
fine.&nbsp; We need this to be a postscript queue however.&nbsp; How =
can we control the tray if the queue is setup for =
postscript?</FONT></P>

<P><FONT SIZE=3D2>Thank you very much,</FONT>
</P>

<P><FONT SIZE=3D2>Mark Myszkowski</FONT>
<BR><FONT SIZE=3D2>mark.myszkowski@wepco.com</FONT>
</P>

</BODY>
</HTML>
------_=_NextPart_001_01C1DF00.5DED6E80--

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-04-08 13:22 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-08 13:22 SUMMARY: Printer escape commands in postscript Myszkowski.Mark

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox