Event G-code for Stop SD Print (#13547)
Co-Authored-By: 7eggert <7eggert@gmx.de> Co-Authored-By: robbycandra <robbycandra.mail@gmail.com>
This commit is contained in:
committed by
Scott Lahteine
parent
2cfa9e9008
commit
46445a5a16
@ -770,8 +770,9 @@
|
||||
// Since the FAT gets out of order with usage, SDCARD_SORT_ALPHA is recommended.
|
||||
#define SDCARD_RATHERRECENTFIRST
|
||||
|
||||
// Add an option in the menu to run all auto#.g files
|
||||
//#define MENU_ADDAUTOSTART
|
||||
//#define MENU_ADDAUTOSTART // Add a menu option to run auto#.g files
|
||||
|
||||
#define EVENT_GCODE_SD_STOP "G28XY" // G-code to run on Stop Print (e.g., "G28XY" or "G27")
|
||||
|
||||
/**
|
||||
* Continue after Power-Loss (Creality3D)
|
||||
|
@ -1143,6 +1143,9 @@ void loop() {
|
||||
#if ENABLED(POWER_LOSS_RECOVERY)
|
||||
card.removeJobRecoveryFile();
|
||||
#endif
|
||||
#ifdef EVENT_GCODE_SD_STOP
|
||||
enqueue_and_echo_commands_P(PSTR(EVENT_GCODE_SD_STOP));
|
||||
#endif
|
||||
}
|
||||
#endif // SDSUPPORT
|
||||
|
||||
|
@ -551,6 +551,10 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if defined(EVENT_GCODE_SD_STOP) && DISABLED(NOZZLE_PARK_FEATURE)
|
||||
static_assert(NULL == strstr(EVENT_GCODE_SD_STOP, "G27"), "NOZZLE_PARK_FEATURE is required to use G27 in EVENT_GCODE_SD_STOP.");
|
||||
#endif
|
||||
|
||||
/**
|
||||
* I2C Position Encoders
|
||||
*/
|
||||
|
Reference in New Issue
Block a user