EasyManuals Logo

IDEC OpenNet series User Manual

IDEC OpenNet series
427 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #182 background imageLoading...
Page #182 background image
12: BOOLEAN COMPUTATION INSTRUCTIONS
OPENNET CONTROLLER USERS MANUAL 12-5
NEG (Negate)
Valid Operands
For the valid operand number range, see page 6-2.
Since the NEG instruction is executed in each scan while input is on, a pulse input from a SOTU or SOTD instruction
should be used as required.
Valid Data Types
When a word operand such as D (data register) or L (link register) is designated as the source/destination, 1 point (integer
data type) or 2 points (long data type) are used.
In the integer data type, valid values are –32768 to 32767. If the designated operand is currently –32768 (8000h), the value
will become –32768 (8000h) after it is negated.
In the long data type, valid values are –2,147,483,648 to 2,147,483,647. If the designated operand is currently
–2,147,483,648 (80000000h), the value will become –2,147,483,648 (80000000h) after it is negated.
Example: NEG
• Data Type: Integer
• Data Type: Long
Operand Function I Q M R T C D L Constant Repeat
S/D (Source/Destination) Operand to negate data —————— XX ——
W (word) I (integer) D (double word) L (long)
X X
0 – S/D S/D
When input is on, a two’s complement of operand designated by S/D is produced, and
the new value is stored to the same operand.
NEG(*) S/D
*****
I0
NEG(I) S/D
D10
SOTU
0
D10
Before Execution After Execution
0
D10
1
D10
1
D10
32768
D10
32768
D10
I1
NEG(L) S/D
D20
SOTU
Before Execution After Execution
0
D20·D21
0
D20·D21
1
D20·D21
1
D20·D21
2147483648
D20·D21
2147483648
D20·D21
Phone: 800.894.0412 - Fax: 888.723.4773 - Web: www.clrwtr.com - Email: info@clrwtr.com

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the IDEC OpenNet series and is the answer not in the manual?

IDEC OpenNet series Specifications

General IconGeneral
BrandIDEC
ModelOpenNet series
CategoryController
LanguageEnglish

Related product manuals