4.7.10 Inverting the result of an operation
The INV instruction is used on its own without any operands. It inverts the result of the opera
-
tion that comes directly before it:
–
If the operation result was “1” it is inverted to “0”
–
If the operation result was “0” it is inverted to “1”.
The above example produces the following signal sequence:
The INV instruction can be used when you need to invert the result of a complex operation. It
can be used in the same position as the AND and ANI instructions.
NOTE
MELSEC System Q Beginners Manual 4 – 29
An Introduction to Programming The Basic Instruction Set
Instruction Function Ladder Diagram IEC Instruction List
INV
Invert, reverses the result of an operation NOT
Ladder Diagram
MELSEC Instruction List
LD X1
AND X2
INV
OUT Y10
INV instruction
1
st
alternative
2
nd
alternative
IEC Instruction List
LD X1
AND X2
NOT
ST Y10
Y10
X1
t
0
1
0
1
X2
0
1
0
1
Operation result before the
INV instruction
Operation result after the
INV instruction
To program an INV instruction in Ladder Diagram
within an OUT instruction, please double-click on the
OUT instruction to display the
Signal Configuration
window.Select
Negation
and confirm with
OK
(see
also chapter 4.7.8)