G Code G12.1
If you are going to use driven tool in the lathe
(turning) you need to have a machine with C-axis capacity and of course, driven
tools.
You got to tell the machine that you will use G17, edge plane, the front of the turning workpiece (the radial surface is G19, normal turn is G18)
G12.1 make your lathe to a mlling machine.
Code with explanatons
O1111
N5 G10 P0 Z-100 (Workplane, zero point)
N10 G28 U0 W0 (tool change position, same as G53..)
N15 T0707 (tool change)
G0 Z3 X40 (start point for X, sensitive setting!)
N20 G97 S800
N25 G94 F200
N30 M52 (start c-axis)
G0 C0 (zero c-axis, same as startpoint in X)
N35 M13 (driven spindel tool M3)
G12.1 (milling)
G1 X0 C9.5 (startpoint for the circular mill)
N45 G1 Z-3 (go deep)
G2 X0 C-9.5 R9.5 (circle/2)
G2 X0 C9.5 R9.5 (circle/2)
N50 G1 Z0
N55 M30
Programing in G12.1 in the most machines make you use
a standard mill programming on the face of the turning workpices.
The coordinates are in this case, X and C (as Y) and Z
X has got its half value (diameter to radius)
C has its real value (same as Y in a mill program)
Z has its real value (depth value, as a mill program)
You need to make a proper start point before the mill
programming.
For X and Z, before G12.1
For C (Y) after M52 (C-axis dependent, use before G12.1)
You may got the error "going thrugh pole" othervise
that error reveals itselfs when the programming you make is impossible for the machine to do, try an other tool path to solve this
To leave the mill setting:
G13.1 (milling off, return to G18)
M53 (C-axis off)