Fixes for LCD change filament (T1438, T1221)

- "Change filament" now allows extruder selection on dual extruder heads (T1438)
- Fix for broken M600 resume_print; head motion during M600; backport from upstream (T1221)
master
Marcio Teixeira 7 years ago
parent a0799ea772
commit 67c6590fa6

@ -13,7 +13,7 @@
* got disabled.
*/
#define LULZBOT_FW_VERSION ".55" // Change this with each update
#define LULZBOT_FW_VERSION ".56" // Change this with each update
#if ( \
!defined(LULZBOT_Gladiola_Mini) && \
@ -130,7 +130,7 @@
#define LULZBOT_SENSORLESS_HOMING
#define LULZBOT_USE_TMC_STEALTHCHOP_Z
#define LULZBOT_USE_Z_BELT
#define LULZBOT_USE_STATUS_LED
#define LULZBOT_USE_EXPERIMENTAL_FEATURES
#define LULZBOT_BAUDRATE 250000
#define LULZBOT_PRINTCOUNTER
#define LULZBOT_UUID "e5502411-d46d-421d-ba3a-a20126d7930f"
@ -149,7 +149,7 @@
#define LULZBOT_SENSORLESS_HOMING
#define LULZBOT_USE_TMC_STEALTHCHOP_Z
#define LULZBOT_USE_Z_BELT
#define LULZBOT_USE_STATUS_LED
#define LULZBOT_USE_EXPERIMENTAL_FEATURES
#define LULZBOT_BAUDRATE 250000
#define LULZBOT_PRINTCOUNTER
#define LULZBOT_UUID "e5502411-d46d-421d-ba3a-a20126d7930f"
@ -249,6 +249,15 @@
// as described in T1393
#define LULZBOT_ENDSTOPS_ALWAYS_ON_DEFAULT_WORKAROUND
// Backport of upstream Marlin fix T7811 related to M600 resume_print
#define LULZBOT_M600_BACKPORT_T7811
/************************* EXPERIMENTAL FEATURES ******************************/
#if defined(LULZBOT_USE_EXPERIMENTAL_FEATURES)
#define LULZBOT_USE_STATUS_LED
#endif
/******************** MOTHERBOARD AND PIN CONFIGURATION ***********************/
#if defined(TOOLHEAD_Devel_ServoDual)
@ -1798,8 +1807,10 @@
#define LULZBOT_SCROLL_LONG_FILE_NAMES
#define LULZBOT_REORDERED_MENUS
#define LULZBOT_ESTEP_REDUCED_LCD_PRECISION
#if LULZBOT_EXTRUDERS > 0
#define LULZBOT_CHANGE_FILAMENT_DUAL_EXTRUDER_SUPPORT
#endif
#endif
/* Marlin requires static PSTRs to display on the LCD display, because of this */
/* we have to use a preprocessor trick to append the heater name on temp errors */

@ -6343,6 +6343,10 @@ inline void gcode_M17() {
KEEPALIVE_STATE(IN_HANDLER);
}
#if defined(LULZBOT_CHANGE_FILAMENT_DUAL_EXTRUDER_SUPPORT)
void LULZBOT_RESTORE_ACTIVE_TOOLHEAD();
#endif
static void resume_print(const float &load_length = 0, const float &initial_extrude_length = 0, const int8_t max_beep_count = 0) {
bool nozzle_timed_out = false;
@ -6360,6 +6364,10 @@ inline void gcode_M17() {
filament_change_beep(max_beep_count, true);
#endif
#if defined(LULZBOT_M600_BACKPORT_T7811)
set_destination_to_current();
#endif
if (load_length != 0) {
#if ENABLED(ULTIPANEL)
// Show "insert filament"
@ -6439,6 +6447,10 @@ inline void gcode_M17() {
lcd_advanced_pause_show_message(ADVANCED_PAUSE_MESSAGE_STATUS);
#endif
#if defined(LULZBOT_CHANGE_FILAMENT_DUAL_EXTRUDER_SUPPORT)
LULZBOT_RESTORE_ACTIVE_TOOLHEAD();
#endif
#if ENABLED(SDSUPPORT)
if (sd_print_paused) {
card.startFileprint();
@ -6447,6 +6459,7 @@ inline void gcode_M17() {
#endif
move_away_flag = false;
}
#endif // ADVANCED_PAUSE_FEATURE

@ -899,6 +899,33 @@ void kill_screen(const char* lcd_msg) {
static void lcd_store_settings();
static void lcd_load_settings();
#if defined(LULZBOT_CHANGE_FILAMENT_DUAL_EXTRUDER_SUPPORT)
void tool_change(const uint8_t tmp_extruder, const float fr_mm_s/*=0.0*/, bool no_move/*=false*/);
static uint8_t active_extruder_before_filament_change = -1;
void lcd_enqueue_filament_change_e0() {
if (axis_unhomed_error()) {lcd_return_to_status(); return;};
active_extruder_before_filament_change = active_extruder;
tool_change(0, 0, true);
lcd_enqueue_filament_change();
}
void lcd_enqueue_filament_change_e1() {
if (axis_unhomed_error()) {lcd_return_to_status(); return;};
active_extruder_before_filament_change = active_extruder;
tool_change(1, 0, true);
lcd_enqueue_filament_change();
}
void LULZBOT_RESTORE_ACTIVE_TOOLHEAD() {
if(active_extruder_before_filament_change > -1) {
tool_change(active_extruder_before_filament_change, 0, true);
active_extruder_before_filament_change = -1;
}
}
#endif
void lcd_main_menu() {
START_MENU();
@ -908,16 +935,24 @@ void kill_screen(const char* lcd_msg) {
if (isPrinting) {
MENU_ITEM(submenu, MSG_TUNE, lcd_tune_menu);
#if ENABLED(ADVANCED_PAUSE_FEATURE)
if (!thermalManager.tooColdToExtrude(active_extruder))
MENU_ITEM(function, MSG_FILAMENTCHANGE, lcd_enqueue_filament_change);
#endif
} else {
MENU_ITEM(submenu, _UxGT("Movement"), lcd_movement_menu);
MENU_ITEM(submenu, MSG_TEMPERATURE, lcd_control_temperature_menu);
MENU_ITEM(submenu, _UxGT("Configuration"), lcd_configuration_menu);
}
#if ENABLED(ADVANCED_PAUSE_FEATURE)
#if defined(LULZBOT_CHANGE_FILAMENT_DUAL_EXTRUDER_SUPPORT)
if (!thermalManager.tooColdToExtrude(0))
MENU_ITEM(function, MSG_FILAMENTCHANGE " E1", lcd_enqueue_filament_change_e0);
if (!thermalManager.tooColdToExtrude(1))
MENU_ITEM(function, MSG_FILAMENTCHANGE " E2", lcd_enqueue_filament_change_e1);
#else
if (!thermalManager.tooColdToExtrude(active_extruder))
MENU_ITEM(function, MSG_FILAMENTCHANGE, lcd_enqueue_filament_change_e0);
#endif
#endif
#if ENABLED(SDSUPPORT)
if (card.cardOK) {
if (card.isFileOpen()) {

Loading…
Cancel
Save