Multiple Conditional Statements The DMC-21x2/21x3 will accept multiple conditions in a single jump statement. The conditional statements are combined in pairs using the operands “&” and “|”. The “&” operand between any two conditions, requires that both statements must be true for the combined statement to be true. The “|” operand between any two conditions, requires that only one statement be true for the combined statement to be true. NOTE: Each condition must be placed in parenthesis for proper evaluation by the controller. In addition, the DMC-21x2/21x3 executes operations from left to right. For further information on Mathematical Expressions and the bit-wise operators ‘&’ and ‘|’, see pg 150.
Using the IF and ENDIF Commands
An IF conditional statement is formed by the combination of an IF and ENDIF command. The IF command has as it's arguments one or more conditional statements. If the conditional statement(s) evaluates true, the command interpreter will continue executing commands which follow the IF command. If the conditional statement evaluates false, the controller will ignore commands until the associated ENDIF command is executed OR an ELSE command occurs in the program (see discussion of ELSE command below). NOTE: An ENDIF command must always be executed for every IF command that has been executed. It is recommended that the user not include jump commands inside IF conditional statements since this causes re-direction of command execution. In this case, the command interpreter may not execute an ENDIF command.
Using the ELSE Command
The ELSE command is an optional part of an IF conditional statement and allows for the execution of command only when the argument of the IF command evaluates False. The ELSE command must occur after an IF command and has no arguments. If the argument of the IF command evaluates false, the controller will skip commands until the ELSE command. If the argument for the IF command evaluates true, the controller will execute the commands between the IF and ELSE command.
Temporal Ming sheng automation equipment co., LTD., specialized in (DCS system) (robotic system) (large) servo control system (PLC system) module for spare parts sales, inventory adequate, product quality, let you have no trouble back at home of our main products are widely used in metallurgy, petroleum, glass, aluminum manufacturing, petrochemical industry, coal mine, papermaking, printing, textile printing and dyeing, machinery, electronics, automobile manufacturing, tobacco, plastics machinery, electric power, water conservancy, water treatment/environmental protection, municipal engineering, boiler heating, energy, power transmission and distribution and so on
Brand advantage
GE gas turbine electric, ABB, Bently, Emerson, Honeywell, ICS Triplex, WOODWARD , FOXBORO, SST, HIMA , Motorola, TRICONEX invensys,SCHNEIDER A - B, Prosoft import module in Europe and America and so on