HP 7470A Interfacing And Programming Manual page 41

Graphic plotter
Hide thumbs Also See for HP 7470A:
Table of Contents

Advertisement

• execution of a DF command, or
• execution of a PA instruction with or without parameters.
The pen moves and draws lines only within the currently defined
window. Refer to The Input Window Instruction, IW, in Chapter 1.
The plotter discards parameters which are out of range. Error 3 will be
set (parameter out of range). A PA command with out-of-range param­
eters will still establish plot absolute mode for future occurrences of PU
or PD with parameters. When scaling is off, in-range parameters are
greater than or equal to -32 768 and less than or equal to 32 767. When
scaling is on, both the parameters and their plotter unit equivalent
must also be in that same range. To find the plotter unit equivalent, use
the equations in the section Scaling Without Using the SC Instruction in
Appendix C.
There are four types of vectors that can be drawn with a PA command
from a given last point to some new point.
LAST POINT
NEW POINT
1. inside window area
to inside window area
2. inside window area
to outside window area
3. outside window area to inside window area
4. outside window area to outside window area
In type one, the pen moves from the last point to the new point with the
pen up or down as programmed.
In type two, the pen moves from the last point toward the new point
and stops where the line between the two points intersects the current
window. The pen up/down condition is as programmed until the inter­
section is reached. Then, the pen is raised.
In type three, the pen moves with the pen up, to the point where the
straight line between the last and new point intersects the window limit.
When the pen reaches this point, the pen assumes its programmed (up
or down) position. The pen then moves to the new point.
In type four, no pen movement occurs unless the straight line between
the last and new point intersects the window. The X- and Y-coordinates
of the current pen position are updated. If part of the vector is in the
window area, the pen moves, pen up, to the point where the line be­
tween the last and the new point first intersects the window limit. The
pen moves under programmed pen up/down control to the intersection
of the vector and the other window limit. At this point, the pen stops
and lifts.
Since out-of-range points are discarded, the plotter will draw a line be­
tween the two points on either side of discarded points. You can be sure
all lines on your plot represent actual data if you:
1. have not changed the error mask from its default setting;
CONTROLLING THE PEN AND PLOTTING
2. have not executed an output error instruction; and
3. the error light is not on at the end of your plot.
(The fact that the error light is on does not necessarily mean out-of-
range data has been encountered; an error in any HP-GL command
will turn the light on.)
The following strings of HP-GL instructions, if sent to the plotter using
a suitable output statement such as PRINT or OUTPUT, will draw two
triangles and then move to the point 10 900,7650 with the pen up.
" I N ; S P 1 ; "
" P F I 2 0 0 0 , 1 5 0 0 , P D , 0 , 1 5 0 0 , 2 0 0 0 , 3 5 0 0 , 2 0 0 0 , 1 5 0 0 , P U , 2 5 0 0 , 1 5 0 0 ; "
"PFIPD4500, 1 5 0 0 , 2 5 0 0 , 3 5 0 0 , 2 5 0 0 , 1 5 0 0 , P U , 1 0 9 0 0 , 7 6 5 0 ; "
2000 , 3500
2500,, 3500
1500
2000,1500
2500,1500
4500,1500
The next strings of HP-GL instructions scale the plotting area into user
units 0 to 100 in each axis and again draws two triangles. Use an out­
put statement implemented on your computer to send the strings to the
plotter.
" I N ; S P 1 ; S C 0 , 1 0 0 , 0 , 1 0 0 ; "
" P R 2 0 , 1 5 , P D , 0 , 1 5 , 2 0 , 3 5 , 2 0 , 1 5 , P U , 2 5 , 1 5 ; "
" P R P D 4 5 , 1 5 , 2 5 , 3 5 , 2 5 , 1 5 , P U ; "
CONTROLLING THE PEN AND PLOTTING 3-7

Advertisement

Table of Contents
loading

Table of Contents