machines/systems/flexibot/docs/marlin/_gcode/M032.md
2025-03-11 23:32:39 +01:00

1.3 KiB

tag title brief author experimental requires group codes notes parameters examples
m0032 Select and Start Begin an SD print from a file. thinkyhead true SDSUPPORT sdcard
M32
Requires [`SDSUPPORT`](/docs/configuration/configuration.html#sd-card)
This is a seldom-used beta feature that needs more testing and use-cases.
tag optional description values
P true Sub-Program flag
tag type
flag bool
tag optional description values
S true Starting file offset
tag type
filepos int
pre code
Select and start a file at offset 5022. M32 S5022 !/boats/sailboat.gco
pre code post
Select and start a file from within G-code. M32 P !/models/lgbust.gco# The `#` suffix is needed when using `P` to "stop buffer pre-reading" so no commands after [`M32`](/docs/gcode/M032.html) will go into the buffer until after it returns.

The M32 command exists to allow G-code to load other G-code files and run them as sub-programs. This can be useful to change the start / end G-code for a batch of files without having to edit them all.

For legacy reasons M32 uses '!' (and '#') to delimit the filepath parameter. The filepath must be the last parameter.