CNC Programming for Deep Hole Drilling Cycles: G76 and G87
CNC programming for deep hole drilling is fundamentally different from conventional drilling programming. The program must manage not just tool motion but coolant pressure, chip evacuation timing, feed reduction at entry and exit, and multiple retracts to clear chips. A poorly programmed deep hole cycle produces broken drills and scrapped parts regardless of machine capability.
Tip: Standard G83 peck cycles are not suitable for gun drilling or BTA drilling. These processes require continuous feed with specific coolant pressure management. Use custom macros or machine builder cycles for production deep hole drilling.
What is the difference between G73 and G83 for deep hole drilling?
G73 (high-speed peck) retracts only a small distance (d parameter) per peck — typically 0.5–2 mm — which breaks chips but does not fully clear them. G83 retracts fully to the R-plane per peck, fully clearing chips but taking more time. Use G73 for shallow holes where chip breaking is sufficient; use G83 for deeper holes where chip evacuation is critical.
No — gun drilling requires continuous feed with no peck retracts. Each retract in gun drilling causes the drill to re-enter the hole, risking walking and guide pad damage. Gun drilling uses a custom macro with continuous feed and coolant pressure management. Some machine builders provide a dedicated gun drilling cycle that maintains spindle speed and coolant pressure during retracts.
How do I program feed rate reduction at hole entry and exit?
Program the entry and exit sections as separate G01 moves with reduced feed rate, then transition to a higher feed rate for the main drilling section. Alternatively, use a custom macro that applies feed rate scaling based on current depth as a percentage of total depth. The typical pattern is 50–70% feed at entry, 100% for the main section, and 50–70% at break-through.
What coolant M-codes are used in deep hole drilling cycles?
Common coolant M-codes for deep hole drilling include: M08 (flood coolant), M88 or M50 (high-pressure coolant on), M89 or M51 (high-pressure coolant off), and M07 (mist coolant). The specific M-codes vary by machine builder — always check the machine manual. High-pressure coolant should be activated before the spindle starts feeding and turned off after the tool clears the hole.
G87 requires special setup: the tool starts with an offset (Q) to clear the bore, rapids to Z depth (behind the bore), returns to center, feeds in the Z+ direction to back bore, dwells at the end, offsets again, and rapids out. The tool must have a clearance pass before entering the bore. G87 is used when the bore cannot be reached from the front side of the part.
CNC programming for deep hole drilling requires process-specific cycles and parameters. Standard peck cycles are adequate for shallow holes, but production deep hole drilling demands custom macros and proper feed rate management. This article reflects industry practice as of 2026.