Siemens SINUMERIK 840D sl Programming Manual page 113

Job planning
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

Examples
Example 1: INTEGER variable or R parameter as count variable
INTEGER variable as count variable:
Program code
DEF INT iVARIABLE1
R10=R12-R20*R1 R11=6
FOR iVARIABLE1 = R10 TO R11
R20=R21*R22+R33
ENDFOR
M30
R parameter as count variable:
Program code
R11=6
FOR R10=R12-R20*R1 TO R11
R20=R21*R22+R33
ENDFOR
M30
Example 2: Production of a fixed quantity of parts
Program code
DEF INT WKPCCOUNT
FOR WKPCCOUNT = 0 TO 100
G01 ...
ENDFOR
M30
Job Planning
Programming Manual, 06/2009, 6FC5398-2BP20-0BA0
Comments
; Count variable = INTEGER variable
Comments
; Count variable = R parameter (real variable)
Comments
; Defines type INT variable with the name
"WKPCCOUNT".
; Initiates the count loop. The "WKPCCOUNT"
variable increments from the initial value "0"
to the end value "100".
; End of count loop
Flexible NC programming
1.12 Check structures
113

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 828dSinumerik 840de sl

Table of Contents