Example program · Mill
Counterbore Holes for M6 Socket Head Screws — G-Code Example
Drills Ø6.6 clearance holes and counterbores them Ø11 × 6.5 deep for M6 socket head cap screws, with a dwell for a flat bottom.
Drills Ø6.6 clearance holes and counterbores them Ø11 × 6.5 deep for M6 socket head cap screws, with a dwell for a flat bottom.
| Item | Value |
|---|---|
| Machine | CNC mill / machining centre (Fanuc-style) |
| Units | Metric (G21) |
| Lines | 22 |
Program
O1010 (M6 SHCS COUNTERBORES)
G21 G17 G40 G49 G80 G90
T9 M06 (6.6 MM DRILL)
G54 G00 X15. Y15.
S1500 M03
G43 H09 Z25. M08
G98 G81 Z-22. R2. F180.
X55.
G80
G91 G28 Z0
G90
T10 M06 (11 MM COUNTERBORE)
G54 G00 X15. Y15.
S900 M03
G43 H10 Z25.
G98 G82 Z-6.5 R2. P300 F80.
X55.
G80
M09
G91 G28 Z0
G90
M30▶ Simulate in the G-code viewer
How it works
- ISO 4762 M6 heads are Ø10 × 6 mm; Ø11 × 6.5 leaves clearance and sinks the head below the surface.
- G82 dwell (P300 = 0.3 s) cleans the counterbore floor.
Codes used in this program
Always check feeds, speeds, offsets and clearances for your own machine and tooling, and prove new programs with single block and reduced rapid.
More milling programs
- Face Milling Program (Zig-Zag Passes)
- Outside Contour with Cutter Compensation (G41)
- Circular Pocket with Helical Entry
- Bolt Hole Circle with Polar Coordinates (G16)
- Peck Drilling a Hole Grid (G83)
- Rigid Tapping Program (M8 × 1.25)
- Internal Thread Milling M12 × 1.75
- Rectangular Pocket in Depth Passes Using a Subprogram
- Machining Multiple Parts with G54–G57
- Fine Boring a Precision Bore (G76 on a Mill)
- Milling a Slot with Ramping Entry
- Chamfering an Outside Edge with a Chamfer Mill
- Parametric Bolt Circle Macro (WHILE Loop)
- Spindle Warm-Up Program
- Setting a Work Offset Automatically with a Probe (G31)
- GRBL Router: Rectangle Cut-Out in Depth Passes
- GRBL / LinuxCNC Touch Plate Z Probe (G38.2)
- Haas G12 / G13 Circular Pocket in One Line
- Haas M97 Local Subprogram for Repeated Features
- High-Speed Peck Drilling in Aluminum (G73)
- Helical Boring a Ø20 Hole with a 10 mm End Mill