Home > Publications >

Main list of M-code

Mcode

Codes with the address M are called auxiliary and are designed to control the operating modes of the machine.

M-codes:

Codes Description
M00 Compulsory stop
M01 Optional stop
M02 End of program
M03 Spindle on (clockwise rotation)
M04 Spindle on (counterclockwise rotation)
M05 Spindle stop
M06 Automatic tool change (ATC)
M07 Coolant on (mist)
M08 Coolant on (flood)
M09 Coolant off
M10 Pallet clamp on
M11 Pallet clamp off
M13 Spindle on (clockwise rotation) and coolant on (flood)
M19 Spindle orientation
M21 Mirror, X-axis
M21 Tailstock forward
M22 Mirror, Y-axis
M22 Tailstock backward
M23 Mirror OFF
M23 Thread gradual pullout ON
M24 Thread gradual pullout OFF
M30 End of program, with return to program top
M41 Gear select – gear 1
M42 Gear select – gear 2
M43 Gear select – gear 3
M44 Gear select – gear 4
M48 Feedrate override allowed
M49 Feedrate override NOT allowed
M52 Unload Last tool from spindle
M60 Automatic pallet change (APC)
M98 Subprogram call
M99 Subprogram end

Subscribe to our news
and regular updates