HOME / Q & A / About Controller / 2-Controller problems

●How to write G.M CODE

Ans:

About the cutting stroke of the tool during processing The standard stroke (current situation) and the machining stroke you want, according to our experience and tool life, are not very related.

However, the cutting stroke that your company thinks will increase the processing time. For example, using 12.7mm to cut a 24mm keyway, the standard current processing stroke, only need to cut 2 cuts, For the cutting stroke you want, you must cut 3 cuts (a waste of time). If your company wants to cut in your own way, you can use it yourself, G.M Code compiles the processing program, Please refer to the operation manual for writing method.

Now give an example to demonstrate how to write G.M CODE as follows,

Press the F2 program editing key → press F8 file management → F1 to open a new file → enter the file name → start writing G.M Code program

G90 G54 G00 X0 Y0 C180 (assuming tool width 12.7, key width 36.0) M03 (Spindle start) M80 (Check that the feed is at the upper safe position)

1 time G201 X╴ Y╴ K O. A0.05 U12.7V╴ Q 1 E 5.0 (5.0 for safety) (Manual P61) G00 X11.65 Y0 M80 (Check that the feed is at the upper safe position)

2 times G201 X╴ Y╴ K O. A0.05 U12.7V╴ Q 1 E 5.0 (Manual P62) G00 X-11.65 Y0 M80 (Check that the feed is at the upper safe position)

3 times G201.1 X╴ Y╴ K O. A0.05 U12.7V╴ Q 1 E 5.0 End face G401 X╴ Y╴ W O. A6.0 U36. Q 1 P 12.7 M05 G90 G00 X╴ Y╴ C0. M30 (Set the coordinates of the workpiece replacement position)