User`s guide

Defining Belt-Relative Locations
In order to define locations relative to a belt, belt-relative compound transformations can be
used as parameters to all the standard V+ teaching aids. For example, all the following
commands define a location loc_1 relative to the current belt location:
1
HERE %belt:loc_1
POINT %belt:loc_1
TEACH %belt:loc_1
In each of these cases, the instantaneous location corresponding to %belt would be
determined (based upon the reading of the belt encoder associated with %belt); loc_1 would
be set equal to the difference between the current tool location and the instantaneous
location defined by %belt.
While a belt variable can be used as the first (leftmost) element of a compound
transformation to define a transformation value, a belt variable cannot appear by itself. For
example, LISTL will not display a belt variable directly. To view the value of a belt variable,
enter the command:
LISTL %belt_variable:NULL
1
Before defining a location relative to a belt, you must make sure the belt encoder offset is set
properly. That usually involves issuing a monitor command in the form:
DO SETBELT %belt = BELT(%belt)
Basic Programming Concepts
V+Language User's Guide, v17.0
Page 316