Variable Minimum, Maximum And Range (Minval, Maxval And Bound) - Siemens SINUMERIK 840D sl Programming Manual

Nc programming
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

Work preparation
3.1 Flexible NC programming
BOOL
x : Possible without restrictions
o: Data loss possible due to the range of values being overshot ⇒ alarm;
rounding: decimal place value ≥ 0.5 ⇒ round up, decimal place value < 0.5 ⇒ round down
&: value ≠ 0 ⇒ TRUE, value== 0 ⇒ FALSE
See also
Variables (Page 389)
3.1.1.14

Variable minimum, maximum and range (MINVAL, MAXVAL and BOUND)

The MINVAL and MAXVAL commands compare the values of two variables. The smaller value
(in the case of MINVAL) or the larger value (in the case of MAXVAL) respectively is delivered as
a result.
The BOUND command tests whether the value of a test variable falls within a defined range of
values.
Syntax
<smaller value>=MINVAL(<variable1>,<variable2>)
<larger value>=MAXVAL(<variable1>,<variable2>)
<return value>=<BOUND>(<minimum>,<maximum>,<test variable>)
Meaning
MINVAL:
<smaller value>:
MAXVAL:
<larger value>:
BOUND:
<minimum>:
<maximum>:
<return value>:
424
from ↓/ to →
Obtains the smaller value of two variables
(<variable1>, <variable2>)
Result variable for the MINVAL command
Set to the smaller variable value.
Obtains the larger value of two variables (<variable1>, <variable2>)
Result variable for the MAXVAL command
Set to the larger variable value.
Tests whether a variable (<test variable) is within a defined range of
values.
Variable which defines the minimum value of the range of values.
Variable which defines the maximum value of the range of values.
Result variable for the BOUND command
If the value of the test variable is within the defined range of values, the
result variable is set to the value of the test variable.
If the value of the test variable is greater than the maximum value, the
result variable is set to the maximum value of the definition range.
If the value of the test variable is less than the minimum value, the result
variable is set to the minimum value of the definition range.
REAL
x
Programming Manual, 12/2019, 6FC5398-2EP40-0BA0
INT
BOOL
x
NC programming
x

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 840de sl

Table of Contents