mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-10 00:07:54 -06:00
homing: Directly interact with the kinematic class when homing
Move the homing logic out of toolhead.py and into homing.py. This simplifies the toolhead logic and centralizes the homing code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
1d6af72de5
commit
8d9ca6f2dd
3 changed files with 13 additions and 10 deletions
|
@ -354,11 +354,11 @@ class GCodeParser:
|
|||
axes.append(self.axis2pos[axis])
|
||||
if not axes:
|
||||
axes = [0, 1, 2]
|
||||
homing_state = homing.Homing(self.toolhead, axes)
|
||||
homing_state = homing.Homing(self.toolhead)
|
||||
if self.is_fileinput:
|
||||
homing_state.set_no_verify_retract()
|
||||
try:
|
||||
self.toolhead.home(homing_state)
|
||||
homing_state.home_axes(axes)
|
||||
except homing.EndstopError as e:
|
||||
raise error(str(e))
|
||||
newpos = self.toolhead.get_position()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue