Omron SYSMAC CP Series Instruction & Reference Manual page 272

Cpu unit
Hide thumbs Also See for SYSMAC CP Series:
Table of Contents

Advertisement

2 Instructions
Function
FLT
FLT(452) converts the 16-bit signed binary value in S to 32-bit floating-point data (IEEE754-format) and
places the result in R+1 and R. A single 0 is added after the decimal point in the floating-point result.
Only values within the range of -32,768 to 32,767 can be specified for S. To convert signed binary data
outside of that range, use FLTL(453).
Example conversions:
A signed binary value of 3 is converted to 3.0.
A signed binary value of -3 is converted to -3.0.
FLTL
FLTL(453) converts the 32-bit signed binary value in S+1 and S to 32-bit floating-point data (IEEE754-
format) and places the result in R+1 and R. A single 0 is added after the decimal point in the floating-
point result.
Signed binary data within the range of –2,147,483,648 to 2,147,483,647 can be specified for S+1 and
S. The floating point value has 24 significant binary digits (bits). The result will not be exact if a number
greater than 16,777,215 (the maximum value that can be expressed in 24-bits) is converted by
FLTL(453).
Example Conversions:
A signed binary value of 16,777,215 is converted to 16,777,215.0.
A signed binary value of –16,777,215 is converted to –16,777,215.0.
2-236
S
R+1
R
B 8 A 3
R+1: D00101
R+1: D00100
CY
1
6
8
5 1
Signed binary data (16 bits)
Floating-point data (32 bits)
6 0 E 3
F 9 2 D
CP1E CPU Unit Instructions Reference Manual(W483)

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents