3.4
Controlling Program
Flow
3.4.1
Jump instructions
LABEL
Step transfer destination
CONDITIONAL JUMP
Jump when the input is
[I
11
turned ON.
UNCONDITIONAL JUMP
Jump to a designated label
OFF.
CONDITIONAL JUMP NOT
Jump when the input
is
turned
to
LAB K
to
loo
I
LAB K
to
LD
X
0
CJN
K
CJ K 102
1
5
to
Ig
I
JMP K
to
LAB K 102
-
-
PROGRAM 1
JMP K5
LAB
K2
+-
-
-
PROGRAM 2
JMP
K
5
LAB
K3
~
6
-
PROGRAM
3
-
JMP K
5
Relevant elements:
KO to K255
Execution times:
Instantaneous progressing
time (1 msec or less)
(Description
of
operations)
A
jump occurs to a
LAB
instruction having
the same number as that designated by the
data of CJ, CJN, and JMP instructions.
LAB
number must not be used more than once
throughout the program.
after CJ, CJN, and JMP instructions.
It may also be used inside or outside the block.
It
is not necessary to finish at the END
of
the
same block. Other END instructions in other
blocks are acceptable.
A
LAB
instruction may be used before or
(Selection
of
the execution program
by
general-
purpose input)
When the digital switch is not connected
to
the general-purpose input,
X0
to
X3
may be
used as jump instructions.
The example shown on the left shows a
case in which
X0
and
X1
are used to select
1
of
4
different programs.
For instance, program
1
is executed when
both
X0
and
X1
are turned
OFF.
LAB
-
44
-