List of M-codes

Next Generation Control Mill Operator's Manual

The Online Interactive Operator's Manual is currently available in English only.

A PDF version of the Operator's Manual is available for download in multiple languages. Click the link below to view the Operator's Manual in your language. Click "Continue" to view the online version in English.

Get a translated PDF Download Continue

This chapter gives detailed descriptions of the M-codes that you use to program your machine.

caution: The sample programs in this manual have been tested for accuracy, but they are for illustrative purposes only. The programs do not define tools, offsets, or materials. They do not describe workholding or other fixturing. If you choose to run a sample program on your machine, do so in Graphics mode. Always follow safe machining practices when you run an unfamiliar program.
note: The sample programs in this manual represent a very conservative programming style. The samples are intended to demonstrate safe and reliable programs, and they are not necessarily the fastest or most efficient way to operate a machine. The sample programs use G-codes that you might choose not to use in more efficient programs.

M-codes are miscellaneous machine commands that do not command axis motion. The format for an M-code is the letter M followed by two to three digits; for example  M03.

Only one M-code is allowed per line of code. All M-codes take effect at the end of the block.

M-codes for Mill
M00 - Stop Program
M01 - Optional Program Stop
M02 - Program End
M03 / M04 / M05 - Spindle Commands
M06 - Tool Change
M07 - Shower Coolant On
M08 / M09 - Coolant
M10 / M11 - 4th Axis Brake
M12 / M13 - 5th Axis Brake
M16 - Tool Change
M19 - Orient Spindle
M21 - M26 - Optional User M Function with M-Fin
M29 - Set Output Relay with M-Fin
M30 - Program End and Reset
M31 - M33 - Chip Conveyor
M34 / M35 - Coolant Increment / Decrement
M36 - Pallet Part Ready
M39 - Rotate Tool Turret
M41 / M42 - Gear Override
M51 - M56 - Set Optional User M-codes
M59 - Set Output Relay
M61 - M66 - Clear Optional User M-codes
M69 - Clear Output Relay
M73 / M74 - Tool Air Blast (TAB)
M75 - Set G35 or G136 Reference Point
M78 - Alarm if Skip Signal Found
M79 - Alarm if Skip Signal Not Found
M80 / M81 - Auto Door
M82 - Tool Unclamp
M83 / M84 - Auto Air Gun
M86 - Tool Clamp
M88 / M89 - Through-Spindle Coolant
M95 - Sleep Mode
M96 - Jump If No Input
M97 - Local Sub-Program Call
M98 - Sub-Program Call
M99 - Sub-Program Return or Loop
M109 - Interactive User Input

Be aware: Many service and repair procedures should be done only by authorized personnel. The service technicians at your Haas Factory Outlet (HFO) have the training, experience, and are certified to do these tasks safely and correctly. You should not do machine repair or service procedures unless you are qualified and knowledgeable about the processes.

Danger: Some service procedures can be dangerous or life-threatening. DO NOT attempt a procedure that you do not completely understand. Contact your Haas Factory Outlet (HFO) and schedule a service technician visit if you have any doubts about doing a procedure.

Feedback