HEIDENHAIN TNC 407 (280 580) User Manual User Manual
Page 190

7-5
TNC 425/TNC 415 B/TNC 407
7
Programming with Q Parameters
Q Parameters Instead of Numerical Values
Example for exercise: Full circle
Circle Center CC:
X
= 50 mm
Y
= 50 mm
Beginning and end of
the circular arc C:
X
= 50 mm
Y
=
0 mm
Milling depth:
Z
M
= –5 mm
Tool Radius:
R
= 15 mm
–5
50
50
Y
X
Z
CC
Part program without Q parameters
0
BEGIN CIRCLE MM ...................................................... Begin program
1
BLK FORM 0.1 Z X+0 Y+0 Z–20 ................................... Define the workpiece blank
2
BLK FORM 0.2 X+100 Y+100 Z+0
3
TOOL DEF 6 L+0 R+15 ................................................ Define the tool
4
TOOL CALL 6 Z S500 ................................................... Call the tool data
5
CC X+50 Y+50 .............................................................. Coordinates of the circle center CC
6
L Z+100 R0 F MAX M6 ................................................. Insert the tool
7
APPR CT X+50 Y+0 Z–5 CCA90 R+20 RR F100 M3 .... Approach the contour
8
C X+50 Y+0 DR+ .......................................................... Mill circular arc C around circle center CC; end point at
X = +50 mm and Y = 0; positive direction of rotation
9
DEP CT CCA180 R+30 F100................................. ....... Depart the contour
10
L Z +100 F MAX M2
11
END PGM CIRCLE MM ................................................ Retract the tool and end the program
Part program with Q parameters
0
BEGIN PGM CIRCLEQP MM
1
FN 0: Q1 = +100 ................................................ Clearance height
2
FN 0: Q2 = +30 .................................................. Start position X
3
FN 0: Q3 = –20 ................................................... Start-End pos. Y
4
FN 0: Q4 = +70 .................................................. End position X
5
FN 0: Q5 = –5 ..................................................... Milling depth
6
FN 0: Q6 = +50 .................................................. Center point X
7
FN 0: Q7 = +50 .................................................. Center point Y
8
FN 0: Q8 = +50 .................................................. Circle starting point X
9
FN 0: Q9 = +0 .................................................... Circle starting point Y
10
FN 0: Q10 = +0 .................................................. Tool length L
11
FN 0: Q11 = +15 ................................................ Tool radius R
12
FN 0: Q20 = +100 .............................................. Milling feed rate F
13
BLK FORM 0.1.Z X+0 Y+0 Z–20
14
BLK FORM 0.2 X+100 Y+100 Z+0
15
TOOL DEF 1 L+Q10 R+Q11
16
TOOL CALL 1 Z S1000
17
CC X+Q6 Y+Q7
18
L Z+Q1 R0 FMAX
19
APPR CT X+Q8 Y+Q9 Z+Q5 CCA90 R+20 RR F100 M3
20
C X+Q8 Y+Q9 DR+
21
DEP CT CCA180 R+30 F100
22
L Z+Q1 FMAX M2
23
END PGM CIRCLEQP MM
Blocks 1 to 12:
Assign numerical values
to the parameters
Blocks 13 to 22:
corresponding to blocks 1 to 12
in the program CIRCLE.H