CNC milling machines allow for precise control over the movement of the cutter during the machining process. One of the capabilities of these machines is to mill arcs, which is often done using the G2 command. This command is used for clockwise arc movements in the XY plane.
Usage Format
The general format for a G2 command in CNC programming is as follows:
G2 X_ Y_ I_ J_ F_
Where:
- X_ and Y_ are the end point coordinates of the arc.
- I_ and J_ are the distances from the starting point to the center of the arc along the X and Y axes, respectively.
- F_ is the feed rate.
Explanation
The G2 command is a modal command, meaning it remains active until another command changes the mode. When programming an arc, the I and J values are crucial as they define the arc’s radius and position relative to the starting point. It’s important to note that I and J are incremental values from the starting point of the arc, not absolute positions.
Example
Let’s consider an example where we want to mill a quarter-circle arc with a radius of 10 units.
Text Diagram:
Starting Point (P1)
|
| (I,J)
| *
| * *
| * *
| * *
*---------------*
P1 End Point (P2)
CNC Program:
N100 G17 G90 G54
N110 T1 M6
N120 S1500 M3
N130 G0 X0 Y0
N140 G43 Z5 H1 M8
N150 G1 Z-5 F100
N160 G2 X10 Y10 I10 J0 F150
N170 G0 Z5
N180 M30
In this program:
- N100 sets the plane and positioning mode, and selects the work offset.
- N110 selects the tool and activates the spindle.
- N130 moves the cutter to the starting point of the arc at X0 Y0.
- N140 positions the cutter above the workpiece.
- N150 initiates the milling process by moving the cutter down.
- N160 is our arc command, milling a quarter-circle clockwise from the starting point to X10 Y10 with a radius of 10 units.
- N170 retracts the cutter.
- N180 ends the program.
This example demonstrates how to use the G2 command with I and J values to mill a precise arc on a CNC machine.