M0, M1, M2, M30, M60: Program Stopping and Ending
To stop a running program temporarily (regardless of the setting of the optional stop switch), program M0.
To stop a running program temporarily (but only if the optional stop switch is on), program M1.
It is OK to program M0 and M1 in MDI mode, but the effect will probably not be noticeable, because normal behavior in MDI mode is to stop after each line of input, anyway.
To exchange pallet shuttles and then stop a running program temporarily (regardless of the setting of the optional stop switch), program M60.
If a program is stopped by an M0, M1, or M60, pressing the cycle start button will restart the program at the following line.
To end a program, program M2. To exchange pallet shuttles and then end a program, program M30. Both of these commands have the following effects.
1. Axis offsets are set to zero (like G92.2) and origin offsets are set to the default (like G54).
2. Selected plane is set to CANON_PLANE_XY (like G17).
3. Distance mode is set to MODE_ABSOLUTE (like G90).
4. Feed rate mode is set to UNITS_PER_MINUTE (like G94).
5. Feed and speed overrides are set to ON (like M48).
6. Cutter compensation is turned off (like G40).
7. The spindle is stopped (like M5).
8. The current motion mode is set to G_1 (like G1).
9. Coolant is turned off (like M9).
No more lines of code in an RS274/NGC file will be executed after the M2 or M30 command is executed. Pressing cycle start will start the program back at the beginning of the file.
- About Us
- AutoMate CNC Lathe
- AutoMateCNC Lathe Overview
- Talon LT-1320 Small Shop Tool Room Lathe
- Talon LT-1440 Small Shop Tool Room Lathe
- Raptor ST-1116 Slant Bed Tool Room Lathe
- Raptor XT-1126 Tool Room Lathe
- Talon GL-1108 Small Shop Gang Tool Lathe
- Raptor GS-1113 Slant Bed Gang Tool Lathe
- Raptor TC-1417 Compact Turret Lathe
- Raptor TS-1117 Slant Bed Turret Lathe
- Granite 3-in-1
- Midas 3-in-1
- Milling Set-Up
- Machine Kits
- Granite CNC Kits
- CNC Reference Info
- 1. Language Overview
- 2. Coordinate System and G92 Offsets
- 3. G Codes Best Practices
- 4. Order of Execution
- 5. M Codes
- M0, M1, M2, M30, M60: Program Stopping and Ending
- M3, M4, M5: Spindle Control
- M6: Tool Change
- M7, M8, M9: Coolant Control
- M48, M49: Override Control
- M50: Feed Overrride Control
- M51: Spindle Speed Override Control
- M52: Adaptive Feed Control
- M53: Feed Stop Control
- M62 to M65: Digital IO Control
- M100 to M199: User Defined Commands
- 6. 0 Codes
- 7. Other Codes
- 8. Mill Canned Cycles
- 9. Tool File Compensation