Parker Hannifin VIX250IM Stepper Machine User Manual


 
VIX IM MICROSTEPPER INDEXER DRIVE USER GUIDE
72
Conditional Code
The flow of a motion control program will depend upon the position of the motor in
combination with the value of particular inputs and commands. System variables are used to
continuously monitor the state of a drives indexer and are able to report such things as
status of indexing or moving/not moving as listed in Table 4-2. Certain system variables
are capable of being tested by the TR (wait for trigger) or IF (test condition)
commands. This allows the value of a system variable to be tested in the following ways:
= Equals
<> Does not equal
> Greater than
< Less than
The TR command pauses program execution until the required trigger condition is met, while
the IF command tests the value of a system variable and executes the next line of code if it
is true, otherwise it skips the next line of code. Use of these commands allows
synchronisation with external events and program branching.
System variables which may be used in conjunction with the IF command are listed in Table
4-8. Where the variable can also be used with the TR command a Y appears in the TR
column.
Variable Name > < = <> TR Format
AI Analogue input Y Y N N Y decimal
DFn Drive fault status N N Y Y Y binary
IN Inputs (drive) N N Y Y Y binary
INn Inputs
(expansion)
N N Y Y Y binary
IP In position flag N N Y Y Y bit
MV Moving N N Y Y Y bit
PA Position absolute Y Y Y* Y Y decimal
PE Position error Y Y Y* Y Y decimal
PF Position following Y Y Y* Y decimal
PI Position
incremental
Y Y Y* Y Y decimal
PM Position master Y Y Y* Y Y decimal
PT Position target Y Y Y* Y Y decimal
RM Registration
move
NNY Y N bit
STn Status of
indexing
N N Y Y Y binary
UFn User program
fault status
N N Y Y N binary
* Not recommended during motion
Table 4-8. System Variables that can be used for Conditional Control