From 890298d34d76923e895ff7905b9dbe374035e694 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Fri, 22 Jun 2018 13:03:07 -0400 Subject: itersolve: Support setting the stepper position via a cartesian coordinate Add support for an itersolve_set_position() function that sets a stepper position from a cartesian coordinate. This eliminates the need for both the python and C code to be able to translate from a cartesian coordinate to a stepper position. Signed-off-by: Kevin O'Connor --- klippy/stepper.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'klippy/stepper.py') diff --git a/klippy/stepper.py b/klippy/stepper.py index 5a9bee70..e68512f7 100644 --- a/klippy/stepper.py +++ b/klippy/stepper.py @@ -243,9 +243,9 @@ class PrinterRail: def set_max_jerk(self, max_halt_velocity, max_accel): for stepper in self.steppers: stepper.set_max_jerk(max_halt_velocity, max_accel) - def set_position(self, pos): + def set_position(self, newpos): for stepper in self.steppers: - stepper.set_position(pos) + stepper.set_position(newpos) def motor_enable(self, print_time, enable=0): for stepper in self.steppers: stepper.motor_enable(print_time, enable) -- cgit v1.2.3-70-g09d2