HP3000-L Archives

December 1995, Week 5

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
John Clark <[log in to unmask]>
Reply To:
John Clark <[log in to unmask]>
Date:
Sat, 30 Dec 1995 03:03:48 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (90 lines)
On Friday, 28 Dec Eric Popish wrote:
 
>Date:    Fri, 29 Dec 1995 11:22:51 -0700
>From:    Eric Popish <[log in to unmask]>
>Subject: Printing Signatures
>
>We have an application, written in COBOL, that produces Late Payment
>Letters. Can someone tell me how (if possible), to have the same
>application print a Signature on the document. This is relatively easy
>using a PC based program such as MS Word or Wordperfect, but I don' t
>know how to get the same outcome from an HP3000.
>
>The above program runs on HP3000 928 and prints to an HP5SiMx
>connected over a LAN.
 
Eric:
 
If you don't mind doing a bit of hacking, you can have a COBOL program, Quiz report or most
anything laser print signatures or other graphics on an HP LaserJet.  No cartridges, no fancy
forms software.  The trick is to load the graphic into printer memory as a PCL macro.  Each
payment letter then includes a short code string to "trip" the macro.  The code sequence pushes
the current laser printer cursor coordinate onto the printer's stack, moves the cursor where you
want the graphic, prints the graphic, then pops the original cursor location back off the stack
so normal printing can resume where it left off.  When you're done printing all your letters, you
reset the printer to remove the signature from memory.
 
The macro itself can be created "with a little magic and common household ingredients."  You need
a scanner (handheld is fine), a word processor that can import and print a graphic, and a disk
editor like the Norton Disk Editor.  You will also probably need a copy of the LaserJet Technical
Reference manual for your model of printer; this goes into much more detail about macros and PCL
than the manuals that ship with the printers.  Some word processors are better than others for
generating a graphic you can easily manipulate.  WordPerfect for DOS 5.2 does a nice job because
it sends very few raster graphics start/stop codes in the print stream and this greatly
simplifies things.  I've noticed that Windows printer drivers, in particular, tend to generate so
many raster codes as to make the output unusable for the "signature macro" trick.  The old
WordPerfect DOS drivers generate a clean print stream that is easy to work with.
 
Armed with your tools, what you need to do is (1) scan the graphic at the same resolution you
intend to print it; (2) import it into an otherwise empty WP document (if using WordPerfect,
anchor the graphic to the top of the page and the left margin and don't set any borders);
(3) print the document to a file at a resolution matching the scanner resolution (to keep the
signature from stretching or shrinking); (4) fire up your disk editor and replace the
WP-generated code strings at the beginning and end of the file with a new set of codes.  The new
codes change the behavior of the file when you send it to the printer.  They cause the graphic to
be loaded into printer memory as a macro instead of being printed on a sheet of paper.  Once
you've created the macro, any application that can print at all can print signatures.  Exit
WordPerfect.  Enter COBOL and Quiz.
 
In the DOS environment, you load the macro into the printer by issuing a command something like
this at a DOS prompt: TYPE MYSIGFIL.MCR > LPT1.  I haven't tried loading a macro directly from
the 3000; the easiest solution (though crude) is to have an A/B switch box that lets you load
from a PC and print from the 3000.  If connected over a LAN via JetDirect, I guess you don't need
the switch box.  Thanks to the marvel of Posix, you could also maybe keep your macros on the 3000
as byte-stream files and redirect them to the printer much as you would with DOS.  Worth a try.
 
The technicalities of the macro programming are too involved to describe fully--I'll send
complete documentation to anyone who wants it.  I have been using this technique with LaserJet
IIs for several years.  You might have to do some fiddling to get the newer LaserJets to work
(and I've been too lazy to try ;-) but it should be possible.  We scan half a dozen of our
dancers' signatures at a time.  When you donate, the thank-you letter has a different dancer's
signature depending on how much you gave.  If you don't donate, we send a real dancer to jump on
you :-(
 
This do-it-yourself macro technique works fine.  The amount of hacking required is a negative but
it's not too hard after a bit of practice.  Unlike using a custom cartridge, the do-it-yourself
method costs nothing and involves no turnaround time to produce signatures and spot graphics as
required.  The printing speed is nearly the top rated speed of the printer because you only send
a signature to the printer once.  Even if you are forced to print over a serial cable, you can
print signatures and logos without any speed penalty, and as long as you have a way to send the
necessary code strings, any application whatsoever can be "graphics enabled."
 
Actually, we mostly use this technique with WordPerfect for Windows and NetWare spooled printing.
Why, with WPWin 6.1 and all its wifty graphics features, would we want to go to such trouble?
Easy: when you are printing a few hundred personalized, laser-signed letters, you wait
forever for the print job to clear your local machine.  You also fill up the spooler real quick
with a few hundred copies of the same signature.  You send all those graphics _twice_ over your
LAN and waste nontrivial bandwidth.  This is of course why you bought Pentium PCs, an Ultium
server with a biggabyte disk array, and an Ethernet switch.  The macro technique frees up spooler
space, conserves bandwidth and makes for _much_ faster printing.
 
If hacking grphics printer macros doesn't appeal, the companies that create custom cartridges are
your best bet.
 
Regards,
 
John Clark, [log in to unmask]
Manager of Information Systems
The National Ballet of Canada
(416) 366-4846  (416) 366-1894 fax

ATOM RSS1 RSS2