-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhelical-circle-array.ngc
executable file
·92 lines (64 loc) · 1.91 KB
/
helical-circle-array.ngc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
( #11=0.000) (hole x-center) (not-used x-center:0.0)
( #12=0.000) (hole y-center) (not-used y-center:0.0)
(#21=8000.0) (rapid feed rate)
#22=3000.0 (cutting xy-feed rate)
#23=2000.0 (z rate)
#51=3.175 (tool diameter)
#52=10.00 (hole diameter)
#53=[#51/2.0-#52/2.0](helical path radius)
#81=20 (number of holes)
#82=[360.0/#81] (angle between holes)
#83=0.0 (start angle)
#84=[#83] (current angle)
#90=280.0 (radius of placing the holes)
#101=15.0 ( Z safe )
#102=10.0 ( Z start)
#103=0.0 ( Z end )
( #104=2.0) ( Z step )
( #106=[fix[[#102-#103]/[#104]]] ) (number of down steps)
( #107=[fix[[#102-#103]/[#105]]] ) (number of up steps)
( #108=[#101] ) ( current Z)
(move to center)
G0 X[#11] Y[#12] Z[#101]
M98P05L[#81]
M30
O05
#111=[#90*cos[#84]]
#112=[#90*sin[#84]]
(call helical drilling cycle at Xi-111,Yi-112)
M98P20L01
(increase angle to next)
#84=[#84+#82]
M99
O10 (normal drilling cycle)
G00 X [#111] Y [#112] Z [#101]
G00 Z [#102]
G01 Z [#103] F[#23]
G00 Z [#102]
M99
O20 (helical drilling cycle)
(move to center of drilling cycle)
G00 X [#111] Y [#112] Z [#101]
G02 X[#111+#53] R[#53/2.0] Z[#101] F[#22]
G02 X[#111-#53] R[#53] Z[#101-2] F[#22]
G02 X[#111+#53] R[#53] Z12.0 F[#22]
G02 X[#111-#53] R[#53] Z10.0 F[#22]
G02 X[#111+#53] R[#53] Z8.0 F[#22]
G02 X[#111-#53] R[#53] Z6.0 F[#22]
G02 X[#111+#53] R[#53] Z4.0 F[#22]
G02 X[#111-#53] R[#53] Z2.0 F[#22]
G02 X[#111+#53] R[#53] Z0.0 F[#22]
G02 X[#111-#53] R[#53] Z0.0 F[#22]
G02 X[#111+#53] R[#53] Z0.0 F[#22]
G02 X[#111-#53] R[#53] Z0.0 F[#22]
G02 X[#111+#53] R[#53] Z2.0 F[#22]
G02 X[#111-#53] R[#53] Z4.0 F[#22]
G02 X[#111+#53] R[#53] Z6.0 F[#22]
G02 X[#111-#53] R[#53] Z8.0 F[#22]
G02 X[#111+#53] R[#53] Z10.0 F[#22]
G02 X[#111-#53] R[#53] Z12.0 F[#22]
G02 X[#111+#53] R[#53] Z[#101-1] F[#22]
G02 X[#111-#53] R[#53] Z[#101] F[#22]
M99
M30
%