237
FLTD, FLTDP, DFLTD, DFLTDP
1
2
3
4
6
7
8
6.3
D
ata conversio
n instru
ctions
6.3.4
F
LT
D, FL
TDP, DF
LTD
, DFLT
DP
:
Integer data to be converted to 64-bit floating decimal point data or head number of the devices where the integer data is stored (BIN 16/32 bits)
:
Head number of the devices where the converted 64-bit floating decimal point data will be stored (real number)
Function
FLTD
(1) Converts 16-bit BIN data designated by to 64-bit floating decimal point type real number, and stores at device number
designated by .
(2) BIN values between -32768 to 32767 can be designated by .
DFLTD
(1) Converts 32-bit BIN data designated by to 64-bit floating decimal point type real number, and stores at device number
designated by .
(2) BIN values between -2147483648 to 2147483647 can be designated by +1 and .
Operation Error
(1) There is no operation error in the FLT(P) or DFLT(P) instruction.
Program Example
(1) The following program converts the BIN 16-bit data at D20 to a 64-bit floating decimal point type real number and stores
the result at D0 to D3.
[Ladder Mode]
[List Mode]
FLTD, FLTDP
Conversion from BIN 16-bit data to floating-point data
(Double precision)
DFLTD, DFLTDP
Conversion from BIN 32-bit data to floating-point data
(Double precision)
6.3.4
FLTD, FLTDP, DFLTD, DFLTDP
Setting
Data
Internal Devices
R, ZR
J \
U \G
Zn
Constants
K, H
Other
Bit
Word
Bit
Word
––
––
––
––
––
––
––
Universal
LCPU
Basic
High
performance
Process
Redundant
P
Command
Command
S
D
S
D
FLTD, DFLTD
FLTDP, DFLTDP
indicates an instruction s
y
mbol of
FLTD/DFLTD.
S
D
S
D
S
D
BIN 16 bits
S
+3
64-bit floating-point
real number
D
+2
D
D
+1
D
S
S
D
B
IN
32
b
i
ts
U
pper
16
b
i
ts
L
ower
16
b
i
ts
+
1
S
S
+
3
6
4-
b
i
t
f
l
oat
i
ng
-
po
i
nt
rea
l
number
D
+
2
D
D
+
1
D
S
S
Step
Instruction
Device