M23: Select File

Issuing an M23 selects a file from the SD card that will be used for printing with the M24 command.

The file will remain “selected” and all subsequent M24 commands will print that file until a different file is selected.

Error Handling

If the file does not exist on the SD card, an error will be returned (ERROR?).

Restarting Files

The M23 command can be used to restart a file from the beginning.

Use M23 to select/reset the file, then M24 to start printing from the beginning.

Print: In this context, "print" refers to running a job on any Smoothie-controlled device such as 3D printer, laser engraver/cutter, CNC router, etc.

Format

The command is used as such:

M23 filename.gco

Which means: Select the file to be used in the subsequent M24 print/resume command.

Parameters

Parameter Usage Example
filename The file, on the SD card, will be printed in the subsequent M24 command M20 myGcodeFile.gco

Filename Support

The filename parameter identifies the file to be used by subsequent M24 commands.

Smoothie supports both long filenames and 8.3 format.

Example

If your SD card contents were:

  • config.txt
  • firmware.cur
  • Readme.txt
  • myGcode.gco

This means if you command:

M23 myGcode.gco

The file myGcode.gco would be queued for subsequent printing with the M24 command.

To actually start printing, you would then issue:

M24

Configuration

The M23 command requires no special configuration settings.

The SD card must be properly inserted and contain the file you’re trying to select.

Further reading

These resources are used as references: