A code that is not on this list is not skipped. The block stops and the program ends,
deliberately: running a move without the compensation or transformation it asked for looks
like a normal move right up until it is not.
| Code | Does |
|---|
G0 | rapid positioning |
G1 | linear feed |
G2 / G3 | circular feed, clockwise / counter-clockwise |
G33 | thread cutting, constant pitch |
G34 / G35 | thread cutting, increasing / decreasing pitch |
G6.2 | NURBS interpolation |
| Code | Does |
|---|
G17 / G18 / G19 | working plane XY / XZ / YZ |
G20 / G21 | inches / millimetres |
G70 / G71 | inches / millimetres, the DIN spelling |
G90 / G91 | absolute / incremental |
| Code | Does |
|---|
G93 | inverse time feed |
G94 | feed per minute |
G95 | feed per revolution |
G96 | constant surface speed |
G97 | direct spindle speed |
| Code | Does |
|---|
G53 | one block in machine coordinates |
G54 … G59 | select work coordinate system 1 to 6 |
G59.1 / G59.2 / G59.3 | work coordinate system 7 / 8 / 9 |
G52 | local coordinate shift |
G92 | set the coordinate system from the current position |
G92.1 / G92.2 / G92.3 | cancel, suspend, restore that shift |
G54.4 | workpiece setting error compensation |
G10 | write an offset; see Tool & Work Offsets |
| Code | Does |
|---|
G40 | cutter compensation off |
G41 / G42 | cutter compensation left / right |
G41.2 / G42.2 | 3D cutter compensation, left / right |
G43 / G44 | tool length offset, positive / negative |
G49 | tool length offset off |
G43.4 / G43.5 | tool centre point control |
G43.8 / G43.9 | tool direction compensation / retained TCPC |
G45 … G48 | single and double tool offset increase and decrease |
| Code | Does |
|---|
G73 | peck drilling, short retract to break the chip |
G74 | left-hand tapping |
G76 | fine boring: orient the spindle and shift clear |
G80 | cancel the cycle |
G81 | drilling |
G82 | drilling with a dwell at the bottom |
G83 | peck drilling, full retract each peck |
G84 | tapping |
G85 … G89 | boring, in five variants; G87 and G88 run as plain drilling, see Canned Cycles |
G98 / G99 | between holes, return to the initial level / the R plane |
G84.2 / G84.3 | rigid tapping |
See Canned Cycles for what each one does at the bottom of the
hole and the words they take.
| Code | Does |
|---|
G50 / G51 | scaling off / on |
G50.1 / G51.1 | mirroring off / on |
G68 / G69 | coordinate rotation on / off |
G68.2 | tilted working plane |
G53.1 | align the tool to the tilted plane |
G7.1 | cylindrical interpolation |
G12.1 / G13.1 | polar coordinate interpolation on / off |
| Code | Does |
|---|
G61 | exact stop mode |
G62 | automatic corner override |
G64 | continuous path, velocity-based cornering |
G64.1 | continuous path with geometric corner smoothing; P sets the tolerance |
G60 | single-direction positioning |
G9 | exact stop, this block only |
G8 | acceleration control (DIN dialect) |
G5 / G5.1 | high-speed machining modes |
| Code | Does |
|---|
G27 | reference position check |
G28 | return to the reference position. Axis words name an intermediate point to pass through, and only the axes named return: G91 G28 Z0. sends Z alone, straight up |
G29 | return from the reference position |
G30 | return to a second reference position, the same way |
G31 | probe until it triggers; see Probing |
G22 / G23 | obstacle protection on / off. Starts on; G23 is refused from a part program |
G66, the modal macro call, is not implemented. G38.2 is refused. G31 is the
probing move here.
| Code | Does |
|---|
M0 | program stop |
M1 | optional stop |
M2 | program end |
M30 | program end and rewind |
M3 / M4 | spindle on, clockwise / counter-clockwise |
M5 | spindle stop |
M19 | spindle orient |
M6 | tool change |
M7 / M8 | mist / flood coolant on |
M9 | coolant off |
M50 / M51 | coolant 3 / coolant 4 on |
M10 / M11 | clamp / unclamp |
M34 / M35 | normal / reduced clamp pressure |
M25 / M26 | tailstock, two positions |
M54 / M55 | tailstock retract / advance |
M40 … M45 | gear range select |
M48 / M49 | feed and spindle override enable / disable |
M60 | pallet change |
M70 / M71 | punch off / on |
M98 / M99 | call a subprogram / return |
A machine may define M codes of its own beyond these; they reach the PLC unchanged.