0% found this document useful (0 votes)
249 views

G - Code M - Code

The document lists common G and M codes used in CNC programming to control machine tool functions and motion. G codes direct tool motion such as rapid moves, linear moves, and circular interpolation. M codes control machine functions like starting/stopping the spindle, coolant control, and ending programs. The document also lists typical codes used for values like feed rates, spindle speeds, tool numbers, and coordinate positions.

Uploaded by

blashkog
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
249 views

G - Code M - Code

The document lists common G and M codes used in CNC programming to control machine tool functions and motion. G codes direct tool motion such as rapid moves, linear moves, and circular interpolation. M codes control machine functions like starting/stopping the spindle, coolant control, and ending programs. The document also lists typical codes used for values like feed rates, spindle speeds, tool numbers, and coordinate positions.

Uploaded by

blashkog
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

A basic list of G operation codes is given below. These direct motion of the tool.

G00 - Rapid move (not cutting) G01 - Linear move G02 - Clockwise circular motion G03 - Counterclockwise circular motion G04 - Dwell G05 - Pause (for operator intervention) G08 - Acceleration G09 - Deceleration G17 - x-y plane for circular interpolation G18 - z-x plane for circular interpolation G19 - y-z plane for circular interpolation G20 - turning cycle or inch data specification G21 - thread cutting cycle or metric data specification G24 - face turning cycle G25 - wait for input to go low G26 - wait for input to go high G28 - return to reference point G29 - return from reference point G31 - Stop on input G33-35 - thread cutting functions G35 - wait for input to go low G36 - wait for input to go high G40 - cutter compensation cancel G41 - cutter compensation to the left G42 - cutter compensation to the right G43 - tool length compensation, positive G44 - tool length compensation, negative G50 - Preset position G70 - set inch based units or finishing cycle G71 - set metric units or stock removal G72 - indicate finishing cycle G72 - 3D circular interpolation clockwise G73 - turning cycle contour G73 - 3D circular interpolation counter clockwise G74 - facing cycle contour G74.1 - disable 360 deg arcs G75 - pattern repeating G75.1 - enable 360 degree arcs G76 - deep hole drilling, cut cycle in z-axis G77 - cut-in cycle in x-axis Version 2 EE IIT, Kharagpur 16

G78 - multiple threading cycle G80 - fixed cycle cancel G81-89 - fixed cycles specified by machine tool manufacturers G81 - drilling cycle G82 - straight drilling cycle with dwell G83 - drilling cycle G83 - peck drilling cycle G84 - taping cycle G85 - reaming cycle G85 - boring cycle G86 - boring with spindle off and dwell cycle G89 - boring cycle with dwell G90 - absolute dimension program G91 - incremental dimensions G92 - Spindle speed limit G93 - Coordinate system setting G94 - Feed rate in ipm G95 - Feed rate in ipr G96 - Surface cutting speed G97 - Rotational speed rpm G98 - withdraw the tool to the starting point or feed per minute G99 - withdraw the tool to a safe plane or feed per revolution G101 - Spline interpolation M-Codes control machine functions. M00 - program stop M01 - optional stop using stop button M02 - end of program M03 - spindle on CW M04 - spindle on CCW M05 - spindle off M06 - tool change M07 - flood with coolant M08 - mist with coolant M08 - turn on accessory (e.g. AC power outlet) M09 - coolant off M09 - turn off accessory M10 - turn on accessory M11 - turn off accessory or tool change M17 - subroutine end M20 - tailstock back M20 - Chain to next program M21 - tailstock forward M22 - Write current position to data file M25 - open chuck M25 - set output #1 off M26 - close chuck M26 - set output #1 on Version 2 EE IIT, Kharagpur 17

M30 - end of tape (rewind) M35 - set output #2 off M36 - set output #2 on M38 - put stepper motors on low power standby M47 - restart a program continuously, or a fixed number of times M71 - puff blowing on M72 - puff blowing off M96 - compensate for rounded external curves M97 - compensate for sharp external curves M98 - subprogram call M99 - return from subprogram, jump instruction M101 - move x-axis home M102 - move y-axis home M103 - move z-axis home Some other typical codes and keywords used in part programs are given below. Annn - an orientation, or second x-axis spline control point Bnnn - an orientation, or second y-axis spline control point Cnnn - an orientation, or second z-axis spline control point, or chamfer Fnnn - a feed value (in ipm or m/s, not ipr), or thread pitch Innn - x-axis center for circular interpolation, or first x-axis spline control point Jnnn - y-axis center for circular interpolation, or first y-axis spline control point Knnn - z-axis center for circular interpolation, or first z-axis spline control point Lnnn - arc angle, loop counter and program cycle counter Nnnn - a sequence/line number Onnn - subprogram block number Pnnn - subprogram reference number Rnnn - a clearance plane for tool movement, or arc radius, or taper value Qnnn - peck depth for pecking cycle Snnn - cutting speed (rpm), spindle speed Tnnn - a tool number Unnn - relative motion in x Vnnn - relative motion in y Wnnn - relative motion in z Xnnn - an x-axis value Ynnn - a y-axis value Znnn - a z-axis value ; - starts a comment , or end of block

You might also like