Fix issue #1 where M600 did not work. Also implemented advanced pause and parging feature and fixed bug, which prevents resuming from pared nozzle.
This commit is contained in:
@@ -1870,7 +1870,7 @@
|
|||||||
* Requires NOZZLE_PARK_FEATURE.
|
* Requires NOZZLE_PARK_FEATURE.
|
||||||
* This feature is required for the default FILAMENT_RUNOUT_SCRIPT.
|
* This feature is required for the default FILAMENT_RUNOUT_SCRIPT.
|
||||||
*/
|
*/
|
||||||
//#define ADVANCED_PAUSE_FEATURE
|
#define ADVANCED_PAUSE_FEATURE
|
||||||
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
||||||
#define PAUSE_PARK_RETRACT_FEEDRATE 60 // (mm/s) Initial retract feedrate.
|
#define PAUSE_PARK_RETRACT_FEEDRATE 60 // (mm/s) Initial retract feedrate.
|
||||||
#define PAUSE_PARK_RETRACT_LENGTH 4 // (mm) Initial retract.
|
#define PAUSE_PARK_RETRACT_LENGTH 4 // (mm) Initial retract.
|
||||||
|
@@ -184,6 +184,8 @@ void AnycubicTouchscreenClass::StartPrint()
|
|||||||
SERIAL_ECHOLNPGM("DEBUG: M24 Resume from regular pause");
|
SERIAL_ECHOLNPGM("DEBUG: M24 Resume from regular pause");
|
||||||
#endif
|
#endif
|
||||||
IsParked = false; // remove parked flag
|
IsParked = false; // remove parked flag
|
||||||
|
wait_for_heatup = false;
|
||||||
|
wait_for_user = false;
|
||||||
starttime = millis();
|
starttime = millis();
|
||||||
card.startFileprint(); // resume regularly
|
card.startFileprint(); // resume regularly
|
||||||
TFTstate = ANYCUBIC_TFT_STATE_SDPRINT;
|
TFTstate = ANYCUBIC_TFT_STATE_SDPRINT;
|
||||||
@@ -213,6 +215,7 @@ void AnycubicTouchscreenClass::StartPrint()
|
|||||||
SERIAL_ECHOLNPGM("DEBUG: M24 Resume from Filament Runout");
|
SERIAL_ECHOLNPGM("DEBUG: M24 Resume from Filament Runout");
|
||||||
#endif
|
#endif
|
||||||
IsParked = false; // clear flags
|
IsParked = false; // clear flags
|
||||||
|
wait_for_user = false;
|
||||||
ai3m_pause_state = 0;
|
ai3m_pause_state = 0;
|
||||||
#ifdef ANYCUBIC_TFT_DEBUG
|
#ifdef ANYCUBIC_TFT_DEBUG
|
||||||
SERIAL_ECHOLNPGM("DEBUG: Filament Pause Flag cleared");
|
SERIAL_ECHOLNPGM("DEBUG: Filament Pause Flag cleared");
|
||||||
@@ -325,15 +328,15 @@ void AnycubicTouchscreenClass::StopPrint()
|
|||||||
|
|
||||||
void AnycubicTouchscreenClass::FilamentChangeResume()
|
void AnycubicTouchscreenClass::FilamentChangeResume()
|
||||||
{
|
{
|
||||||
|
wait_for_user = false; //must be done twice, since we have a bug in marlin
|
||||||
|
wait_for_heatup = false;
|
||||||
// call M108 to break out of M600 pause
|
// call M108 to break out of M600 pause
|
||||||
queue.inject_P(PSTR("M108"));
|
queue.inject_P(PSTR("M108"));
|
||||||
#ifdef ANYCUBIC_TFT_DEBUG
|
#ifdef ANYCUBIC_TFT_DEBUG
|
||||||
SERIAL_ECHOLNPGM("DEBUG: M108 Resume called");
|
SERIAL_ECHOLNPGM("DEBUG: M108 Resume called");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
wait_for_heatup = false;
|
|
||||||
wait_for_user = false;
|
wait_for_user = false;
|
||||||
|
wait_for_heatup = false;
|
||||||
// resume with proper progress state
|
// resume with proper progress state
|
||||||
card.startFileprint();
|
card.startFileprint();
|
||||||
#ifdef ANYCUBIC_TFT_DEBUG
|
#ifdef ANYCUBIC_TFT_DEBUG
|
||||||
|
Reference in New Issue
Block a user