Smithy CNC Mills User Manual
Page 39

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.
3.2 M3, M4, M5: Spindle Control
To start the spindle turning clockwise at the currently programmed speed, pro-
gram M3.
To start the spindle turning counterclockwise at the currently programmed
speed, program M4.
To stop the spindle from turning, program M5.
It is OK to use M3 or M4 if the spindle speed is set to zero. If this is done (or if
the speed override switch is enabled and set to zero), the spindle will not start
turning. If, later, the spindle speed is set above zero (or the override switch is
turned up), the spindle will start turning. It is OK to use M3 or M4 when the
spindle is already turning or to use M5 when the spindle is already stopped.
3.3 M6: Tool Change
To change a tool in the spindle from the tool currently in the spindle to the tool
most recently selected (using a T word - see Section [sub:T:-Select-Tool]), pro-
gram M6. When the tool change is complete:
* The spindle will be stopped.
* The tool that was selected (by a T word on the same line or on any line after
the previous tool change) will be in the spindle. The T number is an integer
giving the changer slot of the tool (not its id).
* If the selected tool was not in the spindle before the tool change, the tool
that was in the spindle (if there was one) will be in its changer slot.
* The coordinate axes will be stopped in the same absolute position they were
in before the tool change (but the spindle may be re-oriented).
* No other changes will be made. For example, coolant will continue to flow
during the tool change unless
SmithyCNC Programmer’s Reference Manual: M Codes
3-3