5 - 152
5 OPERATION CONTROL PROGRAMS
F/FS G
5.17 Program Control
Ver.!
5.17.1 Conditional branch control: IF - ELSE - IEND
Format IF(S) - ELSE - IEND Number of basic steps
IF : 4
ELSE : 3
IEND : 1
[Usable data]
Setting
data
Usable Data
Bit device
Word device Constant
Calculation
expression
Bit
conditional
expression
Comparison
conditional
expression
16-bit
integer
type
32-bit
integer
type (L)
64-bit
floating
point
type (F)
Coasting
timer
16-bit
integer
type (K/H)
32-bit
integer type
(K/H, L)
64-bit
floating
point
type (K)
(S)
— — — — — — — —
: Usable
[Setting data]
Setting data Description Data type of result
(S) Conditional data which controls the flow of program —
[Functions]
(1) If the data specified with (S) is true, the block between IF and ELSE is executed.
(2) If the data specified with (S) is false, the block between ELSE and IEND is
executed.
(3) ELSE can be omitted. In that case, the block between IF and IEND is executed
only when the data specified with (S) is true.
(4) Maximum multiplicities of conditional branch control are eight including selective
branch control. (SELECT - CASE - SEND)
IF...
IF...
SELECT...
CASE...
CEND
SEND
IEND
IEND
(3 level) (2 level) (1 level)
Ver.!
: Refer to Section 1.3 for the software version that supports this function.