From 9f5c7ce908a0a20be55fbfc09b87944724b6560c Mon Sep 17 00:00:00 2001 From: CoderSquirrel Date: Sat, 23 Apr 2016 12:56:48 -0300 Subject: [PATCH 1/3] Add Change Filament to the LCD menu --- Marlin/Configuration.h | 8 +++ .../Felix/Configuration.h | 7 ++- .../Hephestos/Configuration.h | 7 ++- .../Hephestos_2/Configuration.h | 7 ++- .../K8200/Configuration.h | 7 ++- .../RepRapWorld/Megatronics/Configuration.h | 7 ++- .../RigidBot/Configuration.h | 7 ++- .../SCARA/Configuration.h | 7 ++- .../TAZ4/Configuration.h | 7 ++- .../WITBOX/Configuration.h | 7 ++- .../adafruit/ST7565/Configuration.h | 7 ++- .../delta/biv2.5/Configuration.h | 7 ++- .../delta/generic/Configuration.h | 7 ++- .../delta/kossel_mini/Configuration.h | 7 ++- .../delta/kossel_pro/Configuration.h | 7 ++- .../delta/kossel_xl/Configuration.h | 7 ++- .../makibox/Configuration.h | 7 ++- .../tvrrug/Round2/Configuration.h | 7 ++- Marlin/language_en.h | 13 +++++ Marlin/language_pt-br.h | 5 ++ Marlin/ultralcd.cpp | 56 +++++++++++++++++++ 21 files changed, 184 insertions(+), 17 deletions(-) diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index aa1733cc26fa..9d834d6a65ce 100644 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -1156,6 +1156,14 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM + + +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Felix/Configuration.h b/Marlin/example_configurations/Felix/Configuration.h index d8495eb840d3..768cf8ddd2fc 100644 --- a/Marlin/example_configurations/Felix/Configuration.h +++ b/Marlin/example_configurations/Felix/Configuration.h @@ -1138,7 +1138,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Hephestos/Configuration.h b/Marlin/example_configurations/Hephestos/Configuration.h index a047e59c5570..0de2d211de24 100644 --- a/Marlin/example_configurations/Hephestos/Configuration.h +++ b/Marlin/example_configurations/Hephestos/Configuration.h @@ -1147,7 +1147,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Hephestos_2/Configuration.h b/Marlin/example_configurations/Hephestos_2/Configuration.h index 4704fa82271d..0f9738dfef34 100644 --- a/Marlin/example_configurations/Hephestos_2/Configuration.h +++ b/Marlin/example_configurations/Hephestos_2/Configuration.h @@ -1149,7 +1149,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/K8200/Configuration.h b/Marlin/example_configurations/K8200/Configuration.h index 5267edcbd24e..25a218032678 100644 --- a/Marlin/example_configurations/K8200/Configuration.h +++ b/Marlin/example_configurations/K8200/Configuration.h @@ -1172,7 +1172,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h b/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h index e394b6b2af77..1f540dbd32b6 100644 --- a/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h +++ b/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h @@ -1155,7 +1155,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/RigidBot/Configuration.h b/Marlin/example_configurations/RigidBot/Configuration.h index ad5c40850025..070d0f94cb0b 100644 --- a/Marlin/example_configurations/RigidBot/Configuration.h +++ b/Marlin/example_configurations/RigidBot/Configuration.h @@ -1155,7 +1155,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/SCARA/Configuration.h b/Marlin/example_configurations/SCARA/Configuration.h index 1c23794d014f..910fb58bd7ad 100644 --- a/Marlin/example_configurations/SCARA/Configuration.h +++ b/Marlin/example_configurations/SCARA/Configuration.h @@ -1163,7 +1163,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/TAZ4/Configuration.h b/Marlin/example_configurations/TAZ4/Configuration.h index e5a7dd84431f..ec4ab82a0b7f 100644 --- a/Marlin/example_configurations/TAZ4/Configuration.h +++ b/Marlin/example_configurations/TAZ4/Configuration.h @@ -1176,7 +1176,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/WITBOX/Configuration.h b/Marlin/example_configurations/WITBOX/Configuration.h index d3012dbfb1b0..00acb9c35986 100644 --- a/Marlin/example_configurations/WITBOX/Configuration.h +++ b/Marlin/example_configurations/WITBOX/Configuration.h @@ -1147,7 +1147,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/adafruit/ST7565/Configuration.h b/Marlin/example_configurations/adafruit/ST7565/Configuration.h index 9c4f23d18181..c0b8a95de8be 100644 --- a/Marlin/example_configurations/adafruit/ST7565/Configuration.h +++ b/Marlin/example_configurations/adafruit/ST7565/Configuration.h @@ -1155,7 +1155,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/biv2.5/Configuration.h b/Marlin/example_configurations/delta/biv2.5/Configuration.h index 5dd547a516df..37711cc6b10b 100644 --- a/Marlin/example_configurations/delta/biv2.5/Configuration.h +++ b/Marlin/example_configurations/delta/biv2.5/Configuration.h @@ -1240,7 +1240,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/generic/Configuration.h b/Marlin/example_configurations/delta/generic/Configuration.h index 509cfca31dca..e6c1a576b170 100644 --- a/Marlin/example_configurations/delta/generic/Configuration.h +++ b/Marlin/example_configurations/delta/generic/Configuration.h @@ -1234,7 +1234,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_mini/Configuration.h b/Marlin/example_configurations/delta/kossel_mini/Configuration.h index f2e3b46f955b..8a5619241450 100644 --- a/Marlin/example_configurations/delta/kossel_mini/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_mini/Configuration.h @@ -1237,7 +1237,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_pro/Configuration.h b/Marlin/example_configurations/delta/kossel_pro/Configuration.h index 66781c79663e..190f95d83926 100644 --- a/Marlin/example_configurations/delta/kossel_pro/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_pro/Configuration.h @@ -1237,7 +1237,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_xl/Configuration.h b/Marlin/example_configurations/delta/kossel_xl/Configuration.h index c62d63d3fa74..b73ac74b44d8 100644 --- a/Marlin/example_configurations/delta/kossel_xl/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_xl/Configuration.h @@ -1239,7 +1239,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/makibox/Configuration.h b/Marlin/example_configurations/makibox/Configuration.h index 6543925582a4..ec8b01f7f25a 100644 --- a/Marlin/example_configurations/makibox/Configuration.h +++ b/Marlin/example_configurations/makibox/Configuration.h @@ -1158,7 +1158,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/tvrrug/Round2/Configuration.h b/Marlin/example_configurations/tvrrug/Round2/Configuration.h index 8d14edadfb85..f52469a857d9 100644 --- a/Marlin/example_configurations/tvrrug/Round2/Configuration.h +++ b/Marlin/example_configurations/tvrrug/Round2/Configuration.h @@ -1149,7 +1149,12 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM - +/* + * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction +*/ +#define FILAMENTCOMPLETCHANGE_SIZE 75 +#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 +#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/language_en.h b/Marlin/language_en.h index aa9a52dfb65f..0ed948588c06 100644 --- a/Marlin/language_en.h +++ b/Marlin/language_en.h @@ -651,4 +651,17 @@ #endif #endif // LCD_HEIGHT < 4 +#ifndef MSG_CHANGE_FILAMENT + #define MSG_CHANGE_FILAMENT "Filament" +#endif +#ifndef MSG_REMOVE_FILAMENT + #define MSG_REMOVE_FILAMENT "Remove" +#endif +#ifndef MSG_INSERT_FILAMENT + #define MSG_INSERT_FILAMENT "Insert" +#endif +#ifndef MSG_INSERT_FILAMENT_SLOW + #define MSG_INSERT_FILAMENT_SLOW "Slow Insert" +#endif + #endif // LANGUAGE_EN_H diff --git a/Marlin/language_pt-br.h b/Marlin/language_pt-br.h index cc37f31dae91..bff2189b8a88 100644 --- a/Marlin/language_pt-br.h +++ b/Marlin/language_pt-br.h @@ -170,4 +170,9 @@ #define MSG_DELTA_CALIBRATE_Z "Calibrar Z" #define MSG_DELTA_CALIBRATE_CENTER "Calibrar Centro" + +#define MSG_CHANGE_FILAMENT "Filamento" +#define MSG_REMOVE_FILAMENT "Retirar" +#define MSG_INSERT_FILAMENT "Inserir" +#define MSG_INSERT_FILAMENT_SLOW "Lentamente" #endif // LANGUAGE_PT_BR_H diff --git a/Marlin/ultralcd.cpp b/Marlin/ultralcd.cpp index cf0b15ff3e5a..3fa5813b99a5 100755 --- a/Marlin/ultralcd.cpp +++ b/Marlin/ultralcd.cpp @@ -41,6 +41,10 @@ int absPreheatHotendTemp; int absPreheatHPBTemp; int absPreheatFanSpeed; +bool filamentInsert; +bool filamentSlowInsert; +bool filamentRemove; + #if ENABLED(FILAMENT_LCD_DISPLAY) millis_t previous_lcd_status_ms = 0; #endif @@ -140,6 +144,12 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to static void lcd_filament_change_resume_message(); #endif + static void lcd_change_filament_menu(); + static void lcd_retract_filament(); + static void lcd_insert_filament_menu(); + static void lcd_insert_filament(); + static void lcd_insert_filament_slow(); + #if HAS_LCD_CONTRAST static void lcd_set_contrast(); #endif @@ -558,6 +568,7 @@ static void lcd_status_screen() { static void lcd_main_menu() { START_MENU(); MENU_ITEM(back, MSG_WATCH); + MENU_ITEM(submenu, MSG_CHANGE_FILAMENT, lcd_change_filament_menu); if (planner.movesplanned() || IS_SD_PRINTING) { MENU_ITEM(submenu, MSG_TUNE, lcd_tune_menu); } @@ -1149,6 +1160,51 @@ static void lcd_status_screen() { #endif // MANUAL_BED_LEVELING + /** + * + * "Change Filament" submenu + * + */ + static void lcd_change_filament_menu() { + START_MENU(); + MENU_ITEM(back, MSG_MAIN); + MENU_ITEM(function, MSG_REMOVE_FILAMENT , lcd_retract_filament); + MENU_ITEM(submenu, MSG_INSERT_FILAMENT , lcd_insert_filament_menu); + END_MENU(); + } + + static void lcd_insert_filament_menu() { + START_MENU(); + MENU_ITEM(back, MSG_CHANGE_FILAMENT); + MENU_ITEM_EDIT_CALLBACK(bool, MSG_INSERT_FILAMENT_SLOW ,&filamentSlowInsert ,lcd_insert_filament_slow); + if(!filamentSlowInsert) + MENU_ITEM(function, MSG_INSERT_FILAMENT , lcd_insert_filament); + END_MENU(); + } + + static void lcd_insert_filament_slow(){ + while (filamentSlowInsert) { + //While the selection at menu is true it keeps slowing insert till the filament in on the tube + current_position[E_AXIS] += 1.0; + plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE, active_extruder); + st_synchronize(); + } + } + + static void lcd_retract_filament() { + //This value must be setted according the size you have at your printer + current_position[E_AXIS] -= FILAMENTCOMPLETCHANGE_SIZE; + plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_FAST_FEEDRATE, active_extruder); + st_synchronize(); + } + + static void lcd_insert_filament(){ + //This value must be setted according the size you have at your printer + current_position[E_AXIS] += FILAMENTCOMPLETCHANGE_SIZE; + plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_FAST_FEEDRATE, active_extruder); + st_synchronize(); + } + /** * * "Prepare" submenu From 7167b55a16871c9c9d0d1e2f5b1f19e1dee3d649 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 24 Apr 2016 16:08:32 -0700 Subject: [PATCH 2/3] Patch up to illustrate more proper techniques --- Marlin/Configuration.h | 8 -- Marlin/Configuration_adv.h | 13 +- .../Cartesio/Configuration_adv.h | 15 +- .../Felix/Configuration.h | 7 +- .../Felix/Configuration_adv.h | 13 +- .../Hephestos/Configuration.h | 7 +- .../Hephestos/Configuration_adv.h | 13 +- .../Hephestos_2/Configuration.h | 7 +- .../Hephestos_2/Configuration_adv.h | 13 +- .../K8200/Configuration.h | 7 +- .../K8200/Configuration_adv.h | 13 +- .../RepRapWorld/Megatronics/Configuration.h | 7 +- .../RigidBot/Configuration.h | 7 +- .../RigidBot/Configuration_adv.h | 13 +- .../SCARA/Configuration.h | 7 +- .../SCARA/Configuration_adv.h | 13 +- .../TAZ4/Configuration.h | 7 +- .../WITBOX/Configuration.h | 7 +- .../WITBOX/Configuration_adv.h | 13 +- .../adafruit/ST7565/Configuration.h | 7 +- .../delta/biv2.5/Configuration.h | 7 +- .../delta/biv2.5/Configuration_adv.h | 13 +- .../delta/generic/Configuration.h | 7 +- .../delta/generic/Configuration_adv.h | 13 +- .../delta/kossel_mini/Configuration.h | 7 +- .../delta/kossel_mini/Configuration_adv.h | 13 +- .../delta/kossel_pro/Configuration.h | 7 +- .../delta/kossel_pro/Configuration_adv.h | 13 +- .../delta/kossel_xl/Configuration.h | 7 +- .../delta/kossel_xl/Configuration_adv.h | 13 +- .../makibox/Configuration.h | 7 +- .../makibox/Configuration_adv.h | 13 +- .../tvrrug/Round2/Configuration.h | 7 +- .../tvrrug/Round2/Configuration_adv.h | 13 +- Marlin/language_en.h | 22 +-- Marlin/language_pt-br.h | 4 +- Marlin/ultralcd.cpp | 128 +++++++++++------- 37 files changed, 289 insertions(+), 202 deletions(-) diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h index 9d834d6a65ce..aa1733cc26fa 100644 --- a/Marlin/Configuration.h +++ b/Marlin/Configuration.h @@ -1156,14 +1156,6 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM - - -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/Configuration_adv.h b/Marlin/Configuration_adv.h index 3a673a673493..15d172241974 100644 --- a/Marlin/Configuration_adv.h +++ b/Marlin/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/Cartesio/Configuration_adv.h b/Marlin/example_configurations/Cartesio/Configuration_adv.h index d17635221200..e638f5b5bcf2 100644 --- a/Marlin/example_configurations/Cartesio/Configuration_adv.h +++ b/Marlin/example_configurations/Cartesio/Configuration_adv.h @@ -561,7 +561,7 @@ const unsigned int dropsegments = 5; //everything with less than this number of #define FILAMENT_CHANGE_RETRACT_LENGTH 1 // Initial retract in mm // It is a short retract used immediately after print interrupt before move to filament exchange position #define FILAMENT_CHANGE_RETRACT_FEEDRATE 60 // Initial retract feedrate in mm/s - //#define FILAMENT_CHANGE_UNLOAD_LENGTH 100 // Unload filament length from hotend in mm + #define FILAMENT_CHANGE_UNLOAD_LENGTH 100 // Unload filament length from hotend in mm // Longer length for bowden printers to unload filament from whole bowden tube, // shorter lenght for printers without bowden to unload filament from extruder only, // 0 to disable unloading for manual unloading @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/Felix/Configuration.h b/Marlin/example_configurations/Felix/Configuration.h index 768cf8ddd2fc..d8495eb840d3 100644 --- a/Marlin/example_configurations/Felix/Configuration.h +++ b/Marlin/example_configurations/Felix/Configuration.h @@ -1138,12 +1138,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Felix/Configuration_adv.h b/Marlin/example_configurations/Felix/Configuration_adv.h index ffad119958a7..a2324b48cfc5 100644 --- a/Marlin/example_configurations/Felix/Configuration_adv.h +++ b/Marlin/example_configurations/Felix/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/Hephestos/Configuration.h b/Marlin/example_configurations/Hephestos/Configuration.h index 0de2d211de24..a047e59c5570 100644 --- a/Marlin/example_configurations/Hephestos/Configuration.h +++ b/Marlin/example_configurations/Hephestos/Configuration.h @@ -1147,12 +1147,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Hephestos/Configuration_adv.h b/Marlin/example_configurations/Hephestos/Configuration_adv.h index 8956c41cd1eb..c458a76703e6 100644 --- a/Marlin/example_configurations/Hephestos/Configuration_adv.h +++ b/Marlin/example_configurations/Hephestos/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/Hephestos_2/Configuration.h b/Marlin/example_configurations/Hephestos_2/Configuration.h index 0f9738dfef34..4704fa82271d 100644 --- a/Marlin/example_configurations/Hephestos_2/Configuration.h +++ b/Marlin/example_configurations/Hephestos_2/Configuration.h @@ -1149,12 +1149,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/Hephestos_2/Configuration_adv.h b/Marlin/example_configurations/Hephestos_2/Configuration_adv.h index 704b20ce4066..bfca8536d07f 100644 --- a/Marlin/example_configurations/Hephestos_2/Configuration_adv.h +++ b/Marlin/example_configurations/Hephestos_2/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/K8200/Configuration.h b/Marlin/example_configurations/K8200/Configuration.h index 25a218032678..5267edcbd24e 100644 --- a/Marlin/example_configurations/K8200/Configuration.h +++ b/Marlin/example_configurations/K8200/Configuration.h @@ -1172,12 +1172,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/K8200/Configuration_adv.h b/Marlin/example_configurations/K8200/Configuration_adv.h index 1a00bb37615e..281b2a54e703 100644 --- a/Marlin/example_configurations/K8200/Configuration_adv.h +++ b/Marlin/example_configurations/K8200/Configuration_adv.h @@ -581,8 +581,17 @@ const unsigned int dropsegments = 2; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h b/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h index 1f540dbd32b6..e394b6b2af77 100644 --- a/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h +++ b/Marlin/example_configurations/RepRapWorld/Megatronics/Configuration.h @@ -1155,12 +1155,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/RigidBot/Configuration.h b/Marlin/example_configurations/RigidBot/Configuration.h index 070d0f94cb0b..ad5c40850025 100644 --- a/Marlin/example_configurations/RigidBot/Configuration.h +++ b/Marlin/example_configurations/RigidBot/Configuration.h @@ -1155,12 +1155,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/RigidBot/Configuration_adv.h b/Marlin/example_configurations/RigidBot/Configuration_adv.h index e1280f2d2ef9..809a4ccf0a1e 100644 --- a/Marlin/example_configurations/RigidBot/Configuration_adv.h +++ b/Marlin/example_configurations/RigidBot/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/SCARA/Configuration.h b/Marlin/example_configurations/SCARA/Configuration.h index 910fb58bd7ad..1c23794d014f 100644 --- a/Marlin/example_configurations/SCARA/Configuration.h +++ b/Marlin/example_configurations/SCARA/Configuration.h @@ -1163,12 +1163,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/SCARA/Configuration_adv.h b/Marlin/example_configurations/SCARA/Configuration_adv.h index 475e0335a44a..dafbbb023df9 100644 --- a/Marlin/example_configurations/SCARA/Configuration_adv.h +++ b/Marlin/example_configurations/SCARA/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/TAZ4/Configuration.h b/Marlin/example_configurations/TAZ4/Configuration.h index ec4ab82a0b7f..e5a7dd84431f 100644 --- a/Marlin/example_configurations/TAZ4/Configuration.h +++ b/Marlin/example_configurations/TAZ4/Configuration.h @@ -1176,12 +1176,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/WITBOX/Configuration.h b/Marlin/example_configurations/WITBOX/Configuration.h index 00acb9c35986..d3012dbfb1b0 100644 --- a/Marlin/example_configurations/WITBOX/Configuration.h +++ b/Marlin/example_configurations/WITBOX/Configuration.h @@ -1147,12 +1147,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/WITBOX/Configuration_adv.h b/Marlin/example_configurations/WITBOX/Configuration_adv.h index 8956c41cd1eb..c458a76703e6 100644 --- a/Marlin/example_configurations/WITBOX/Configuration_adv.h +++ b/Marlin/example_configurations/WITBOX/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/adafruit/ST7565/Configuration.h b/Marlin/example_configurations/adafruit/ST7565/Configuration.h index c0b8a95de8be..9c4f23d18181 100644 --- a/Marlin/example_configurations/adafruit/ST7565/Configuration.h +++ b/Marlin/example_configurations/adafruit/ST7565/Configuration.h @@ -1155,12 +1155,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/biv2.5/Configuration.h b/Marlin/example_configurations/delta/biv2.5/Configuration.h index 37711cc6b10b..5dd547a516df 100644 --- a/Marlin/example_configurations/delta/biv2.5/Configuration.h +++ b/Marlin/example_configurations/delta/biv2.5/Configuration.h @@ -1240,12 +1240,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/biv2.5/Configuration_adv.h b/Marlin/example_configurations/delta/biv2.5/Configuration_adv.h index 894e861633e6..5b76073e90e3 100644 --- a/Marlin/example_configurations/delta/biv2.5/Configuration_adv.h +++ b/Marlin/example_configurations/delta/biv2.5/Configuration_adv.h @@ -577,8 +577,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/delta/generic/Configuration.h b/Marlin/example_configurations/delta/generic/Configuration.h index e6c1a576b170..509cfca31dca 100644 --- a/Marlin/example_configurations/delta/generic/Configuration.h +++ b/Marlin/example_configurations/delta/generic/Configuration.h @@ -1234,12 +1234,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/generic/Configuration_adv.h b/Marlin/example_configurations/delta/generic/Configuration_adv.h index fba00960a25e..c3cfa0e14202 100644 --- a/Marlin/example_configurations/delta/generic/Configuration_adv.h +++ b/Marlin/example_configurations/delta/generic/Configuration_adv.h @@ -577,8 +577,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/delta/kossel_mini/Configuration.h b/Marlin/example_configurations/delta/kossel_mini/Configuration.h index 8a5619241450..f2e3b46f955b 100644 --- a/Marlin/example_configurations/delta/kossel_mini/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_mini/Configuration.h @@ -1237,12 +1237,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h b/Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h index 7265b76284a6..a5af8027f578 100644 --- a/Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h +++ b/Marlin/example_configurations/delta/kossel_mini/Configuration_adv.h @@ -576,8 +576,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/delta/kossel_pro/Configuration.h b/Marlin/example_configurations/delta/kossel_pro/Configuration.h index 190f95d83926..66781c79663e 100644 --- a/Marlin/example_configurations/delta/kossel_pro/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_pro/Configuration.h @@ -1237,12 +1237,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_pro/Configuration_adv.h b/Marlin/example_configurations/delta/kossel_pro/Configuration_adv.h index 69eb9ce95659..e1051ad1ed44 100644 --- a/Marlin/example_configurations/delta/kossel_pro/Configuration_adv.h +++ b/Marlin/example_configurations/delta/kossel_pro/Configuration_adv.h @@ -581,8 +581,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/delta/kossel_xl/Configuration.h b/Marlin/example_configurations/delta/kossel_xl/Configuration.h index b73ac74b44d8..c62d63d3fa74 100644 --- a/Marlin/example_configurations/delta/kossel_xl/Configuration.h +++ b/Marlin/example_configurations/delta/kossel_xl/Configuration.h @@ -1239,12 +1239,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/delta/kossel_xl/Configuration_adv.h b/Marlin/example_configurations/delta/kossel_xl/Configuration_adv.h index f224fd60e7a4..67db137a43c8 100644 --- a/Marlin/example_configurations/delta/kossel_xl/Configuration_adv.h +++ b/Marlin/example_configurations/delta/kossel_xl/Configuration_adv.h @@ -577,8 +577,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/makibox/Configuration.h b/Marlin/example_configurations/makibox/Configuration.h index ec8b01f7f25a..6543925582a4 100644 --- a/Marlin/example_configurations/makibox/Configuration.h +++ b/Marlin/example_configurations/makibox/Configuration.h @@ -1158,12 +1158,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = false; // set to true to invert the l //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/makibox/Configuration_adv.h b/Marlin/example_configurations/makibox/Configuration_adv.h index 857f320e4666..2550c9230e0d 100644 --- a/Marlin/example_configurations/makibox/Configuration_adv.h +++ b/Marlin/example_configurations/makibox/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/example_configurations/tvrrug/Round2/Configuration.h b/Marlin/example_configurations/tvrrug/Round2/Configuration.h index f52469a857d9..8d14edadfb85 100644 --- a/Marlin/example_configurations/tvrrug/Round2/Configuration.h +++ b/Marlin/example_configurations/tvrrug/Round2/Configuration.h @@ -1149,12 +1149,7 @@ const bool Z_MIN_PROBE_ENDSTOP_INVERTING = true; // set to true to invert the lo //define BlinkM/CyzRgb Support //#define BLINKM -/* - * Define the size of the full retract and insert filament. The feed rate for the complete insertion/retract and the feedrate for the slow inserction -*/ -#define FILAMENTCOMPLETCHANGE_SIZE 75 -#define FILAMENTCOMPLETCHANGE_FAST_FEEDRATE 100 -#define FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE 1.5 + /*********************************************************************\ * R/C SERVO support * Sponsored by TrinityLabs, Reworked by codexmas diff --git a/Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h b/Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h index 69ee6e04b5c2..46f328b14e23 100644 --- a/Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h +++ b/Marlin/example_configurations/tvrrug/Round2/Configuration_adv.h @@ -575,8 +575,17 @@ const unsigned int dropsegments = 5; //everything with less than this number of // Filament can be extruded repeatedly from the filament exchange menu to fill the hotend, // or until outcoming filament color is not clear for filament color change #define FILAMENT_CHANGE_EXTRUDE_FEEDRATE 3 // Extrude filament feedrate in mm/s - must be slower than load feedrate - #endif -#endif + + //#define MANUAL_FILAMENT_CHANGE // Add Manual Filament Change to the LCD Menus + #if ENABLED(MANUAL_FILAMENT_CHANGE) + #define MFC_LOAD_LENGTH_CM 55 + #define MFC_NORMAL_SPEED 100 + #define MFC_SLOW_SPEED 3.5 + #endif + + #endif // FILAMENT_CHANGE_FEATURE + +#endif // ULTIPANEL /******************************************************************************\ * enable this section if you have TMC26X motor drivers. diff --git a/Marlin/language_en.h b/Marlin/language_en.h index 0ed948588c06..48fc57259998 100644 --- a/Marlin/language_en.h +++ b/Marlin/language_en.h @@ -651,17 +651,23 @@ #endif #endif // LCD_HEIGHT < 4 -#ifndef MSG_CHANGE_FILAMENT - #define MSG_CHANGE_FILAMENT "Filament" +#ifndef MSG_CHANGE_FILAMENT + #define MSG_CHANGE_FILAMENT "Filament" #endif -#ifndef MSG_REMOVE_FILAMENT - #define MSG_REMOVE_FILAMENT "Remove" +#ifndef MSG_EJECT_FILAMENT + #define MSG_EJECT_FILAMENT "Eject" #endif -#ifndef MSG_INSERT_FILAMENT - #define MSG_INSERT_FILAMENT "Insert" +#ifndef MSG_INSERT_FILAMENT + #define MSG_INSERT_FILAMENT "Insert" #endif -#ifndef MSG_INSERT_FILAMENT_SLOW - #define MSG_INSERT_FILAMENT_SLOW "Slow Insert" +#ifndef MSG_INSERT_FILAMENT_SLOW + #define MSG_INSERT_FILAMENT_SLOW "Slow Insert" +#endif +#ifndef MSG_STOP_EJECT + #define MSG_STOP_EJECT "Stop " MSG_EJECT_FILAMENT +#endif +#ifndef MSG_STOP_INSERT + #define MSG_STOP_INSERT "Stop " MSG_INSERT_FILAMENT #endif #endif // LANGUAGE_EN_H diff --git a/Marlin/language_pt-br.h b/Marlin/language_pt-br.h index bff2189b8a88..5f0d06e85214 100644 --- a/Marlin/language_pt-br.h +++ b/Marlin/language_pt-br.h @@ -170,9 +170,9 @@ #define MSG_DELTA_CALIBRATE_Z "Calibrar Z" #define MSG_DELTA_CALIBRATE_CENTER "Calibrar Centro" - #define MSG_CHANGE_FILAMENT "Filamento" -#define MSG_REMOVE_FILAMENT "Retirar" +#define MSG_EJECT_FILAMENT "Retirar" #define MSG_INSERT_FILAMENT "Inserir" #define MSG_INSERT_FILAMENT_SLOW "Lentamente" + #endif // LANGUAGE_PT_BR_H diff --git a/Marlin/ultralcd.cpp b/Marlin/ultralcd.cpp index 3fa5813b99a5..72033801f181 100755 --- a/Marlin/ultralcd.cpp +++ b/Marlin/ultralcd.cpp @@ -41,9 +41,11 @@ int absPreheatHotendTemp; int absPreheatHPBTemp; int absPreheatFanSpeed; -bool filamentInsert; -bool filamentSlowInsert; -bool filamentRemove; +#if ENABLED(MANUAL_FILAMENT_CHANGE) + enum MFCState { MFC_IDLE, MFC_EJECTING, MFC_INSERTING, MFC_INSERTING_SLOW }; + MFCState mfc_state = MFC_IDLE; + bool mfc_filament_slow_inserting = false; +#endif #if ENABLED(FILAMENT_LCD_DISPLAY) millis_t previous_lcd_status_ms = 0; @@ -144,11 +146,10 @@ uint8_t lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; // Set when the LCD needs to static void lcd_filament_change_resume_message(); #endif - static void lcd_change_filament_menu(); - static void lcd_retract_filament(); - static void lcd_insert_filament_menu(); - static void lcd_insert_filament(); - static void lcd_insert_filament_slow(); + #if ENABLED(MANUAL_FILAMENT_CHANGE) + static void lcd_change_filament_menu(); + static void lcd_insert_filament(); + #endif #if HAS_LCD_CONTRAST static void lcd_set_contrast(); @@ -568,7 +569,9 @@ static void lcd_status_screen() { static void lcd_main_menu() { START_MENU(); MENU_ITEM(back, MSG_WATCH); - MENU_ITEM(submenu, MSG_CHANGE_FILAMENT, lcd_change_filament_menu); + #if ENABLED(MANUAL_FILAMENT_CHANGE) + MENU_ITEM(submenu, MSG_CHANGE_FILAMENT, lcd_change_filament_menu); + #endif if (planner.movesplanned() || IS_SD_PRINTING) { MENU_ITEM(submenu, MSG_TUNE, lcd_tune_menu); } @@ -812,7 +815,7 @@ static void lcd_status_screen() { // // Change filament // - #if ENABLED(FILAMENT_CHANGE_FEATURE) + #if ENABLED(FILAMENT_CHANGE_FEATURE) && DISABLED(MANUAL_FILAMENT_CHANGE) MENU_ITEM(gcode, MSG_FILAMENTCHANGE, PSTR("M600")); #endif @@ -1160,50 +1163,77 @@ static void lcd_status_screen() { #endif // MANUAL_BED_LEVELING - /** - * - * "Change Filament" submenu - * - */ - static void lcd_change_filament_menu() { - START_MENU(); - MENU_ITEM(back, MSG_MAIN); - MENU_ITEM(function, MSG_REMOVE_FILAMENT , lcd_retract_filament); - MENU_ITEM(submenu, MSG_INSERT_FILAMENT , lcd_insert_filament_menu); - END_MENU(); - } + #if ENABLED(MANUAL_FILAMENT_CHANGE) - static void lcd_insert_filament_menu() { - START_MENU(); - MENU_ITEM(back, MSG_CHANGE_FILAMENT); - MENU_ITEM_EDIT_CALLBACK(bool, MSG_INSERT_FILAMENT_SLOW ,&filamentSlowInsert ,lcd_insert_filament_slow); - if(!filamentSlowInsert) - MENU_ITEM(function, MSG_INSERT_FILAMENT , lcd_insert_filament); - END_MENU(); - } + /** + * + * "Change Filament" submenu + * + */ - static void lcd_insert_filament_slow(){ - while (filamentSlowInsert) { - //While the selection at menu is true it keeps slowing insert till the filament in on the tube - current_position[E_AXIS] += 1.0; - plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_SLOW_FEEDRATE, active_extruder); - st_synchronize(); + static void lcd_set_mfc_state(MFCState state) { + mfc_state = state; + lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; + defer_return_to_status = (state != MFC_IDLE); + mfc_filament_slow_inserting = (state == MFC_INSERTING_SLOW); } - } - static void lcd_retract_filament() { - //This value must be setted according the size you have at your printer - current_position[E_AXIS] -= FILAMENTCOMPLETCHANGE_SIZE; - plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_FAST_FEEDRATE, active_extruder); - st_synchronize(); - } + inline void lcd_stop_mfc() { lcd_set_mfc_state(MFC_IDLE); } - static void lcd_insert_filament(){ - //This value must be setted according the size you have at your printer - current_position[E_AXIS] += FILAMENTCOMPLETCHANGE_SIZE; - plan_buffer_line(current_position[(X_AXIS)], current_position[(Y_AXIS)], current_position[(Z_AXIS)], current_position[E_AXIS], FILAMENTCOMPLETCHANGE_FAST_FEEDRATE, active_extruder); - st_synchronize(); - } + static void lcd_mfc_move(const MFCState state, const float distance, const float speed=100.0) { + lcd_set_mfc_state(state); + int count = MFC_LOAD_LENGTH_CM * 10; + #if ENABLED(DELTA) + calculate_delta(current_position); + #define MFC_DEST(axis) delta[axis] + #else + #define MFC_DEST(axis) current_position[axis] + #endif + while (mfc_state == state && count--) { + if (state == MFC_INSERTING_SLOW && !mfc_filament_slow_inserting) break; + current_position[E_AXIS] += distance; + planner.buffer_line(MFC_DEST(X_AXIS), MFC_DEST(Y_AXIS), MFC_DEST(Z_AXIS), current_position[E_AXIS], speed, active_extruder); + stepper.synchronize(); + } + lcd_stop_mfc(); + } + static void lcd_eject_filament() { lcd_mfc_move(MFC_EJECTING, -1.0, MFC_NORMAL_SPEED); } + static void lcd_insert_filament() { lcd_mfc_move(MFC_INSERTING, 1.0, MFC_NORMAL_SPEED); } + static void lcd_insert_filament_slow_callback() { + if (mfc_filament_slow_inserting) + lcd_mfc_move(MFC_INSERTING_SLOW, 1.0, MFC_SLOW_SPEED); + else + lcd_stop_mfc(); + } + + static void lcd_insert_filament_menu() { + START_MENU(); + MENU_ITEM(back, MSG_CHANGE_FILAMENT); + MENU_ITEM_EDIT_CALLBACK(bool, MSG_INSERT_FILAMENT_SLOW, &mfc_filament_slow_inserting, lcd_insert_filament_slow_callback); + if (mfc_state == MFC_IDLE) MENU_ITEM(function, MSG_INSERT_FILAMENT, lcd_insert_filament); + END_MENU(); + } + + static void lcd_change_filament_menu() { + START_MENU(); + MENU_ITEM(back, MSG_MAIN); + switch (mfc_state) { + case MFC_IDLE: + MENU_ITEM(function, MSG_EJECT_FILAMENT, lcd_eject_filament); + MENU_ITEM(submenu, MSG_INSERT_FILAMENT, lcd_insert_filament_menu); + break; + case MFC_EJECTING: + MENU_ITEM(function, MSG_STOP_EJECT, lcd_stop_mfc); + break; + case MFC_INSERTING: + case MFC_INSERTING_SLOW: + MENU_ITEM(function, MSG_STOP_INSERT, lcd_stop_mfc); + break; + } + END_MENU(); + } + + #endif // MANUAL_FILAMENT_CHANGE /** * From 5fc24f51899cd1359a9b0bdf2d816d0c04665ea9 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 24 Apr 2016 16:26:45 -0700 Subject: [PATCH 3/3] Include MANUAL_FILAMENT_CHANGE in Travis test --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index eb471fd11e4a..ac08fa594c0c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -161,11 +161,11 @@ script: - opt_set MOTHERBOARD BOARD_MINIRAMBO - build_marlin # - # Test FILAMENT_CHANGE_FEATURE and LCD_INFO_MENU + # Test FILAMENTCHANGEENABLE, MANUAL_FILAMENT_CHANGE, and LCD_INFO_MENU # - restore_configs - opt_enable ULTIMAKERCONTROLLER - - opt_enable_adv FILAMENT_CHANGE_FEATURE LCD_INFO_MENU + - opt_enable_adv FILAMENTCHANGEENABLE MANUAL_FILAMENT_CHANGE LCD_INFO_MENU - build_marlin # # Enable filament sensor