Manual – IPOSplus®
357
23
Comparison commands
Assembler – Commands
CPLT/COMPARE
LESS THAN
The CPLT command compares, observing the signs, whether variable X1 is less than
as variable or constant X2. Variable X1 contains the result. It is not equal to zero if the
condition is fulfilled; otherwise, the result is zero.
The result can be processed further, for example, with a subsequent jump command.
Variable X2 remains unchanged.
Structure
Example 1
SET H0 = -3
CPLT H0 < -3
After the program has been processed, H0 has the value zero.
Example 2
SET H0 = 2
SET H2 =
3
CPLT H0 < H2
After the program has been processed, H0 has the value one.
CPNE/COMPARE
NOT EQUAL
The CPNE command compares, observing the signs, whether variable X1 is not equal
to the variable or constant X2. Variable X1 contains the result. It is not equal to zero if
the condition is fulfilled; otherwise, the result is zero.
The result can be processed further, for example, with a subsequent jump command.
Variable X2 remains unchanged.
Structure
Example 1
SET H0 = 13
SET H1 = 13
CPNE H0 != H1
After the program has been processed, H0 has the value zero and H1 the value 13.
Example 2
SET H0 = 50
CPNE H0 != 13
After the program has been processed, H0 has the value one.
Command structure
Mxxx CPLT X1 < X2
Mxxx: Label
(optional)
X1:
Variable (result)
X2:
Variable or constant
Command structure
Mxxx CPNE X1 != X2
Mxxx: Label
(optional)
X1:
Variable (result)
X2:
Variable or constant
P
i
f
kVA
Hz
n
P
i
f
kVA
Hz
n