TRN (Truncate) Ladder Logic Instruction

The Truncate instruction removes the fractional part of a number stored in a Real data type and places the truncated value in the destination. The Source data remains unchanged


  •             Source data =              357.06
  •             Destination data =      357      (After truncate)

List of possible arguments

SOURCE can be one of the following data types.

  • REAL

DESTINATION can be any combination of the following data types.

  • SINT
  • INT
  • DINT
  • REAL

Note: Arithmetic status flags are affected (S:V, S:Z, S:N, S:C). Overflow, Zero, Negative, and Carry.

Leave a Comment