From 263f8edff8c4b649322193876e04442f15e66463 Mon Sep 17 00:00:00 2001 From: Thomas Moore Date: Mon, 25 Mar 2019 23:41:52 -0400 Subject: [PATCH] Disable volumetric extrusion during G26 (#13479) --- Marlin/src/gcode/bedlevel/G26.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Marlin/src/gcode/bedlevel/G26.cpp b/Marlin/src/gcode/bedlevel/G26.cpp index 20169dc586..a98eff5fb6 100644 --- a/Marlin/src/gcode/bedlevel/G26.cpp +++ b/Marlin/src/gcode/bedlevel/G26.cpp @@ -686,6 +686,12 @@ void GcodeSuite::G26() { set_current_from_destination(); } + #if DISABLED(NO_VOLUMETRICS) + bool volumetric_was_enabled = parser.volumetric_enabled; + parser.volumetric_enabled = false; + planner.calculate_volumetric_multipliers(); + #endif + if (turn_on_heaters() != G26_OK) goto LEAVE; current_position[E_AXIS] = 0.0; @@ -909,6 +915,11 @@ void GcodeSuite::G26() { move_to(destination, 0); // Move back to the starting position //debug_current_and_destination(PSTR("done doing X/Y move.")); + #if DISABLED(NO_VOLUMETRICS) + parser.volumetric_enabled = volumetric_was_enabled; + planner.calculate_volumetric_multipliers(); + #endif + #if HAS_LCD_MENU ui.release(); // Give back control of the LCD #endif