Chapter 6 Instruction Details
XBC E-Type Main Unit 6-302 Ve r. 1
6.43 Sign Reverse Instruction
6.43.1 NEG, NEGP, DNEG, DNEGP
Instruction
Step
P M K F L T C S Z D.x
R.x
U N D R
D O O O - O - - - O - - - O O O O 2 - - -
1) NEG (Negative)
(1) Converts the sign of the value in specified area D to save in D area.
(2) View Monitoring Option is available for monitoring, if signed, and the value converted to negative is
used only in Signed Operation.
2) DNEG( Double Word Negative )
(1) Changes the sign of the value saved in D, D+1 and saves in D, D+1.
(2) View Monitoring Option is available for monitoring, if signed, and the value converted to negative is
used only in Signed Operation.
3) Program Example
(1) Where D0020 value converted to negative and operated as signed.
M00000
NEGP D00020
MULP D00020 2 D10000