mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-24 15:14:00 -06:00
kinematics: Convert get_rails() method to get_steppers()
All callers of get_rails() actually just want the steppers, so return them directly. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
89835940f7
commit
ca505bf4ac
6 changed files with 14 additions and 21 deletions
|
@ -43,10 +43,10 @@ class CartKinematics:
|
|||
self.printer.lookup_object('gcode').register_command(
|
||||
'SET_DUAL_CARRIAGE', self.cmd_SET_DUAL_CARRIAGE,
|
||||
desc=self.cmd_SET_DUAL_CARRIAGE_help)
|
||||
def get_rails(self, flags=""):
|
||||
def get_steppers(self, flags=""):
|
||||
if flags == "Z":
|
||||
return [self.rails[2]]
|
||||
return list(self.rails)
|
||||
return self.rails[2].get_steppers()
|
||||
return [s for rail in self.rails for s in rail.get_steppers()]
|
||||
def calc_position(self):
|
||||
return [rail.get_commanded_position() for rail in self.rails]
|
||||
def set_position(self, newpos, homing_axes):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue