Omron CJ - REFERENCE MANUAL 10-2009 Reference Manual page 417

Table of Contents

Advertisement

NEG/NEGL
Instruction
2'S COMPLEMENT
DOUBLE 2'S COMPLEMENT
Symbol
Applicable Program Areas
Function block
Area
definitions
Usage
OK
Operands
Operand
NEG: Source word
S
NEGL: First source word
NEG: Result word
R
NEGL: First result word
Operand Specifications
Word addresses
Area
CIO
WR
HR
S
NEG
OK
OK
OK
R
S
NEGL
OK
OK
OK
R
Flags
Name
Error Flag
Equals Flag
Negative Flag
CS/CJ/NSJ Series Instructions Reference Manual (W474)
Mnemonic
Variations
NEG
@NEG
NEGL
@NEGL
NEG
NEG(160)
S: Source word
S
R: Result word
R
Block program areas
Step program areas
OK
OK
Description
Indirect DM/EM
@DM
AR
T
C
DM
EM
@EM
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
OK
Label
ER
OFF
=
• ON if the result is 0000/0000 0000.
• OFF in all other cases.
N
• ON if bit 15 of the result is ON.
• OFF in all other cases.
Function
code
Calculates the 2's complement of a word of hexa-
160
decimal data.
Calculates the 2's complement of two words of
161
hexadecimal data.
Subroutines
OK
Data type
NEG
WORD
DWORD
UINT
Registers
addresses
Con-
stants
*DM
DR
*EM
OK
OK
OK
---
OK
OK
---
---
Operation
3. Instructions
Function
NEGL
NEGL(161)
S: First source word
S
R: First result word
R
SFC action or
Interrupt tasks
transition programs
OK
OK
Size
NEGL
NEG
1
UDINT
1
Flags
Pulse
bits
Indirect
IR
TK
CF
using IR
---
OK
---
---
---
---
OK
---
---
---
3
NEGL
2
2
TR
bits
---
---
379

Advertisement

Table of Contents
loading

Table of Contents