Chapter 6 Instruction Details
XBC E-Type Main Unit 6-116 Ve r. 1
6.21.6 L2R, L2RP
Instruction
Step
P M K F L T C S Z D.x
R.x
U N D R
L2R(P)
2~4 O - -
S/D
Area Number where Long Real Data is saved
Area Number where Real Data is saved
[Flag Set]
Flag Description
Error
To be set, in case of FPU operation error flag F0057E, F0057C, F0057B,
F0057A are Set.
F110
1) L2R (Long real to Real)
(1) L2R(P) converts S+3,S+2,S+1,S specified Long Real Number to Real to save in D+1, D.
(2) If S+3,S+2,S+1,S specified Long Real Number’s value exceeds Real Number’s range, operation error occurs.
Long Real Number’s range is | 2-1022 to 21023 | , Real Number’s range is | 2-126 to 2127 |.
2) Program Example
(1) Long Real data from D1000~D1003=13456.6 is saved, If Input signal P0000 is On, Real data of 13456.6 is
converted and it is saved in P1100.
0x4167
S+2S+3
b63 b48
0x8C29 0x DCD6
SS+1
b32 b0b16
0xE8B0
( 12345678. 901234)
( 12345678. 901234)
b0b15
D+1, D
0x4B3C
0x614E
b31