Polar Coordinate Interpolation (G12.1): Milling Circular Features with Rotary Axis
Polar Coordinate Interpolation (G12.1) is a powerful but underused G-code that allows programming linear moves in X/C coordinates — perfect for milling bolt circles, keyways, or slots on cylindrical parts using a rotary axis.
📌 1. What is G12.1?
- G12.1: Activate Polar Interpolation Mode
- G13.1: Cancel Polar Interpolation Mode
Instead of programming arcs with I/J, you program linear moves in C-axis (degrees) and X (radius).
📌 2. Typical Application
- Milling keyways on shafts
- Engraving around a cylinder
- Slotting or drilling equally spaced holes
- Creating circular pockets using rotary axis instead of X/Y interpolation
📌 3. Fanuc Example Program (C-Axis Milling)
%
O1000 (POLAR INTERPOLATION EXAMPLE)
G17 G21 G40 G49 G80 G90
T0101 M06
G54
M19 (ORIENT SPINDLE)
M154 (C-AXIS ENGAGE)
G97 S800 M03
G00 X20.0 C0.0
G12.1 (ENABLE POLAR MODE)
G01 X25.0 C360.0 F200 (MILL FULL CIRCLE)
G13.1 (CANCEL POLAR MODE)
M155 (C-AXIS DISENGAGE)
M30
%
| Block | Function |
|---|---|
M154 | Engage C-axis |
G12.1 | Polar mode ON |
X25.0 | Radius |
C360.0 | Full rotation in degrees |
📌 4. Haas Example with Rotary Table
Haas does not use G12.1 but supports rotary positioning + interpolation.
You can replicate polar motion using G112 (C-axis substitution) on Y-axis lathes.
G112
G01 X25.0 Y360.0 F150.
G113 (Cancel)
📌 5. Programming Tips
- Always engage C-axis or rotary lock before G12.1.
- Program feed in mm/min (G94) for predictable motion.
- Use single-block mode to verify motion before cutting.
- Avoid rapid moves while in polar mode — always feed.
📌 6. Common Mistakes
| Mistake | Result |
|---|---|
| Forgetting M154 | C-axis not locked → part does not rotate |
| Forgetting G13.1 | Remaining in polar mode → wrong positioning after |
| Wrong radius | Cutter moves to wrong location, possible crash |
📌 7. Siemens / Heidenhain Equivalent
- Siemens:
TRANS/ROTtransformations or TRAORI for tool center point control. - Heidenhain: Use PLANE SPATIAL with rotary axis coupling.
📌 8. Advanced Example – Milling Multiple Slots
G12.1
#100=0
WHILE[#100LT360]DO1
G01 X30.0 C[#100+30] F250
G00 X20.0
#100=#100+60
END1
G13.1
This macro mills 6 equally spaced slots around a shaft.
📌 9. Future of Polar Interpolation (2025–2030)
- CAM systems now auto-generate G12.1/G13.1 code for live-tool lathes.
- AI-driven polar interpolation optimizes feed per degree for constant chip load.
- Real-time collision avoidance integrated in controllers.
✅ Conclusion
Polar Coordinate Interpolation (G12.1) is a game-changing technique for cylindrical machining.
By mastering G12.1/G13.1, you simplify rotary programming, reduce cycle time, and make programs shorter and more reliable.
Leave a comment