|
@@ -128,124 +128,123 @@
|
128
|
128
|
* M1 - Same as M0
|
129
|
129
|
* M17 - Enable/Power all stepper motors
|
130
|
130
|
* M18 - Disable all stepper motors; same as M84
|
131
|
|
- * M20 - List SD card
|
132
|
|
- * M21 - Init SD card
|
133
|
|
- * M22 - Release SD card
|
134
|
|
- * M23 - Select SD file (M23 filename.g)
|
135
|
|
- * M24 - Start/resume SD print
|
136
|
|
- * M25 - Pause SD print
|
137
|
|
- * M26 - Set SD position in bytes (M26 S12345)
|
138
|
|
- * M27 - Report SD print status
|
139
|
|
- * M28 - Start SD write (M28 filename.g)
|
140
|
|
- * M29 - Stop SD write
|
141
|
|
- * M30 - Delete file from SD (M30 filename.g)
|
142
|
|
- * M31 - Output time since last M109 or SD card start to serial
|
143
|
|
- * M32 - Select file and start SD print (Can be used _while_ printing from SD card files):
|
144
|
|
- * syntax "M32 /path/filename#", or "M32 S<startpos bytes> !filename#"
|
145
|
|
- * Call gcode file : "M32 P !filename#" and return to caller file after finishing (similar to #include).
|
|
131
|
+ * M20 - List SD card. (Requires SDSUPPORT)
|
|
132
|
+ * M21 - Init SD card. (Requires SDSUPPORT)
|
|
133
|
+ * M22 - Release SD card. (Requires SDSUPPORT)
|
|
134
|
+ * M23 - Select SD file: "M23 /path/file.gco". (Requires SDSUPPORT)
|
|
135
|
+ * M24 - Start/resume SD print. (Requires SDSUPPORT)
|
|
136
|
+ * M25 - Pause SD print. (Requires SDSUPPORT)
|
|
137
|
+ * M26 - Set SD position in bytes: "M26 S12345". (Requires SDSUPPORT)
|
|
138
|
+ * M27 - Report SD print status. (Requires SDSUPPORT)
|
|
139
|
+ * M28 - Start SD write: "M28 /path/file.gco". (Requires SDSUPPORT)
|
|
140
|
+ * M29 - Stop SD write. (Requires SDSUPPORT)
|
|
141
|
+ * M30 - Delete file from SD: "M30 /path/file.gco"
|
|
142
|
+ * M31 - Report time since last M109 or SD card start to serial.
|
|
143
|
+ * M32 - Select file and start SD print: "M32 [S<bytepos>] !/path/file.gco#". (Requires SDSUPPORT)
|
|
144
|
+ * Use P to run other files as sub-programs: "M32 P !filename#"
|
146
|
145
|
* The '#' is necessary when calling from within sd files, as it stops buffer prereading
|
147
|
|
- * M33 - Get the longname version of a path
|
148
|
|
- * M42 - Change pin status via gcode Use M42 Px Sy to set pin x to value y, when omitting Px the onboard led will be used.
|
149
|
|
- * M48 - Measure Z_Probe repeatability. M48 [P # of points] [X position] [Y position] [V_erboseness #] [E_ngage Probe] [L # of legs of travel]
|
150
|
|
- * M75 - Start the print job timer
|
151
|
|
- * M76 - Pause the print job timer
|
152
|
|
- * M77 - Stop the print job timer
|
153
|
|
- * M78 - Show statistical information about the print jobs
|
154
|
|
- * M80 - Turn on Power Supply
|
155
|
|
- * M81 - Turn off Power Supply
|
156
|
|
- * M82 - Set E codes absolute (default)
|
157
|
|
- * M83 - Set E codes relative while in Absolute Coordinates (G90) mode
|
158
|
|
- * M84 - Disable steppers until next move,
|
159
|
|
- * or use S<seconds> to specify an inactivity timeout, after which the steppers will be disabled. S0 to disable the timeout.
|
|
146
|
+ * M33 - Get the longname version of a path. (Requires LONG_FILENAME_HOST_SUPPORT)
|
|
147
|
+ * M42 - Change pin status via gcode: M42 P<pin> S<value>. LED pin assumed if P is omitted.
|
|
148
|
+ * M48 - Measure Z Probe repeatability: M48 P<points> X<pos> Y<pos> V<level> E<engage> L<legs>. (Requires Z_MIN_PROBE_REPEATABILITY_TEST)
|
|
149
|
+ * M75 - Start the print job timer.
|
|
150
|
+ * M76 - Pause the print job timer.
|
|
151
|
+ * M77 - Stop the print job timer.
|
|
152
|
+ * M78 - Show statistical information about the print jobs. (Requires PRINTCOUNTER)
|
|
153
|
+ * M80 - Turn on Power Supply. (Requires POWER_SUPPLY)
|
|
154
|
+ * M81 - Turn off Power Supply. (Requires POWER_SUPPLY)
|
|
155
|
+ * M82 - Set E codes absolute (default).
|
|
156
|
+ * M83 - Set E codes relative while in Absolute (G90) mode.
|
|
157
|
+ * M84 - Disable steppers until next move, or use S<seconds> to specify an idle
|
|
158
|
+ * duration after which steppers should turn off. S0 disables the timeout.
|
160
|
159
|
* M85 - Set inactivity shutdown timer with parameter S<seconds>. To disable set zero (default)
|
161
|
|
- * M92 - Set planner.axis_steps_per_mm - same syntax as G92
|
162
|
|
- * M104 - Set extruder target temp
|
163
|
|
- * M105 - Read current temp
|
164
|
|
- * M106 - Fan on
|
165
|
|
- * M107 - Fan off
|
166
|
|
- * M108 - Stop the waiting for heaters in M109, M190, M303. Does not affect the target temperature.
|
|
160
|
+ * M92 - Set planner.axis_steps_per_mm for one or more axes.
|
|
161
|
+ * M104 - Set extruder target temp.
|
|
162
|
+ * M105 - Report current temperatures.
|
|
163
|
+ * M106 - Fan on.
|
|
164
|
+ * M107 - Fan off.
|
|
165
|
+ * M108 - Break out of heating loops (M109, M190, M303). With no controller, breaks out of M0/M1. (Requires EMERGENCY_PARSER)
|
167
|
166
|
* M109 - Sxxx Wait for extruder current temp to reach target temp. Waits only when heating
|
168
|
167
|
* Rxxx Wait for extruder current temp to reach target temp. Waits when heating and cooling
|
169
|
168
|
* IF AUTOTEMP is enabled, S<mintemp> B<maxtemp> F<factor>. Exit autotemp by any M109 without F
|
170
|
|
- * M110 - Set the current line number
|
171
|
|
- * M111 - Set debug flags with S<mask>. See flag bits defined in enum.h.
|
172
|
|
- * M112 - Emergency stop
|
173
|
|
- * M113 - Get or set the timeout interval for Host Keepalive "busy" messages
|
174
|
|
- * M114 - Output current position to serial port
|
175
|
|
- * M115 - Capabilities string
|
176
|
|
- * M117 - Display a message on the controller screen
|
177
|
|
- * M119 - Output Endstop status to serial port
|
178
|
|
- * M120 - Enable endstop detection
|
179
|
|
- * M121 - Disable endstop detection
|
180
|
|
- * M126 - Solenoid Air Valve Open (BariCUDA support by jmil)
|
181
|
|
- * M127 - Solenoid Air Valve Closed (BariCUDA vent to atmospheric pressure by jmil)
|
182
|
|
- * M128 - EtoP Open (BariCUDA EtoP = electricity to air pressure transducer by jmil)
|
183
|
|
- * M129 - EtoP Closed (BariCUDA EtoP = electricity to air pressure transducer by jmil)
|
184
|
|
- * M140 - Set bed target temp
|
185
|
|
- * M145 - Set the heatup state H<hotend> B<bed> F<fan speed> for S<material> (0=PLA, 1=ABS)
|
186
|
|
- * M149 - Set temperature units
|
187
|
|
- * M150 - Set BlinkM Color Output R: Red<0-255> U(!): Green<0-255> B: Blue<0-255> over i2c, G for green does not work.
|
188
|
|
- * M163 - Set a single proportion for a mixing extruder. Requires MIXING_EXTRUDER.
|
189
|
|
- * M164 - Save the mix as a virtual extruder. Requires MIXING_EXTRUDER and MIXING_VIRTUAL_TOOLS.
|
190
|
|
- * M165 - Set the proportions for a mixing extruder. Use parameters ABCDHI to set the mixing factors. Requires MIXING_EXTRUDER.
|
191
|
|
- * M190 - Sxxx Wait for bed current temp to reach target temp. Waits only when heating
|
192
|
|
- * Rxxx Wait for bed current temp to reach target temp. Waits when heating and cooling
|
|
169
|
+ * M110 - Set the current line number. (Used by host printing)
|
|
170
|
+ * M111 - Set debug flags: "M111 S<flagbits>". See flag bits defined in enum.h.
|
|
171
|
+ * M112 - Emergency stop.
|
|
172
|
+ * M113 - Get or set the timeout interval for Host Keepalive "busy" messages. (Requires HOST_KEEPALIVE_FEATURE)
|
|
173
|
+ * M114 - Report current position.
|
|
174
|
+ * M115 - Report capabilities.
|
|
175
|
+ * M117 - Display a message on the controller screen. (Requires an LCD)
|
|
176
|
+ * M119 - Report endstops status.
|
|
177
|
+ * M120 - Enable endstops detection.
|
|
178
|
+ * M121 - Disable endstops detection.
|
|
179
|
+ * M126 - Solenoid Air Valve Open. (Requires BARICUDA)
|
|
180
|
+ * M127 - Solenoid Air Valve Closed. (Requires BARICUDA)
|
|
181
|
+ * M128 - EtoP Open. (Requires BARICUDA)
|
|
182
|
+ * M129 - EtoP Closed. (Requires BARICUDA)
|
|
183
|
+ * M140 - Set bed target temp. S<temp>
|
|
184
|
+ * M145 - Set heatup values for materials on the LCD. H<hotend> B<bed> F<fan speed> for S<material> (0=PLA, 1=ABS)
|
|
185
|
+ * M149 - Set temperature units. (Requires TEMPERATURE_UNITS_SUPPORT)
|
|
186
|
+ * M150 - Set BlinkM Color R<red> U<green> B<blue>. Values 0-255. (Requires BLINKM)
|
|
187
|
+ * M163 - Set a single proportion for a mixing extruder. (Requires MIXING_EXTRUDER)
|
|
188
|
+ * M164 - Save the mix as a virtual extruder. (Requires MIXING_EXTRUDER and MIXING_VIRTUAL_TOOLS)
|
|
189
|
+ * M165 - Set the proportions for a mixing extruder. Use parameters ABCDHI to set the mixing factors. (Requires MIXING_EXTRUDER)
|
|
190
|
+ * M190 - Sxxx Wait for bed current temp to reach target temp. ** Waits only when heating! **
|
|
191
|
+ * Rxxx Wait for bed current temp to reach target temp. ** Waits for heating or cooling. **
|
193
|
192
|
* M200 - Set filament diameter, D<diameter>, setting E axis units to cubic. (Use S0 to revert to linear units.)
|
194
|
|
- * M201 - Set max acceleration in units/s^2 for print moves (M201 X1000 Y1000)
|
195
|
|
- * M202 - Set max acceleration in units/s^2 for travel moves (M202 X1000 Y1000) Unused in Marlin!!
|
196
|
|
- * M203 - Set maximum feedrate that your machine can sustain (M203 X200 Y200 Z300 E10000) in units/sec
|
197
|
|
- * M204 - Set default acceleration: P for Printing moves, R for Retract only (no X, Y, Z) moves and T for Travel (non printing) moves (ex. M204 P800 T3000 R9000) in units/sec^2
|
|
193
|
+ * M201 - Set max acceleration in units/s^2 for print moves: "M201 X<accel> Y<accel> Z<accel> E<accel>"
|
|
194
|
+ * M202 - Set max acceleration in units/s^2 for travel moves: "M202 X<accel> Y<accel> Z<accel> E<accel>" ** UNUSED IN MARLIN! **
|
|
195
|
+ * M203 - Set maximum feedrate: "M203 X<fr> Y<fr> Z<fr> E<fr>" in units/sec.
|
|
196
|
+ * M204 - Set default acceleration in units/sec^2: P<printing> R<extruder_only> T<travel>
|
198
|
197
|
* M205 - Set advanced settings. Current units apply:
|
199
|
198
|
S<print> T<travel> minimum speeds
|
200
|
199
|
B<minimum segment time>
|
201
|
200
|
X<max xy jerk>, Z<max Z jerk>, E<max E jerk>
|
202
|
|
- * M206 - Set additional homing offset
|
203
|
|
- * M207 - Set Retract Length: S<length>, Feedrate: F<units/min>, and Z lift: Z<distance>
|
204
|
|
- * M208 - Set Recover (unretract) Additional (!) Length: S<length> and Feedrate: F<units/min>
|
205
|
|
- * M209 - Turn Automatic Retract Detection on/off: S<bool> (For slicers that don't support G10/11).
|
|
201
|
+ * M206 - Set additional homing offset.
|
|
202
|
+ * M207 - Set Retract Length: S<length>, Feedrate: F<units/min>, and Z lift: Z<distance>. (Requires FWRETRACT)
|
|
203
|
+ * M208 - Set Recover (unretract) Additional (!) Length: S<length> and Feedrate: F<units/min>. (Requires FWRETRACT)
|
|
204
|
+ * M209 - Turn Automatic Retract Detection on/off: S<0|1> (For slicers that don't support G10/11). (Requires FWRETRACT)
|
206
|
205
|
Every normal extrude-only move will be classified as retract depending on the direction.
|
207
|
|
- * M211 - Enable, Disable, and/or Report software endstops: [S<bool>]
|
208
|
|
- * M218 - Set a tool offset: T<index> X<offset> Y<offset>
|
209
|
|
- * M220 - Set Feedrate Percentage: S<percent> ("FR" on your LCD)
|
210
|
|
- * M221 - Set Flow Percentage: S<percent>
|
211
|
|
- * M226 - Wait until the specified pin reaches the state required: P<pin number> S<pin state>
|
212
|
|
- * M240 - Trigger a camera to take a photograph
|
213
|
|
- * M250 - Set LCD contrast C<contrast value> (value 0..63)
|
214
|
|
- * M280 - Set servo position absolute. P: servo index, S: angle or microseconds
|
|
206
|
+ * M211 - Enable, Disable, and/or Report software endstops: S<0|1>
|
|
207
|
+ * M218 - Set a tool offset: "M218 T<index> X<offset> Y<offset>". (Requires 2 or more extruders)
|
|
208
|
+ * M220 - Set Feedrate Percentage: "M220 S<percent>" (i.e., "FR" on the LCD)
|
|
209
|
+ * M221 - Set Flow Percentage: "M221 S<percent>"
|
|
210
|
+ * M226 - Wait until a pin is in a given state: "M226 P<pin> S<state>"
|
|
211
|
+ * M240 - Trigger a camera to take a photograph. (Requires CHDK or PHOTOGRAPH_PIN)
|
|
212
|
+ * M250 - Set LCD contrast: "M250 C<contrast>" (0-63). (Requires LCD support)
|
|
213
|
+ * M280 - Set servo position absolute: "M280 P<index> S<angle|µs>". (Requires servos)
|
215
|
214
|
* M300 - Play beep sound S<frequency Hz> P<duration ms>
|
216
|
|
- * M301 - Set PID parameters P I and D
|
217
|
|
- * M302 - Allow cold extrudes, or set the minimum extrude S<temperature>.
|
218
|
|
- * M303 - PID relay autotune S<temperature> sets the target temperature. (default target temperature = 150C)
|
219
|
|
- * M304 - Set bed PID parameters P I and D
|
220
|
|
- * M380 - Activate solenoid on active extruder
|
221
|
|
- * M381 - Disable all solenoids
|
222
|
|
- * M400 - Finish all moves
|
223
|
|
- * M401 - Lower Z probe if present
|
224
|
|
- * M402 - Raise Z probe if present
|
225
|
|
- * M404 - Display or set the Nominal Filament Width: [ N<diameter> ]
|
226
|
|
- * M405 - Enable Filament Sensor extrusion control. Optional delay between sensor and extruder: D<cm>
|
227
|
|
- * M406 - Disable Filament Sensor extrusion control
|
228
|
|
- * M407 - Display measured filament diameter in millimeters
|
229
|
|
- * M410 - Quickstop. Abort all the planned moves
|
230
|
|
- * M420 - Enable/Disable Mesh Leveling (with current values) S1=enable S0=disable
|
231
|
|
- * M421 - Set a single Z coordinate in the Mesh Leveling grid. X<units> Y<units> Z<units>
|
232
|
|
- * M428 - Set the home_offset logically based on the current_position
|
233
|
|
- * M500 - Store parameters in EEPROM
|
234
|
|
- * M501 - Read parameters from EEPROM (if you need reset them after you changed them temporarily).
|
235
|
|
- * M502 - Revert to the default "factory settings". You still need to store them in EEPROM afterwards if you want to.
|
236
|
|
- * M503 - Print the current settings (from memory not from EEPROM). Use S0 to leave off headings.
|
237
|
|
- * M540 - Use S[0|1] to enable or disable the stop SD card print on endstop hit (requires ABORT_ON_ENDSTOP_HIT_FEATURE_ENABLED)
|
238
|
|
- * M600 - Pause for filament change X[pos] Y[pos] Z[relative lift] E[initial retract] L[later retract distance for removal]
|
239
|
|
- * M665 - Set delta configurations: L<diagonal rod> R<delta radius> S<segments/s>
|
240
|
|
- * M666 - Set delta endstop adjustment
|
241
|
|
- * M605 - Set dual x-carriage movement mode: S<mode> [ X<duplication x-offset> R<duplication temp offset> ]
|
242
|
|
- * M851 - Set Z probe's Z offset in current units. (Negative values apply to probes that extend below the nozzle.)
|
243
|
|
- * M907 - Set digital trimpot motor current using axis codes.
|
244
|
|
- * M908 - Control digital trimpot directly.
|
245
|
|
- * M909 - DAC_STEPPER_CURRENT: Print digipot/DAC current value
|
246
|
|
- * M910 - DAC_STEPPER_CURRENT: Commit digipot/DAC value to external EEPROM via I2C
|
247
|
|
- * M350 - Set microstepping mode.
|
248
|
|
- * M351 - Toggle MS1 MS2 pins directly.
|
|
215
|
+ * M301 - Set PID parameters P I and D. (Requires PIDTEMP)
|
|
216
|
+ * M302 - Allow cold extrudes, or set the minimum extrude S<temperature>. (Requires PREVENT_COLD_EXTRUSION)
|
|
217
|
+ * M303 - PID relay autotune S<temperature> sets the target temperature. Default 150C. (Requires PIDTEMP)
|
|
218
|
+ * M304 - Set bed PID parameters P I and D. (Requires PIDTEMPBED)
|
|
219
|
+ * M380 - Activate solenoid on active extruder. (Requires EXT_SOLENOID)
|
|
220
|
+ * M381 - Disable all solenoids. (Requires EXT_SOLENOID)
|
|
221
|
+ * M400 - Finish all moves.
|
|
222
|
+ * M401 - Lower Z probe. (Requires a probe)
|
|
223
|
+ * M402 - Raise Z probe. (Requires a probe)
|
|
224
|
+ * M404 - Display or set the Nominal Filament Width: "W<diameter>". (Requires FILAMENT_WIDTH_SENSOR)
|
|
225
|
+ * M405 - Enable Filament Sensor flow control. "M405 D<delay_cm>". (Requires FILAMENT_WIDTH_SENSOR)
|
|
226
|
+ * M406 - Disable Filament Sensor flow control. (Requires FILAMENT_WIDTH_SENSOR)
|
|
227
|
+ * M407 - Display measured filament diameter in millimeters. (Requires FILAMENT_WIDTH_SENSOR)
|
|
228
|
+ * M410 - Quickstop. Abort all planned moves.
|
|
229
|
+ * M420 - Enable/Disable Mesh Leveling (with current values) S1=enable S0=disable (Requires MESH_BED_LEVELING)
|
|
230
|
+ * M421 - Set a single Z coordinate in the Mesh Leveling grid. X<units> Y<units> Z<units> (Requires MESH_BED_LEVELING)
|
|
231
|
+ * M428 - Set the home_offset based on the current_position. Nearest edge applies.
|
|
232
|
+ * M500 - Store parameters in EEPROM. (Requires EEPROM_SETTINGS)
|
|
233
|
+ * M501 - Restore parameters from EEPROM. (Requires EEPROM_SETTINGS)
|
|
234
|
+ * M502 - Revert to the default "factory settings". ** Does not write them to EEPROM! **
|
|
235
|
+ * M503 - Print the current settings (in memory): "M503 S<verbose>". S0 specifies compact output.
|
|
236
|
+ * M540 - Enable/disable SD card abort on endstop hit: "M540 S<state>". (Requires ABORT_ON_ENDSTOP_HIT_FEATURE_ENABLED)
|
|
237
|
+ * M600 - Pause for filament change: "M600 X<pos> Y<pos> Z<raise> E<first_retract> L<later_retract>". (Requires FILAMENT_CHANGE_FEATURE)
|
|
238
|
+ * M665 - Set delta configurations: "M665 L<diagonal rod> R<delta radius> S<segments/s>" (Requires DELTA)
|
|
239
|
+ * M666 - Set delta endstop adjustment. (Requires DELTA)
|
|
240
|
+ * M605 - Set dual x-carriage movement mode: "M605 S<mode> [X<x_offset>] [R<temp_offset>]". (Requires DUAL_X_CARRIAGE)
|
|
241
|
+ * M851 - Set Z probe's Z offset in current units. (Negative = below the nozzle.)
|
|
242
|
+ * M907 - Set digital trimpot motor current using axis codes. (Requires a board with digital trimpots)
|
|
243
|
+ * M908 - Control digital trimpot directly. (Requires DAC_STEPPER_CURRENT or DIGIPOTSS_PIN)
|
|
244
|
+ * M909 - Print digipot/DAC current value. (Requires DAC_STEPPER_CURRENT)
|
|
245
|
+ * M910 - Commit digipot/DAC value to external EEPROM via I2C. (Requires DAC_STEPPER_CURRENT)
|
|
246
|
+ * M350 - Set microstepping mode. (Requires digital microstepping pins.)
|
|
247
|
+ * M351 - Toggle MS1 MS2 pins directly. (Requires digital microstepping pins.)
|
249
|
248
|
*
|
250
|
249
|
* ************ SCARA Specific - This can change to suit future G-code regulations
|
251
|
250
|
* M360 - SCARA calibration: Move to cal-position ThetaA (0 deg calibration)
|
|
@@ -256,13 +255,13 @@
|
256
|
255
|
* ************* SCARA End ***************
|
257
|
256
|
*
|
258
|
257
|
* ************ Custom codes - This can change to suit future G-code regulations
|
259
|
|
- * M100 - Watch Free Memory (For Debugging Only)
|
260
|
|
- * M928 - Start SD logging (M928 filename.g) - ended by M29
|
|
258
|
+ * M100 - Watch Free Memory (For Debugging). (Requires M100_FREE_MEMORY_WATCHER)
|
|
259
|
+ * M928 - Start SD logging: "M928 filename.gco". Stop with M29. (Requires SDSUPPORT)
|
261
|
260
|
* M999 - Restart after being stopped by error
|
262
|
261
|
*
|
263
|
262
|
* "T" Codes
|
264
|
263
|
*
|
265
|
|
- * T0-T3 - Select a tool by index (usually an extruder) [ F<units/min> ]
|
|
264
|
+ * T0-T3 - Select an extruder (tool) by index: "T<n> F<units/min>"
|
266
|
265
|
*
|
267
|
266
|
*/
|
268
|
267
|
|