mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-15 18:58:03 -06:00
homing: Directly interact with the kinematic class on query_endstops()
Move the query_endstop logic out of toolhead.py and into homing.py. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
8d9ca6f2dd
commit
f6d4284d5c
6 changed files with 15 additions and 21 deletions
|
@ -58,6 +58,8 @@ class DeltaKinematics:
|
|||
% (math.sqrt(self.max_xy2), math.sqrt(self.slow_xy2),
|
||||
math.sqrt(self.very_slow_xy2)))
|
||||
self.set_position([0., 0., 0.])
|
||||
def get_steppers(self):
|
||||
return list(self.steppers)
|
||||
def _cartesian_to_actuator(self, coord):
|
||||
return [math.sqrt(self.arm_length2
|
||||
- (self.towers[i][0] - coord[0])**2
|
||||
|
@ -124,8 +126,6 @@ class DeltaKinematics:
|
|||
+ self.steppers[i].get_homed_offset()
|
||||
for i in StepList]
|
||||
homing_state.set_homed_position(self._actuator_to_cartesian(spos))
|
||||
def query_endstops(self, print_time, query_flags):
|
||||
return homing.query_endstops(print_time, query_flags, self.steppers)
|
||||
def motor_off(self, print_time):
|
||||
self.limit_xy2 = -1.
|
||||
for stepper in self.steppers:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue