Skip to content

Commit

Permalink
Merge pull request #1619 from MRprusa3d/PFW-795d
Browse files Browse the repository at this point in the history
better autoLoad II
  • Loading branch information
PavelSindler authored Mar 12, 2019
2 parents c55f429 + 3388444 commit 4203627
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
9 changes: 8 additions & 1 deletion Firmware/Marlin_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7515,11 +7515,18 @@ static void handleSafetyTimer()

void manage_inactivity(bool ignore_stepper_queue/*=false*/) //default argument set in Marlin.h
{
bool bInhibitFlag;
#ifdef FILAMENT_SENSOR
if (mmu_enabled == false)
{
//-// if (mcode_in_progress != 600) //M600 not in progress
if ((mcode_in_progress != 600) && (eFilamentAction != e_FILAMENT_ACTION_autoLoad) && (menu_menu!=lcd_menu_extruder_info)) //M600 not in progress, preHeat @ autoLoad menu not active, Support::ExtruderInfo menu not active
#ifdef PAT9125
bInhibitFlag=(menu_menu==lcd_menu_extruder_info); // Support::ExtruderInfo menu active
#endif // PAT9125
#ifdef IR_SENSOR
bInhibitFlag=(menu_menu==lcd_menu_show_sensors_state); // Support::SensorInfo menu active
#endif // IR_SENSOR
if ((mcode_in_progress != 600) && (eFilamentAction != e_FILAMENT_ACTION_autoLoad) && (!bInhibitFlag)) //M600 not in progress, preHeat @ autoLoad menu not active, Support::ExtruderInfo/SensorInfo menu not active
{
if (!moves_planned() && !IS_SD_PRINTING && !is_usb_printing && (lcd_commands_type != LCD_COMMAND_V2_CAL) && !wizard_active)
{
Expand Down
6 changes: 3 additions & 3 deletions Firmware/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -131,14 +131,14 @@ static void prusa_stat_farm_number();
static void prusa_stat_temperatures();
static void prusa_stat_printinfo();
static void lcd_farm_no();
void lcd_menu_extruder_info(); // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")
//static void lcd_menu_extruder_info(); // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")
static void lcd_menu_xyz_y_min();
static void lcd_menu_xyz_skew();
static void lcd_menu_xyz_offset();
static void lcd_menu_fails_stats_mmu();
static void lcd_menu_fails_stats_mmu_print();
static void lcd_menu_fails_stats_mmu_total();
static void lcd_menu_show_sensors_state();
//static void lcd_menu_show_sensors_state(); // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")

static void mmu_fil_eject_menu();
static void mmu_load_to_nozzle_menu();
Expand Down Expand Up @@ -4057,7 +4057,7 @@ static void lcd_show_sensors_state()
lcd_print_state(idler_state);
}

static void lcd_menu_show_sensors_state()
void lcd_menu_show_sensors_state() // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")
{
lcd_timeoutToStatus.stop();
lcd_show_sensors_state();
Expand Down
1 change: 1 addition & 0 deletions Firmware/ultralcd.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ extern bool lcd_selftest();
void lcd_menu_statistics();

void lcd_menu_extruder_info(); // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")
void lcd_menu_show_sensors_state(); // NOT static due to using inside "Marlin_main" module ("manage_inactivity()")

extern const char* lcd_display_message_fullscreen_P(const char *msg, uint8_t &nlines);
extern const char* lcd_display_message_fullscreen_P(const char *msg);
Expand Down

0 comments on commit 4203627

Please sign in to comment.