Chapter 4. Ladder Diagram (LD) Programming
GFK-2950C February 2018 119
4.6 Conversion Functions
The Conversion functions change a data item from one number format (data type) to another. Many
programming instructions, such as math functions, must be used with data of one type. As a result,
data conversion is often required before using those instructions.
Converts degrees to radians
Converts radians to degrees
Convert to BCD4 (4-digit Binary-Coded-Decimal)
Converts UINT (16-bit unsigned integer) to BCD4
Converts INT (16-bit signed integer) to BCD4
Convert to BCD8 (8-digit Binary-Coded-Decimal)
Converts DINT (32-bit signed integer) to BCD8
Convert to INT (16-bit signed integer)
Convert to UINT (16-bit unsigned integer)
Convert to DINT (32-bit signed integer)
Converts 8-digit Binary-Coded-Decimal (BCD8) to DINT
Converts REAL (32-bit signed real or floating-point values) to DINT
Converts REAL (64-bit signed real or floating-point values) to DINT
Convert to REAL (32-bit signed real or floating-point values)
Convert to LREAL(64-bit signed real or floating-point values)
Rounds a REAL number down to a DINT (32-bit signed integer) number
Rounds a REAL number down to an INT (16-bit signed integer) number