Conditional Expressions; Operational Instructions - Hitachi NT2021XA Instruction Manual

Easy-sequence programming software
Table of Contents

Advertisement

Chapter 2 Syntax

(2) Conditional expressions

The table below lists the conditional expressions that can be used for the <condition> parameters in program control instructions.
Instruction
name
Mnemonic code
Comparison
Note : <variable 1> and <variable 2> can be constants ranging from 0 to 127.

(3) Operational instructions

Instruction
name
Mnemonic code
<variable 1> =
<variable 1> =
Arithmetic
operation
<variable 1> =
<variable 1> =
Remainder
<variable 1> =
Absolute
<variable 1> =
value
Substitution
<variable 1> =
<variable 1> =
<variable 1> =
Logic
operation
<variable 1> =
<variable 1> =
Note 1 : <variable 2> can be a constant ranging from 0 to 127.
Note 2 : <variable 3> can be a constant ranging from 0 to 2
Instruction format
Parameter 1
Parameter 2
<variable 2 /
=
constant>
<variable 2 /
<
constant>
<variable 2 /
<=
constant>
<variable 2 /
>
constant>
<variable 2 /
>=
constant>
<variable 2 /
<>
constant>
Instruction format
Parameter 1
Parameter 2
<variable 2/
constant>
<variable 2/
constant>
<variable 2/
constant>
<variable 2/
constant>
<variable 2/
mod
constant>
abs
<variable 2/
or
constant>
<variable 2/
and
constant>
<variable 2/
xor
constant>
not
Parameter 3
Parameter 4
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
Parameter 3
Parameter 4
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
<variable 3/
constant>
31
-1.
2-4
Description
Parameter 5
"True" when <variable 2/constant> is equal
to <variable 3/constant>
"True" when <variable 2/constant> is less
than <variable 3/constant>
"True" when <variable 2/constant> is not
greater than <variable 3/constant>
"True" when <variable 2/constant> is
greater than <variable 3/constant>
"True" when <variable 2/constant> is not
less than <variable 3/constant>
"True" when <variable 2/constant> is not
equal to <variable 3/constant>
Description
Parameter 5
Adds <variable 2/constant> and <variable
3/constant> and assigns the result to
<variable 1>.
Subtracts <variable 3/constant> from
<variable 2/constant> and assigns the
result to <variable 1>.
Multiplies <variable 2/constant> by
<variable 3/constant> and assigns the
result to <variable 1>.
Divides <variable 2/constant> by <variable
3/constant> and assigns the result to
<variable 1>.
Divides <variable 2/constant> by <variable
3/constant> and assigns the remainder to
<variable 1>.
Assigns the absolute value of <variable
3/constant> to <variable 1>.
Assigns <variable 3/constant> to <variable
1>.
Assigns the OR of <variable 2/constant>
and <variable 3/constant> to <variable 1>.
Assigns the AND of <variable 2/constant>
and <variable 3/constant> to <variable 1>.
Assigns the XOR of <variable 2/constant>
and <variable 3/constant> to <variable 1>.
Inverts the bits of <variable 3/constant> and
assigns the inverted bits to <variable 1>.

Advertisement

Table of Contents
loading

Table of Contents