hit counter script

Evaluate (Eval) - Siemens SINUMERIK 828D Commissioning Manual

Hide thumbs Also See for SINUMERIK 828D:
Table of Contents

Advertisement

Programming commands
6.3 Functions
6.3.16

Evaluate (EVAL)

Description
The EVAL function evaluates a transferred expression and then executes it. With this function,
expressions can be programmed during runtime. This can be useful, for example, for indexed
access operations to variables.
Programming
Syntax:
Description:
Parameters:
Example
VAR1=(S)
VAR2=(S)
VAR3=(S)
VAR4=(S)
CHANGE()
REG[7] = EVAL("VAR"<<REG[5])
IF REG[5] == 1
ELSE
ENDIF
END_CHANGE
126
(exp)
EVAL
Evaluates an expression
exp
REG[7] = VAR1
IF REG[5] == 2
REG[7] = VAR2
ELSE
IF REG[5] == 3
REG[7] = VAR3
ELSE
IF REG[5] == 4
REG[7] = VAR4
ENDIF
ENDIF
ENDIF
Logic expression
; The expression in parentheses produces VAR3 if the
value of REG[5] is equal to 3. The value of VAR3 is,
therefore, assigned to REG[7].
Programming Manual, 10/2015, 6FC5397-3DP40-5BA3
SINUMERIK Integrate Run MyScreens

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents

Save PDF