Rockwell Automation 5370-UPK CVIM USER-PAK Option User Manual
Page 92
Chapter 8
Defining Strings for Serial Ports and Viewports
8–16
may be preferable to use the
Tool
type viewport when using formula
results for line drawing parameters, especially if you expect the results to
change from inspection to inspection, meaning the line would be
repositioned.
•
Draw line code coordinates correspond to a fixed screen resolution of 512
(h) x 256 (v) pixels.
Cursor Positioning with Draw Line Codes
Any string content that follows the draw line parameters in the string will be
displayed beginning at the end point of the line previously drawn. This is
because draw line parameters set the current “cursor position” for the string.
The cursor position is the point at which the next field in the string will be
displayed, or the next line in the string will be drawn. When the string is
displayed, the initial cursor position is as set by the string
Pick & Place
function. The cursor position subsequently changes, as the string is
displayed. The final cursor position is at the end point of the last line drawn,
or if other contents follow, at the end of the last field in the string.
For example, the string text:
D10,20 30,40 “End Point”
would draw a diagonal line followed by the literal text
End Point
:
End Point
Cursor position after displaying
End Point
Cursor position after
drawing
line
The
dx
and
dy
parameters can be omitted when using the draw line code. If
they are omitted, no line is drawn; however, the cursor position is set by the
starting point (x,y) coordinates. Any remaining part of the string is displayed
beginning at the starting coordinates. In this way, you can use the
x
and
y
starting coordinates to position string contents.
For example, the string text:
D10,20 “Results”
would not draw a line, but would display the word
Results
, beginning at
starting point (10, 20):
(10, 20)
(No line drawn)
Viewport border
Starting point
Results