Variable Definition - Siemens sinumerik 840d Programming Manual

Hide thumbs Also See for sinumerik 840d:
Table of Contents

Advertisement

04.00
12.98
1
840D
840D
NCU 571
NCU 572
NCU 573
1.2

Variable definition

User-defined variables
In addition to the predefined variables, programmers
can also define their own variables and assign
values to them.
Local variables (LUD) are only valid in the program
in which they are defined.
Global variables (GUD) apply in all programs.
SW 4.4 and higher:
The local user variables (LUD) defined in the main
program are redefined to program global user
variables (PUD) via machine data.
Machine manufacturer
See machine manufacturer's specifications
If they are defined in the main program, they are also
valid in all levels of the subprograms called. They
are created with part program start and deleted with
part program end or reset.
Example:
$MN_LUD_EXTENDED_SCOPE=1
PROC MAIN
DEF INT VAR1
...
SUB2
...
M30
PROC SUB2
DEF INT VAR2
...
IF (VAR1==1)
VAR1=VAR1+1
VAR2=1
ENDIF
SUB3
...
M17
PROC SUB3
...
 Siemens AG 2000. All rights reserved
SINUMERIK 840D/840Di/810D/FM-NC Programming Guide Advanced (PGA) − 04.00 Edition
FM-NC
810D
840Di
;main program
;PUD definition
;subprogram call
;subprogram call SUB2
;LUD DEFINITION
;read PUD
;read and write
;PUD
;write LUD
;subprogram call
;subprogram SUB3
Flexible NC Programming
1.2

Variable definition

1
1-25

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik fm-ncSinumerik 840diSinumerik 810d

Table of Contents