EasyManua.ls Logo

Omron CP - PROGRAMMING MANUAL 05-2007 - Page 430

Omron CP - PROGRAMMING MANUAL 05-2007
1175 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
397
Conversion Instructions Section 3-11
3-11-6 DOUBLE 2’S COMPLEMENT: NEGL(161)
Purpose Calculates the 2’s complement of two words of hexadecimal data.
Ladder Symbol
Variations
Applicable Program Areas
Operand Specifications
Description NEGL(161) calculates the 2’s complement of S+1 and S and writes the result
to R+1 and R. The 2’s complement calculation basically reverses the status of
the bits in S+1 and S and adds 1.
Note This operation (reversing the status of the bits and adding 1) is equivalent to
subtracting the content of S+1 and S from 0000 0000.
NEGL(161)
S
R
S: First source word
R: First result word
Variations Executed Each Cycle for ON Condition NEGL(161)
Executed Once for Upward Differentiation @NEGL(161)
Executed Once for Downward Differentiation Not supported
Immediate Refreshing Specification Not supported
Block program areas Step program areas Subroutines Interrupt tasks
OK OK OK OK
Area S R
CIO Area CIO 0 to CIO 6142
Work Area W0 to W510
Holding Bit Area H0 to H510
Auxiliary Bit Area A0 to A958 A448 to A958
Timer Area T0000 to T4094
Counter Area C0000 to C4094
DM Area D0 to D32766
Indirect DM addresses
in binary
@ D0 to @ D32767
Indirect DM addresses
in BCD
*D0 to *D32767
Constants #00000000 to #FFFFFFFF
(binary)
---
Data Registers ---
Index Registers ---
Indirect addressing
using Index Registers
,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to +2047 ,IR15
DR0 to DR15, IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
(
S+1, S
) (
R+1, R
)
2's complement
(Complement + 1)

Table of Contents

Related product manuals