Справочник Пользователя для Mitsubishi Electronics MELSEC -Q/L
7 APPLICATION INSTRUCTIONS
7.11 Character String Processing Instructions
569
7
Conversion from character string to floating-point data
EVAL(P)
*1 Applicable for the Universal model QCPU, LCPU.
Processing details
• Converts character string stored in the area starting from the device number designated by (S) to 32-bit floating point type
real number, and stores result at device designated by (D).
• The designated character string can be converted to 32-bit floating point type real number data either in the decimal point
format or the exponent format.
• Basic model QCPU: The serial number (first five digits) is "04122" or later.
(S): Character string data to be converted to 32-bit floating decimal point real number data or head number of the devices where the character string data is
stored (character string)
(D): Head number of the devices where the converted 32-bit floating decimal point real number data will be stored (real number)
Setting
data
data
Internal device
R, ZR
J\
U\G
Zn
Constant
$
$
Others
Bit
Word
Bit
Word
(S)
(D)
• When using decimal point format
• When using exponent format
Basic
Process
High
performance
Redundant Universal
LCPU
Ver.
Command
Command
EVAL
EVALP
S
D
S
D
EVAL
EVALP
+1
ASCII code for the sign
ASCII code for the 1st character
ASCII code for the 3rd character
b15
b8 b7
b0
+2
ASCII code for the 5th character
ASCII code for the 7th character
+3
00
H
+4
Indicates the end
of character string
of character string
+1
32-bit floating-point
real number
real number
S
S
S
S
S
ASCII code for the 2nd character
ASCII code for the 4th character
ASCII code for the 6th character
D
D
+1
2D
H
(-)
31
H
(1)
2E
H
(.)
30
H
(0)
+2
37
H
(7)
38
H
(8)
31
H
(1)
32
H
(2)
+3
00
H
+4
0 7 8 1 2
.
1
-
+1
32-bit floating-point
real number
real number
7
-1 . 0 8 12
S
D
S
S
S
S
S
b15
b8b7
b0
D
+1
2D
H
(-)
20
H
(space)
31
H
(1)
2E
H
(.)
b15
b7
b0
+2
33
H
(3)
32
H
(2)
30
H
(0)
31
H
(1)
+3
45
H
(E)
2B
H
(+)
31
H
(1)
+4
+5
+1
30
H
(0)
00
H
-1. 320 1E + 10
1
1
. 3 2 0 1 E + 1 0
32-bit floating-point
real number
real number
+6
b8
S
S
S
S
S
S
S
D
D