7 Applied Instructions
7.12 Floating Point
472
FXCPU Structured Programming Manual
(Basic & Applied Instruction)
Program example
By using the DEBIN instruction, the numeric value including the decimal point can be directly converted into
the binary floating decimal point.
Example: Binary floating decimal point conversion of 3.14
3.14=314×10
-2
(Decimal floating decimal point)
→ As for program example of floating decimal point operation, refer to section 7.5.10.
[Structured ladder]
X002
VAR_01
*1
MOVP
EN
s
ENO
K314
MOVP
EN
s
ENO
K-2
D0
D1
DEBIN
EN
s
ENO
d
d
d
VAR_02
*2
K314 → D0
K-2 → D1
314×10
-2
[D0] [D1]
(D1,D0)→(D11,D10)
314×10
-2
Binary floating decimal point
*1. VAR_01 is global label, and D0 is defined.
*2. VAR_02 is global label, and D10 is defined.
[ST]
MOVP(X002,K314,D0);
MOVP(X002,K-2,D1);
DEBIN(Y002,VAR_01,VAR_02);