G98 vs G99: Understanding Return Levels in CNC Drilling Cycles
When using canned cycles like G81 or G83, the return position of the tool after drilling is controlled by G98 and G99. Misusing these can slow your program or cause unexpected motion.
🛠 What Do G98 and G99 Do?
| Code | Return To Position | Behavior Description |
|---|---|---|
| G98 | Initial Point (Z before cycle) | Retracts to original Z before drilling |
| G99 | R Point (Retract Level) | Retracts only to the specified R-level |
- G98 is safer but slower
- G99 is faster and used for repetitive drilling close to the surface
📐 Drilling Cycle with G98 Example
G90 G00 X0 Y0
G98 G81 Z-10.0 R2.0 F100
X20 Y0
X40 Y0
G80
What happens:
- Drill starts at current Z (e.g., Z10.0)
- Rapid down to
R2.0, feed toZ-10.0 - Retracts to initial Z position (Z10.0)
- Moves to next hole, repeats
✅ Use when obstacles exist above the part (like clamps)
📈 G99 Drilling Cycle Example
G90 G00 X0 Y0
G99 G81 Z-10.0 R2.0 F100
X20 Y0
X40 Y0
G80
What happens:
- Drill retracts only to
R2.0after each hole - Faster because tool stays low
- Efficient for parts with flat surfaces and no obstacles
🎯 When to Use G98 vs G99
| Use Case | Recommended Code |
|---|---|
| Obstructions/fixtures | G98 |
| Fast drilling on flat part | G99 |
| High-speed production | G99 |
| First hole after rapid | G98 |
⚠️ Common Mistakes
- Forgetting to switch from G98 to G99 after first hole
- Setting
Rvalue too low → causes tool crash - Using G99 without checking for clamps or vises
✅ Pro Tips
- Always visualize the return height in simulation
- First use
G98for clearance, then switch toG99 - Use
G80to cancel drilling cycles after usage
🧪 Visual Example
Assume:
- Initial Z = 50.0
- R = 2.0
- Z drilling depth = -10.0
| Command | Tool Movement After Hole |
|---|---|
| G98 | Back to Z50.0 (initial) |
| G99 | Back to Z2.0 (R plane) |
🧠 Summary
G98= safer but slower → returns to initial ZG99= efficient → returns to R point- Choose based on setup safety and speed
- Always end cycles with
G80
Leave a comment