---
title: Supported M-codes
slug: supported-m-codes
docTags: 
createdAt: 2022-03-24T17:49:56.000Z
---

| M Code                               | Meaning                                                                                                                                  |
| ------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------- |
| [M0](docId\:LHmMbAy23Q7kqBe9WDV0_)   | Program stop                                                                                                                             |
| [M1](docId\:LHmMbAy23Q7kqBe9WDV0_)   | Optional program stop                                                                                                                    |
| [M2](docId\:LHmMbAy23Q7kqBe9WDV0_)   | Program end                                                                                                                              |
| [M3](docId\:LCGnVkPx_hp4rq3G5m9QV)   | Turn spindle clockwise                                                                                                                   |
| [M4](docId\:LCGnVkPx_hp4rq3G5m9QV)   | Turn spindle counterclockwise                                                                                                            |
| [M5](docId\:LCGnVkPx_hp4rq3G5m9QV)   | Stop spindle turning                                                                                                                     |
| [M6](docId\:kQG7dD1dpwUw3hchbArUT)   | Tool change                                                                                                                              |
| [M7](docId\:CKpEEqps6uVHTMidSiRnR)   | Mist coolant on                                                                                                                          |
| [M8](docId\:CKpEEqps6uVHTMidSiRnR)   | Flood coolant on                                                                                                                         |
| [M9](docId\:CKpEEqps6uVHTMidSiRnR)   | Mist and flood coolant off                                                                                                               |
| M10                                  | Laser off (PWM off)                                                                                                                      |
| M11                                  | Laser on with Power S                                                                                                                    |
| [M20](docId:4KZjVMWs8l4YNN6N5ZmcB)   | Plasma Torch Height Control ON                                                                                                           |
| [M21](docId:4KZjVMWs8l4YNN6N5ZmcB)   | Plasma Torch Height Control OFF                                                                                                          |
| [M22](docId:4KZjVMWs8l4YNN6N5ZmcB)   | M23 Q… Set Plasma THC set point value                                                                                                    |
| [M26](docId\:b-HT95-u-CRzgtMitKpI8)  | Enable rotary axis clamping                                                                                                              |
| [M27](docId\:b-HT95-u-CRzgtMitKpI8)  | Disable rotary axis clamping                                                                                                             |
| [M30](docId\:LHmMbAy23Q7kqBe9WDV0_)  | Program end, spindle and coolants off, and rewind                                                                                        |
| [M48](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Enable speed and feed overrides                                                                                                          |
| [M49](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Disable speed and feed overrides                                                                                                         |
| [M50](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Set feed override                                                                                                                        |
| [M51](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Set speed override                                                                                                                       |
| [M52](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Enable feed override by analog input                                                                                                     |
| [M53](docId\:C9jbUdjZJbt5_JzMT_hWm)  | Enable feed hold input                                                                                                                   |
| [M54](docId\:pkHadTeLJOSp0wTTu_1dJ)  | Set general-purpose output                                                                                                               |
| [M55](docId\:pkHadTeLJOSp0wTTu_1dJ)  | Clear general-purpose output                                                                                                             |
| [M56](docId\:pkHadTeLJOSp0wTTu_1dJ)  | Read general-purpose input                                                                                                               |
| [M57](docId\:pkHadTeLJOSp0wTTu_1dJ)  | Read general-purpose output                                                                                                              |
| [M60](docId\:LHmMbAy23Q7kqBe9WDV0_)  | Program stop, use this with nesting instead of M30 so that the spindle/coolants remain on during the transition from one to the next run |
| M80                                  | Drive enable ON                                                                                                                          |
| M81                                  | Drive enable OFF                                                                                                                         |
| [M90](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Standard Head/spindle                                                                                                                    |
| [M91](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Alternate Head/2nd spindle                                                                                                               |
| [M92](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Alternate Head/3rd spindle                                                                                                               |
| [M93](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Alternate Head/4th spindle                                                                                                               |
| [M95](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Alternate Head/Probe                                                                                                                     |
| [M97](docId\:LCGnVkPx_hp4rq3G5m9QV)  | Alternate Head/Camera                                                                                                                    |

:::hint{type="info"}
Note that a head may as well be e.g. a tangential knife configuration.
:::

## 3D printing specials

| M Code                                | Meaning                                                      |
| ------------------------------------- | ------------------------------------------------------------ |
| [M104](docId\:HHDBn9QPO179onaPOasZL)  | Set extruder temperature                                     |
| [M106](docId\:HHDBn9QPO179onaPOasZL)  | Workpiece cooling fan on                                     |
| [M107](docId\:HHDBn9QPO179onaPOasZL)  | Workpiece cooling fan off                                    |
| [M109](docId\:HHDBn9QPO179onaPOasZL)  | M109 S... Set extruder temperature and wait until reached    |
| [M140](docId\:HHDBn9QPO179onaPOasZL)  | M140 S... Bed temperature                                    |
| [M143](docId\:HHDBn9QPO179onaPOasZL)  | M143 S... Maximum Hot-end temperature to prevent overheating |
| [M190](docId\:HHDBn9QPO179onaPOasZL)  | M190 Wait for bed temperature to reach the target value      |

