Delta AH500 Programming Manual page 245

Hide thumbs Also See for AH500:
Table of Contents

Advertisement

API
Instruction code
0202
D
FLT
Device X
Y
M
S
D
Symbol:
Explanation:
1.
The instruction is used to convert the binary integer into the single-precision floating-point
number.
2.
The operand S used in the instruction FLT can not be the 32-bit counter.
3.
The source device S used in the instruction FLT occupies one register, and D used in FLT
occupies two registers.
4.
The source device S used in the instruction DFLT occupies two registers, and D used in DFLT
also occupies two registers.
When the absolute value of the conversion result is larger than the value which can be
represented by the maximum floating-point number, SM602 is ON, and the maximum
floating-point number is stored in D.
When the absolute value of the conversion result is less than the value which can be
represented by the minimum floating-point number, SM601 is ON, and the minimum
floating-point number is stored in D.
When the conversion result is zero, SM600 is ON.
Example 1:
1.
When X0.0 is ON, the binary integer in D0 is converted into the single-precision floating-point
number, and the conversion result is stored in (D13, D12).
2.
When X0.1 is ON, the binary integer in (D1, D0) is converted into the single-precision
floating-point number, and the conversion result is stored in (D21, D20).
3.
Suppose the value in D0 is 10. When X0.0 is ON, 10 is converted into the single-precision
floating-point number 16#41200000, and 16#41200000 is stored in the 32-bit register (D13,
D12).
4.
Suppose the value in the 32-bit register (D1, D0) is 100,000. When X0.1 is ON, 100,000 is
converted into the single-precision floating-point number 16#47C35000, 16#47C35000 is
stored in the 32-bit register (D21, D20).
Operand
S, D
P
S
T
C
HC
D
Pulse instruction 16-bit instruction (5 steps) 32-bit instruction (5 steps)
AH500
S : Source device
D : Conversion result
Ch a pt er 6 Ap p l i ed I ns t r uc t i ons
Converting the binary integer into
the binary floating-point number
L
SM SR
E
PR
AH500
Word/Double word
Double word
Function
K
16# "$"
DF
AH500
6 - 7 7

Advertisement

Table of Contents
loading

Table of Contents