Procházet zdrojové kódy

Release UI on G26 priming timeout (#16449)

Tanguy Pruvot před 5 roky
rodič
revize
c8ac908db2
1 změnil soubory, kde provedl 6 přidání a 5 odebrání
  1. 6
    5
      Marlin/src/gcode/bedlevel/G26.cpp

+ 6
- 5
Marlin/src/gcode/bedlevel/G26.cpp Zobrazit soubor

418
 inline bool prime_nozzle() {
418
 inline bool prime_nozzle() {
419
 
419
 
420
   const feedRate_t fr_slow_e = planner.settings.max_feedrate_mm_s[E_AXIS] / 15.0f;
420
   const feedRate_t fr_slow_e = planner.settings.max_feedrate_mm_s[E_AXIS] / 15.0f;
421
-  #if HAS_LCD_MENU
421
+  #if HAS_LCD_MENU && DISABLED(TOUCH_BUTTONS) // ui.button_pressed issue with touchscreen
422
     #if ENABLED(PREVENT_LENGTHY_EXTRUDE)
422
     #if ENABLED(PREVENT_LENGTHY_EXTRUDE)
423
       float Total_Prime = 0.0;
423
       float Total_Prime = 0.0;
424
     #endif
424
     #endif
425
 
425
 
426
     if (g26_prime_flag == -1) {  // The user wants to control how much filament gets purged
426
     if (g26_prime_flag == -1) {  // The user wants to control how much filament gets purged
427
-      #if HAS_LCD_MENU
428
-        ui.capture();
429
-      #endif
427
+      ui.capture();
430
       ui.set_status_P(GET_TEXT(MSG_G26_MANUAL_PRIME), 99);
428
       ui.set_status_P(GET_TEXT(MSG_G26_MANUAL_PRIME), 99);
431
       ui.chirp();
429
       ui.chirp();
432
 
430
 
439
         destination.e += 0.25;
437
         destination.e += 0.25;
440
         #if ENABLED(PREVENT_LENGTHY_EXTRUDE)
438
         #if ENABLED(PREVENT_LENGTHY_EXTRUDE)
441
           Total_Prime += 0.25;
439
           Total_Prime += 0.25;
442
-          if (Total_Prime >= EXTRUDE_MAXLENGTH) return G26_ERR;
440
+          if (Total_Prime >= EXTRUDE_MAXLENGTH) {
441
+            ui.release();
442
+            return G26_ERR;
443
+          }
443
         #endif
444
         #endif
444
         prepare_internal_move_to_destination(fr_slow_e);
445
         prepare_internal_move_to_destination(fr_slow_e);
445
         destination = current_position;
446
         destination = current_position;

Loading…
Zrušit
Uložit