Browse Source

Abort arc on planner hard stop

Alex Voinea 2 years ago
parent
commit
0b23ccdee9
1 changed files with 3 additions and 0 deletions
  1. 3 0
      Firmware/motion_control.cpp

+ 3 - 0
Firmware/motion_control.cpp

@@ -150,6 +150,9 @@ void mc_arc(float* position, float* target, float* offset, float feed_rate, floa
             clamp_to_software_endstops(position);
             // Insert the segment into the buffer
             plan_buffer_line(position[X_AXIS], position[Y_AXIS], position[Z_AXIS], position[E_AXIS], feed_rate, extruder, position);
+            // Handle the situation where the planner is aborted hard.
+            if (waiting_inside_plan_buffer_line_print_aborted)
+                return;
         }
     }
     // Clamp to the target position.