516
FX3S/FX3G/FX3GC/FX3U/FX3UC Series
Programming Manual - Basic & Applied Instruction Edition
18 Floating Point – FNC110 to FNC139
18.16 FNC128 – ENEG / Floating Point Negation
18.16 FNC128 – ENEG / Floating Point Negation
Outline
This instruction inverts the sign of binary floating point (real number) data.
→ For handling of floating point, refer to Subsection 5.1.3.
1. Instruction format
2. Set data
3. Applicable devices
Explanation of function and operation
1. 32-bit operation (DENEG and DENEGP)
The sign of binary floating point stored in [ +1, ] is inverted, and the negation result is stored to [ +1,
].
Program example
In the program example shown below, the sign of floating point data stored in D100 and D101 is inverted, and the
negation result is stored to D100 and D101 when X000 turns ON.
Operand Type Description Data Type
Head device number storing binary floating data whose sign is to be inverted Real number (binary)
Oper-
and
Type
Bit Devices Word Devices Others
System User Digit Specification System User
Special
Unit
Index
Con-
stant
Real
Number
Charac-
ter String
Pointer
XYMTCSD.b KnX KnY KnM KnS T C D R U\G V Z Modify K H E ""P
−
−
Mnemonic Operation Condition
16-bit Instruction
DENEG
DENEGP
Mnemonic Operation Condition
32-bit Instruction
5 steps
Continuous
Operation
Pulse (Single)
Operation
P
FNC 128
ENEG
D
D
D
D
D
D
D
Command
input
FNC128
DENEG
D
X000
1.2345
−
1.2345
D101 D100D101 D100
END
FNC128
DENEGP
D100