4-25
Printing, Plotting, and Saving Measurement Results
Outputting Plot Files from a PC to an HPGL Compatible Printer
Outputting Plot Files from a PC to an HPGL Compatible Printer
To output the plot files to an HPGL compatible printer, you can use the HPGL
initialization sequence linked in a series as follows:
Step 1. Store the HPGL initialization sequence in a file named hpglinit.
Step 2. Store the exit HPGL mode and form feed sequence in a file named exithpgl.
Step 3. Send the HPGL initialization sequence to the printer.
Step 4. Send the plot file to the printer.
Step 5. Send the exit HPGL mode and form feed sequence to the printer.

Step 1. Store the HPGL initialization sequence.

1. Create a test file by typing in each character as shown in the left column of Table 4-7.
Do not insert spaces or linefeeds. Most editors allow the inclusion of escape sequences.
For example, in the MS-DOS editor (DOS 5.0 or greater), press CNTRL-P (hold down
the CTRL key and press P) followed by the ESCape key to create the escape character.
2. Name the file hpglinit.
NOTE As shown in Table 4-7, the <esc> is the symbol used for the escape character,
decimal value 27.
Table4-7 HPGL Initialization Commands
Command Remark
<esc>E conditional page eject
<esc>&12A page size 8.5 x 11
<esc>&l1O landscape orie nta tion (lower case l, one, capital O)
<esc>&a0L no left margin (a, zero, capital L)
<esc>&a400M no right margin (a, 4, zero, zero, capital M)
<esc>&l0E no top margin (lower case l, zero, capita l E)
<esc>*c7680x5650Y frame size 10.66"x 7.847" (720 decipoints/inch)
<esc>*p50x50Y move cursor to anchor point
<esc>*c0T set picture frame anchor point
<esc>*r-3U set CMY palette
<esc>%1B ente r HPGL mode; curs or at PCL