Welcome to our simple guide on the M92 CNC code. Whether you are new to CNC programming or an experienced machinist, understanding the M92 code is essential.
This guide will explain everything you need to know about this unit mode command—what it is, when to use it, and why it matters.
(Step-by-step.)
Key Takeaways
- M92 sets the number of steps-per-mm, per-inch, or per-degree for one or more axes in a CNC machine.
- The command affects how many steps will be done for each unit of movement, adjusting the coordinate system to match the machine’s specifications.
- The command format is M92 [Asteps] [Bsteps] [Csteps] [Esteps] [Tindex] [Usteps] [Vsteps] [Wsteps] [Xsteps] [Ysteps] [Zsteps].
- M92 can be used with no parameters to retrieve the current steps-per-unit settings, and M503 can be used on older Marlin versions.
- M92 settings are saved with M500 and loaded with M501 when EEPROM_SETTINGS is enabled, and M502 resets steps-per-unit for all axes to default values.
Understanding M92 CNC Code
What exactly does the M92 CNC code do?
It sets the number of steps-per-mm, per-inch, or per-degree for one or more axes, affecting how many steps will be done for each unit of movement.
You’ll typically work with steps-per-millimeter unless INCH_MODE_SUPPORT is enabled or the machine is a SCARA, and any axis with AXISn_ROTATES enabled is configured in steps-per-degree.
When you use M92, you’re adjusting the coordinate system to match your machine’s specifications.
The command format is straightforward: M92 [Asteps] [Bsteps] [Csteps] [Esteps] [Tindex] [Usteps] [Vsteps] [Wsteps] [Xsteps] [Ysteps] [Zsteps], with each parameter setting the steps per unit for a specific axis.
M-Codes Overview and Functions
You’re likely familiar with M-codes, as they’re used on most machine types and can be customized based on application and user definition. These codes control various functions on your machine, such as program stops, spindle control, and coolant control.
M-Code | Function | Description |
---|---|---|
M00 | Program Stop | Stops the program |
M03 | Spindle Control | Turns on the spindle in a clockwise direction |
M06 | Tool Change | Initiates a tool change |
M08 | Coolant Control | Turns on the coolant |
M05 | Spindle Control | Turns off the spindle |
Understanding M-codes is vital for effective machine operation. By using the right M-code, you can control your machine’s functions, ensuring efficient and accurate production.
CNC Machine Control With M-Codes
As you plunge into CNC machine control, it’s essential to understand the role M-codes play in precise machine operation.
These codes control various functions, including program stops, spindle control, and coolant control, allowing for flexibility and customization in CNC operations.
Some essential M-codes for CNC machine control include:
- M00: Stops a program, allowing for intervention or inspection.
- M03: Turns on the spindle in a clockwise direction, controlling spindle rotation.
- M06: Initiates tool changes, managing tooling systems.
- M08: Turns on the coolant, controlling coolant systems.
M92 Command Usage and Parameters
When controlling CNC machines, precise movement is essential, and M-codes play a significant role in achieving this precision.
The M92 command is used to set the number of steps-per-mm, per-inch, or per-degree for one or more axes. You’ll typically set units in steps-per-millimeter unless INCH_MODE_SUPPORT is enabled or the machine is a SCARA, and any axis with AXISn_ROTATES enabled is configured in steps-per-degree.
The command format is M92 [Asteps] [Bsteps] [Csteps] [Esteps] [Tindex] [Usteps] [Vsteps] [Wsteps] [Xsteps] [Ysteps] [Zsteps], where each parameter sets the steps per unit for the corresponding axis.
You can get the current steps-per-unit settings using M92 with no parameters or M503 on older versions of Marlin.
Notes and Exceptions for M92
The M92 command has several important notes and exceptions to keep in mind when using it to set the number of steps-per-mm, per-inch, or per-degree for one or more axes.
When you use M92, you’re setting the steps-per-unit for your machine, which affects the Feed Rate and tool length offset.
Some key notes to bear in mind:
- With EEPROM_SETTINGS enabled, your M92 settings are saved with M500 and loaded with M501.
- M502 resets steps-per-unit for all axes to default values.
- You can get the current steps-per-unit settings using M92 with no parameters or M503 on older versions of Marlin.
- INCH_MODE_SUPPORT enables inches as the default unit, and SCARA machines have A and B axes configured in steps-per-degree.
CNC Codes Similar to M92
Code | Function/Mode |
---|---|
M90 | Standard Head Programming |
M90.1 | Absolute Programming IJK |
M91.1 | Incremental Programming IJK |
G90 | Absolute Measurements |
G91 | Incremental Measurements |
G92 | Thread Cutting Cycle/Clamp Maximum Spindle Speed |
G94 | Feed Per Minute |
G95 | Feed Per Revolution of the Spindle |
G96 | Constant Surface Speed Control |
G97 | Constant Surface Speed Control Cancel |
G98 | Return to Initial Point in Canned Cycle |
G99 | Return to R Point in Canned Cycle |
Quick Navigation