Show "FILAMENT CHANGE" during filament change

This commit is contained in:
Scott Lahteine 2019-10-02 19:05:12 -05:00
parent 0322348924
commit 6b945eb548
4 changed files with 21 additions and 11 deletions

View file

@ -240,10 +240,10 @@ bool load_filament(const float &slow_load_length/*=0*/, const float &fast_load_l
wait_for_user = true; wait_for_user = true;
#if ENABLED(HOST_PROMPT_SUPPORT) #if ENABLED(HOST_PROMPT_SUPPORT)
host_prompt_do(PROMPT_USER_CONTINUE, PSTR("Continuous Purge Running..."), PSTR("Continue")); host_prompt_do(PROMPT_USER_CONTINUE, PSTR("Filament Purge Running..."), PSTR("Continue"));
#endif #endif
#if ENABLED(EXTENSIBLE_UI) #if ENABLED(EXTENSIBLE_UI)
ExtUI::onUserConfirmRequired(PSTR("Continuous Purge Running...")); ExtUI::onUserConfirmRequired(PSTR("Filament Purge Running..."));
#endif #endif
for (float purge_count = purge_length; purge_count > 0 && wait_for_user; --purge_count) for (float purge_count = purge_length; purge_count > 0 && wait_for_user; --purge_count)
do_pause_e_move(1, ADVANCED_PAUSE_PURGE_FEEDRATE); do_pause_e_move(1, ADVANCED_PAUSE_PURGE_FEEDRATE);

View file

@ -39,6 +39,7 @@ typedef struct {
enum PauseMode : char { enum PauseMode : char {
PAUSE_MODE_SAME, PAUSE_MODE_SAME,
PAUSE_MODE_PAUSE_PRINT, PAUSE_MODE_PAUSE_PRINT,
PAUSE_MODE_CHANGE_FILAMENT,
PAUSE_MODE_LOAD_FILAMENT, PAUSE_MODE_LOAD_FILAMENT,
PAUSE_MODE_UNLOAD_FILAMENT PAUSE_MODE_UNLOAD_FILAMENT
}; };

View file

@ -1266,6 +1266,9 @@
#ifndef MSG_DAC_EEPROM_WRITE #ifndef MSG_DAC_EEPROM_WRITE
#define MSG_DAC_EEPROM_WRITE _UxGT("DAC EEPROM Write") #define MSG_DAC_EEPROM_WRITE _UxGT("DAC EEPROM Write")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_HEADER
#define MSG_FILAMENT_CHANGE_HEADER _UxGT("FILAMENT CHANGE")
#endif
#ifndef MSG_FILAMENT_CHANGE_HEADER_PAUSE #ifndef MSG_FILAMENT_CHANGE_HEADER_PAUSE
#define MSG_FILAMENT_CHANGE_HEADER_PAUSE _UxGT("PRINT PAUSED") #define MSG_FILAMENT_CHANGE_HEADER_PAUSE _UxGT("PRINT PAUSED")
#endif #endif
@ -1493,20 +1496,20 @@
#define MSG_FILAMENT_CHANGE_HEATING_2 _UxGT("Please wait...") #define MSG_FILAMENT_CHANGE_HEATING_2 _UxGT("Please wait...")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_UNLOAD_1 #ifndef MSG_FILAMENT_CHANGE_UNLOAD_1
#define MSG_FILAMENT_CHANGE_UNLOAD_1 _UxGT("Wait for") #define MSG_FILAMENT_CHANGE_UNLOAD_1 _UxGT("Wait for filament")
#define MSG_FILAMENT_CHANGE_UNLOAD_2 _UxGT("filament unload") #define MSG_FILAMENT_CHANGE_UNLOAD_2 _UxGT("to fully unload")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_LOAD_1 #ifndef MSG_FILAMENT_CHANGE_LOAD_1
#define MSG_FILAMENT_CHANGE_LOAD_1 _UxGT("Wait for") #define MSG_FILAMENT_CHANGE_LOAD_1 _UxGT("Wait for filament")
#define MSG_FILAMENT_CHANGE_LOAD_2 _UxGT("filament load") #define MSG_FILAMENT_CHANGE_LOAD_2 _UxGT("to load to nozzle")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_PURGE_1 #ifndef MSG_FILAMENT_CHANGE_PURGE_1
#define MSG_FILAMENT_CHANGE_PURGE_1 _UxGT("Wait for") #define MSG_FILAMENT_CHANGE_PURGE_1 _UxGT("Wait for filament")
#define MSG_FILAMENT_CHANGE_PURGE_2 _UxGT("filament purge") #define MSG_FILAMENT_CHANGE_PURGE_2 _UxGT("purge to finish")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_CONT_PURGE_1 #ifndef MSG_FILAMENT_CHANGE_CONT_PURGE_1
#define MSG_FILAMENT_CHANGE_CONT_PURGE_1 _UxGT("Click to finish") #define MSG_FILAMENT_CHANGE_CONT_PURGE_1 _UxGT("Click to stop")
#define MSG_FILAMENT_CHANGE_CONT_PURGE_2 _UxGT("filament purge") #define MSG_FILAMENT_CHANGE_CONT_PURGE_2 _UxGT("purging filament")
#endif #endif
#ifndef MSG_FILAMENT_CHANGE_RESUME_1 #ifndef MSG_FILAMENT_CHANGE_RESUME_1
#define MSG_FILAMENT_CHANGE_RESUME_1 _UxGT("Wait for print") #define MSG_FILAMENT_CHANGE_RESUME_1 _UxGT("Wait for print")

View file

@ -47,6 +47,7 @@ inline PGM_P _change_filament_temp_command() {
return PSTR("M701 T%d"); return PSTR("M701 T%d");
case PAUSE_MODE_UNLOAD_FILAMENT: case PAUSE_MODE_UNLOAD_FILAMENT:
return _change_filament_temp_extruder >= 0 ? PSTR("M702 T%d") : PSTR("M702 ;%d"); return _change_filament_temp_extruder >= 0 ? PSTR("M702 T%d") : PSTR("M702 ;%d");
case PAUSE_MODE_CHANGE_FILAMENT:
case PAUSE_MODE_PAUSE_PRINT: case PAUSE_MODE_PAUSE_PRINT:
default: default:
return PSTR("M600 B0 T%d"); return PSTR("M600 B0 T%d");
@ -75,7 +76,9 @@ static PGM_P change_filament_header(const PauseMode mode) {
return PSTR(MSG_FILAMENTCHANGE); return PSTR(MSG_FILAMENTCHANGE);
} }
void _menu_temp_filament_op(const PauseMode mode, const int8_t extruder) { void _menu_temp_filament_op(const PauseMode inMode, const int8_t extruder) {
// If no print is active, just label as "filament change"
const PauseMode mode = (inMode != PAUSE_MODE_PAUSE_PRINT || printingIsPaused()) ? inMode : PAUSE_MODE_CHANGE_FILAMENT;
_change_filament_temp_mode = mode; _change_filament_temp_mode = mode;
_change_filament_temp_extruder = extruder; _change_filament_temp_extruder = extruder;
START_MENU(); START_MENU();
@ -315,10 +318,13 @@ static uint8_t hotend_status_extruder = 0;
static PGM_P pause_header() { static PGM_P pause_header() {
switch (pause_mode) { switch (pause_mode) {
case PAUSE_MODE_CHANGE_FILAMENT:
return PSTR(MSG_FILAMENT_CHANGE_HEADER);
case PAUSE_MODE_LOAD_FILAMENT: case PAUSE_MODE_LOAD_FILAMENT:
return PSTR(MSG_FILAMENT_CHANGE_HEADER_LOAD); return PSTR(MSG_FILAMENT_CHANGE_HEADER_LOAD);
case PAUSE_MODE_UNLOAD_FILAMENT: case PAUSE_MODE_UNLOAD_FILAMENT:
return PSTR(MSG_FILAMENT_CHANGE_HEADER_UNLOAD); return PSTR(MSG_FILAMENT_CHANGE_HEADER_UNLOAD);
case PAUSE_MODE_PAUSE_PRINT:
default: break; default: break;
} }
return PSTR(MSG_FILAMENT_CHANGE_HEADER_PAUSE); return PSTR(MSG_FILAMENT_CHANGE_HEADER_PAUSE);