A SERVICE OF

logo

[ If Branch, Wait Condition ]
if Branch: if, then, else, endIf
This section explains point job data commands for executing different jobs according to certain
conditions. These commands belong to the category [if Branch, Wait Condition.]
Command Category
Command
Parameter
Job
if
-
if Branch
then
-
Executes the following commands if true.
else
-
Executes the following commands if false.
if Branch, Wait
Condition
endIf
-
End of if Branch
Be sure to put the commands for the Condition after “if.”
Examples of if, then, else and endIf
Example 1: If #genIn2 is ON, raise the Z
axis by 10 mm and output a pulse to
#genOut1.
If #genIn2 is not ON, descend the Z axis
10 mm and output a pulse to #genOut2.
The Commands for Example 1 are shown below.
#genIn2=ON
Raise by 10 mm.
Output to #genOut1.
Descend by 10 mm.
Output to #genOut2.
if
ld #genIn2
then
upZ 10,20
pulse #genOut1,200
else
downZ 10,20
pulse #genOut2,200
endIf
If the following condition is true, advance to then. If false, advance to
else.
#genIn2 = ON (Condition)
If the Condition is true, execute the following commands.
Raise the Z axis by 10 mm at the speed of 20 mm/sec,
And output ON pulse to #genOut1. (The pulse width is 0.2 seconds.)
If the Condition is false, execute the following commands.
Descend the Z axis by 10 mm at the speed of 20 mm/sec,
and output ON pulse to #genOut2 (The pulse width is 0.2 seconds.
End of if Branch
Features II CARTESIAN Benchtop Robot
36