10.4.6.1
Parameters of the Truncate Function
Input/ Output
Choices
Description
enable
flow
When the function is enabled, the conversion is
performed.
IN
R, AI, AQ, constant
IN contains a reference for the real value to be
truncated.
ok
flow, none
The OK output is energized when the function is
performed without error, unless the value is out of
range or IN is NaN.
Q
R, AI, AQ
For integer only: I, Q, M,
T, G
Q contains the truncated INT or DINT value of the
original value in IN.
10.4.6.2
Example
In the example, the displayed constant is truncated and the integer result 562 is placed in
%T0001.
%I0002
CONST
5.02
OK
REAL
TRUN_
INT
IN
%T0001
Q
Instruction Set Reference
GFK-1503E User Manual 161
For public disclosure
Summary of Contents for VersaMax PLC
Page 16: ...Notes 16 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 38: ...Notes 38 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 50: ...Notes 50 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 92: ...Notes 92 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 112: ...Notes 112 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 224: ...Notes 224 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 292: ...Notes 292 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 316: ...Notes 316 GFK 1503E VersaMax PLC User Manual For public disclosure ...
Page 317: ......