Siemens SINUMERIK 840D sl Programming Manual page 426

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

Advertisement

Work preparation
3.1 Flexible NC programming
Meaning
<result>:
ISVAR:
<Variable>:
<n>:
<m>:
The following checks are made in accordance with the transfer parameter:
● Is the name known?
● Is the variable an array?
● Is it a one- or two-dimensional array?
● Is the respective array index in the permissible range?
Only if all checks are positive, TRUE (1) is returned.
If a check is negative or a syntax error has occurred, FALSE (0) is returned.
Examples
Program code
DEF INT VAR1
DEF BOOL IS_VAR=FALSE
N10 IS_VAR=ISVAR("VAR1")
Program code
DEF REAL VARARRAY[10,10]
DEF BOOL IS_VAR=FALSE
N10 IS_VAR=ISVAR("VARARRAY[,]")
N20 IS_VAR=ISVAR("VARARRAY")
N30 IS_VAR=ISVAR("VARARRAY[8,11]")
N40 IS_VAR=ISVAR("VARARRAY[8,8")
N50 IS_VAR=ISVAR("VARARRAY[,8]")
N60 IS_VAR=ISVAR("VARARRAY[8,]")
426
Return value
Data type:
Range of values:
Checks whether the specified system/user variable is known in the NC.
Name of the system/user variable
Data type:
Array index of the first dimension (optional)
Data type:
Array index of the second dimension (optional)
Data type:
Comment
; IS_VAR is in this case TRUE.
Comment
; IS_VAR is in this case TRUE, is a two-di-
mensional array.
; IS_VAR is TRUE, variable exists.
; IS_VAR is FALSE, array index is not per-
mitted.
; IS_VAR is FALSE, "]" missing (syntax er-
ror).
; IS_VAR is TRUE, array index is permitted.
; IS_VAR is TRUE, array index is permitted.
BOOL
1
Variable available
0
Variable unknown
STRING
INT
INT
Programming Manual, 12/2019, 6FC5398-2EP40-0BA0
NC programming

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 840de sl

Table of Contents