Skip to content

Commit

Permalink
✨ Long filename open/create/write (MarlinFirmware#23526)
Browse files Browse the repository at this point in the history
Co-authored-by: Scott Lahteine <[email protected]>
  • Loading branch information
2 people authored and Omkar Dhekne committed Mar 25, 2024
1 parent 52e3d90 commit dfaa6bf
Show file tree
Hide file tree
Showing 8 changed files with 582 additions and 148 deletions.
28 changes: 9 additions & 19 deletions Marlin/Configuration_adv.h
Original file line number Diff line number Diff line change
Expand Up @@ -1525,33 +1525,23 @@
// LCD's font must contain the characters. Check your selected LCD language.
//#define UTF_FILENAME_SUPPORT

// This allows hosts to request long names for files and folders with M33
//#define LONG_FILENAME_HOST_SUPPORT
//#define LONG_FILENAME_HOST_SUPPORT // Get the long filename of a file/folder with 'M33 <dosname>' and list long filenames with 'M20 L'
//#define LONG_FILENAME_WRITE_SUPPORT // Create / delete files with long filenames via M28, M30, and Binary Transfer Protocol

// Enable this option to scroll long filenames in the SD card menu
//#define SCROLL_LONG_FILENAMES
//#define SCROLL_LONG_FILENAMES // Scroll long filenames in the SD card menu

// Leave the heaters on after Stop Print (not recommended!)
//#define SD_ABORT_NO_COOLDOWN
//#define SD_ABORT_NO_COOLDOWN // Leave the heaters on after Stop Print (not recommended!)

/**
* This option allows you to abort SD printing when any endstop is triggered.
* This feature must be enabled with "M540 S1" or from the LCD menu.
* To have any effect, endstops must be enabled during SD printing.
* Abort SD printing when any endstop is triggered.
* This feature is enabled with 'M540 S1' or from the LCD menu.
* Endstops must be activated for this option to work.
*/
//#define SD_ABORT_ON_ENDSTOP_HIT

/**
* This option makes it easier to print the same SD Card file again.
* On print completion the LCD Menu will open with the file selected.
* You can just click to start the print, or navigate elsewhere.
*/
//#define SD_REPRINT_LAST_SELECTED_FILE
//#define SD_REPRINT_LAST_SELECTED_FILE // On print completion open the LCD Menu and select the same file

/**
* Auto-report SdCard status with M27 S<seconds>
*/
//#define AUTO_REPORT_SD_STATUS
//#define AUTO_REPORT_SD_STATUS // Auto-report media status with 'M27 S<seconds>'

/**
* Support for USB thumb drives using an Arduino USB Host Shield or
Expand Down
2 changes: 2 additions & 0 deletions Marlin/src/gcode/eeprom/M500-M504.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ void GcodeSuite::M502() {
/**
* M503: print settings currently in memory
*
* S<bool> : Include / exclude header comments in the output. (Default: S1)
*
* With CONFIGURATION_EMBEDDING:
* C<flag> : Save the full Marlin configuration to SD Card as "mc.zip"
*/
Expand Down
8 changes: 7 additions & 1 deletion Marlin/src/gcode/host/M115.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,12 @@ void GcodeSuite::M115() {
// LONG_FILENAME_HOST_SUPPORT (M33)
cap_line(F("LONG_FILENAME"), ENABLED(LONG_FILENAME_HOST_SUPPORT));

// LONG_FILENAME_WRITE_SUPPORT (M23, M28, M30...)
cap_line(F("LFN_WRITE"), ENABLED(LONG_FILENAME_WRITE_SUPPORT));

// CUSTOM_FIRMWARE_UPLOAD (M20 F)
cap_line(F("CUSTOM_FIRMWARE_UPLOAD"), ENABLED(CUSTOM_FIRMWARE_UPLOAD));

// EXTENDED_M20 (M20 L)
cap_line(F("EXTENDED_M20"), ENABLED(LONG_FILENAME_HOST_SUPPORT));

Expand All @@ -179,7 +185,7 @@ void GcodeSuite::M115() {
cap_line(F("MEATPACK"), SERIAL_IMPL.has_feature(port, SerialFeature::MeatPack));

// CONFIG_EXPORT
cap_line(F("CONFIG_EXPORT"), ENABLED(CONFIG_EMBED_AND_SAVE_TO_SD));
cap_line(F("CONFIG_EXPORT"), ENABLED(CONFIGURATION_EMBEDDING));

// Machine Geometry
#if ENABLED(M115_GEOMETRY_REPORT)
Expand Down
Loading

0 comments on commit dfaa6bf

Please sign in to comment.