
Drive PLC Developer Studio
IEC 61131-3 Operators
12-10
l
DDS EN 2.3
12.4.5 MUX
Multiplexer
OUT := MUX(K, IN0,...,INn)
means:
OUT := INk.
• IN0, ... , INn and OUT canbeofanytype.
• K must be of type BYTE, WORD, DWORD, SINT, USINT, INT, UINT, DINT or UDINT.
• MUX selects the Kth value from a number of values. If K is greater than the number of other
inputs (n), the last value will be passed on (INn).
Examples
IL ST FBD
LD 0
MUX 30,40,50,60,70,80
ST Var1 (* Var1 = 30 *)
Tip!
For runtime optimization, the system now computes the expression attached to the input side of
INk. Contrary to this, simulation computes all branches.
12.5 Comparison operators
Types:
The operands of the following comparison operators can be of type BOOL, BYTE, WORD, DWORD,
SINT, USINT, INT, UINT, DINT, UDINT, REAL, TIME, DATE, TIME_OF_DAY, DATE_AND_TIME and
STRING.
12.5.1 GT
Greater than
A Boolean operator with the result TRUE if the first operand is greater than the second operand.
Examples
IL ST FBD
LD 20
GT 30
ST Var1 (* Var1 = FALSE *)
Var1 := 20 > 30;
Comentários a estes Manuais