chiark / gitweb /
Changed check i mtion_conrol
authorErik van der Zalm <erik@vdzalm.eu>
Thu, 9 Feb 2012 20:02:01 +0000 (21:02 +0100)
committerErik van der Zalm <erik@vdzalm.eu>
Thu, 9 Feb 2012 20:02:01 +0000 (21:02 +0100)
if (millimeters_of_travel == 0.0) => if (millimeters_of_travel < 0.001)
(thanks mooselake)

Marlin/motion_control.cpp

index ab403e981286ac4f274202064d6e573343b426de..a24b2b782cf695034fe9b62eb7f962982a365e21 100644 (file)
@@ -45,7 +45,7 @@ void mc_arc(float *position, float *target, float *offset, uint8_t axis_0, uint8
   if (isclockwise) { angular_travel -= 2*M_PI; }
   
   float millimeters_of_travel = hypot(angular_travel*radius, fabs(linear_travel));
-  if (millimeters_of_travel == 0.0) { return; }
+  if (millimeters_of_travel < 0.001) { return; }
   uint16_t segments = floor(millimeters_of_travel/MM_PER_ARC_SEGMENT);
   /*  
     // Multiply inverse feed_rate to compensate for the fact that this movement is approximated