From 75b73b09d635df4aa9002d9c1d486e52a7034ca0 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Sat, 30 Mar 2019 14:32:03 -0400 Subject: [PATCH] corexy: Fix minimum halt velocity Due to the corexy kinematics, the individual steppers may have a velocity of sqrt(2) times faster than the cartesian velocity _and_ can have an acceleration of sqrt(2) times faster. Make sure to calculate in the higher acceleration. Signed-off-by: Kevin O'Connor --- klippy/kinematics/corexy.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/klippy/kinematics/corexy.py b/klippy/kinematics/corexy.py index e7ab2f24..98db27eb 100644 --- a/klippy/kinematics/corexy.py +++ b/klippy/kinematics/corexy.py @@ -28,8 +28,9 @@ class CoreXYKinematics: # Setup stepper max halt velocity max_halt_velocity = toolhead.get_max_axis_halt() max_xy_halt_velocity = max_halt_velocity * math.sqrt(2.) - self.rails[0].set_max_jerk(max_xy_halt_velocity, max_accel) - self.rails[1].set_max_jerk(max_xy_halt_velocity, max_accel) + max_xy_accel = max_accel * math.sqrt(2.) + self.rails[0].set_max_jerk(max_xy_halt_velocity, max_xy_accel) + self.rails[1].set_max_jerk(max_xy_halt_velocity, max_xy_accel) self.rails[2].set_max_jerk( min(max_halt_velocity, self.max_z_velocity), self.max_z_accel) def get_steppers(self, flags=""):