6.3 Data Conversion Instructions
6.3.6 Floating-point data to 16-bit/32-bit BIN data conversion (double precision)
6-81
6
BA
S
IC
INSTRUCTIONS
INTD, DINT
D
INTD, DINTD
DINTD(P)
(1) Converts the 64-bit floating-point real number specified for
to 32-bit BIN data, and stores
the result to
.
(2) 64-bit floating-point real numbers between 2147483648.0 and 2147483647.0 can be
specified for
+ 3,
+ 2,
+ 1 or
.
(3) The integer value stored in
+ 1 and
is stored as BIN 32 bits.
(4) After conversion, the first digit from the decimal point of the 64-bit floating-point real number
is rounded off.
O
p
erat
i
on
E
rror
In any of the following cases, an operation error occurs, the error flag (SM0) is turned ON, and
the corresponding error code is stored to SD0.
• The value of the specified device is not within the following range.
(Error code: 4140)
0, 2
-1022
| value of the specified device | 2
1024
• The value of the specified device is
−
0. (Error
code:
4140)
• The 64-bit floating-point data set for
is outside the range of
−
32768.0 to 32767.0 for the
INTD instruction.
(Error code: 4140)
• The 64-bit floating-point data set for
is outside the range of
−
2147483648.0 to
2147483647.0 for the DINTD instruction.
(Error code: 4140)
s
d
Upp
er
16
b
its
Lo
w
er
16
b
its
6
4-
b
it
f
loating-
p
oint
real num
b
er
BIN 3
2
b
its
d
s
s
s
s
s
d
d
s
s
Summary of Contents for MELSEC Q Series
Page 1: ...Structured Programming Manual Mitsubishi Programmable Controller QCPU Common Instructions ...
Page 2: ......
Page 14: ...A 12 MEMO ...
Page 340: ...6 178 MEMO MTR ...
Page 708: ...7 368 MEMO ...
Page 776: ...8 68 MEMO ...
Page 796: ...9 20 MEMO ...
Page 804: ...App 8 MEMO ...
Page 812: ...Index 8 MEMO ...
Page 815: ......