Standard function blocks
248
Inputs
Input (I): REAL24
Outputs
Output (O): REAL
REALn_TO_DINT
(10029)
Illustration
Execution time
6.45 µs
Operation
Output (O) is the 32-bit integer equivalent of the REAL/REAL24 input (I). Output O1 is
the integer value and output O2 is the fractional value.
The output value is limited to the maximum value of the data type range.
Example (from REAL to DINT):
When I = 2.04998779297, O1 = 2 and O2 = 3276.
Inputs
The input data type is selected by the user.
Input (I): REAL, REAL24
Outputs
Output (O1, O2): DINT
REALn_TO_DINT_SIMP
(10028)
Illustration
Execution time
5.54 µs
Operation
Output (O) is the 32-bit integer equivalent of the REAL/REAL24 input (I) multiplied by
the scale input (SCALE).
Error codes are indicated by the error output (ERRC) as follows:
Example (from REAL to DINT):
When I = 2.04998779297and SCALE = 100, O = 204.
REALn_TO_DINT
(REAL)
91
TLA1 1 msec
(1)
I
O1
O1(91)
O2
O2(91)
REALn_TO_DINT_SIMP
(REAL)
92
TLA1 1 msec
(1)
I
SCALE
O
O(92)
ERRC
ERRC(92)
Error code
Description
0
No error
1001
The calculated integer value exceeds the minimum value. The output
is set to the minimum value.
1002
The calculated integer value exceeds the maximum value. The
output is set to the maximum value.
1003
Scale input is 0. The output is set to 0.
1004
Incorrect scale input, i.e. scale input is < 0 or is not a factor of 10.
Summary of Contents for ACSM1 Series
Page 1: ...ACSM1 Firmware Manual ACSM1 Speed and Torque Control Program...
Page 2: ......
Page 4: ......
Page 12: ...Table of contents 12...
Page 49: ...Drive control and features 49...
Page 282: ...Standard function blocks 282...
Page 306: ...Application program template 306...
Page 312: ...Control chain block diagrams 312...
Page 331: ...331...
Page 332: ...332...
Page 333: ......