-

LIMIT

Type Function
Description Limits the value of the input parameter IN to the value range defined by the input parameters MN (minimum limit) and MX (maximum limit) as follows:

OUT := MIN(MAX(IN,MN),MX)

where the function MIN determines the minimum limit for the output value and the function MAX the maximum limit for the output value.

  • The value connected to IN is written to the output if the value is in the range of MN and MX.
  • If the value at IN1 is smaller than the MN value (IN1 < MN), the MN value is written to the output.
  • If the value at IN1 is greater than the MX value (IN1 > MX), the MX value is written to the output.
Notes
  • The function provides implicit data type conversion at its input and output parameters according to the rules defined by the IEC 61131 standard.
  • The function is an overloaded function. It can operate on various input data types.
  • The function is not extendable, no further inputs can be added.
Parameters Inputs

MN

IN

MX

Output

OUT
Error behaviorError behavior
Additional information EN/ENO behavior