Basic instructions
8.4 Comparator operations
S7-1200 Programmable controller
System Manual, V4.2, 09/2016, A5E02486680-AK
251
IN_Range (Value within range) and OUT_Range (Value outside range)
Table 8- 31 Value within Range and value outside range instructions
val, max);
Tests whether an input value is in or out of a specified value range.
If the comparison is TRUE, then the box output is TRUE.
val, max);
1
For LAD and FBD: Click the "???" and select the data type from the drop-down list.
Table 8- 32 Data types for the parameters
MIN, VAL, MAX SInt, Int, DInt, USInt, UInt, UDInt, Real, LReal,
Comparator inputs
1
The input parameters MIN, VAL, and MAX must be the same data type.
● The IN_RANGE comparison is true if: MIN <= VAL <= MAX
● The OUT_RANGE comparison is true if: VAL < MIN or VAL > MAX