This page 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.
|M01||Optional Stop Program|
|M03||Spindle On Fwd|
|M04||Spindle On Rev|
|M08 / M09||Coolant On / Off|
|M10 / M11||Chuck Clamp / Unclamp|
|M12 / M13||Auto Jet Air Blast On / Off (Optional)|
|M14 / M15||Main Spindle Brake On /Off (Optional C-Axis)|
|M17||Turret Rotation Fwd|
|M18||Turret Rotation Rev|
|M19||Orient Spindle (Optional)|
|M21||Tailstock Advance (Optional)|
|M22||Tailstock Retract (Optional)|
|M23||Chamfer Out of Thread On|
|M24||Chamfer Out of Thread Off|
|M30||End of Program and Reset|
|M31||Chip Auger Forward (Optional)|
|M33||Chip Auger Stop (Optional)|
|M35||Parts Catcher Part-Off Position|
|M36||Parts Catcher On (Optional)|
|M37||Parts Catcher Off (Optional)|
|M38 / M39||Spindle Speed Variation On / Off|
|M41 / M42||Low / High Gear (Optional)|
|M43||Turret Unlock (Service Use Only)|
|M44||Turret Lock (Service Use Only)|
|M51 - M56||Turn On Built-In M-Code Relay|
|M59||Turn On Output Relay|
|M61 - M66||M61 - M66 Turn Off Built-In M-Code Relay|
|M69||Turn Off Output Relay|
|M78||Alarm if Skip Signal Found|
|M79||Alarm if Skip Signal Not Found|
|M85 / M86||Automatic Door Open / Close (Optional)|
|M88 / M89||High Pressure Coolant On / Off (Optional)|
|M90 / M91||Fixture Clamp Input On / Off|
|M96||Jump If No Signal|
|M97||Local Subprogram Call|
|M99||Subprogram Return Or Loop|
|M104 / M105||Probe Arm Extend / Retract (Optional)|
|M109||Interactive User Input|
|M110||Secondary Spindle Chuck Clamp (Optional)|
|M111||Secondary Spindle Chuck Unclamp (Optional)|
|M112 / M113||Secondary Spindle Air Blast On / Off (Optional)|
|M114 / M115||Secondary Spindle Brake On / Off (Optional)|
|M119||Secondary Spindle Orient (Optional)|
|M121- M126||M121 - M126 Built-In M-Codes Relays with M-Fin|
|M129||Turn On M-Code Relay with M-Fin|
|M130 / M131||Display Media / Cancel Display Media|
|M133||Live Tool Fwd (Optional)|
|M134||Live Tool Rev (Optional)|
|M135||Live Tool Stop (Optional)|
|M138||Spindle Speed Variation On|
|M139||Spindle Speed Variation Off|
|M143||Secondary Spindle Forward (Optional)|
|M144||Secondary Spindle Reverse (Optional)|
|M145||Secondary Spindle Stop (Optional)|
|M146 / M147||Steady Rest Clamp / Unclamp (Optional)|
|M158 / M159||Mist Condenser On/Off|
|M170 / M171||Engage 4th Axis Brake / Release 4th Axis Brake|
|M214 / M215||Live Tool Brake On/Off|
|M219||Live Tool Orient (Optional)|
|M299||APL / Part Load / or Program End|
|M300||M300 - APL/Robot Custom Sequence|
|M334 / M335||P-Cool Increment / P-Cool Decrement|
|M373 / M374||Tool Air Blash (TAB) On/OFF|
|M388 / M389||Through-Spindle Coolant On / Off|
To make this site work properly, we sometimes place small data files called cookies on your device. Most big websites do this too.
A cookie is a small text file that a website saves on your computer or mobile device when you visit the site. It enables the website to remember your actions and preferences (such as login, language, font size and other display preferences) over a period of time, so you don’t have to keep re-entering them whenever you come back to the site or browse from one page to another.
USD prices DO NOT include customs duty, customs fees, insurance, VAT, or freight.
CNY prices include customs duty, customs fees, insurance, and VAT. DOES NOT include freight.
This price includes shipping cost, export and import duties, insurance, and any other expenses incurred during shipping to a location in France agreed with you as a buyer. No other mandatory costs can be added to the delivery of a Haas CNC Product.
KEEP UP WITH THE LATEST HAAS TIPS AND TECHNOLOGY...
HAAS TOOLING ACCEPTS THE FOLLOWING:
2800 Sturgis Rd., Oxnard, CA 93030 / Toll Free: 800-331-6746
Phone: 805-278-1800 / Fax: 805-278-2255