mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-07 15:07:33 -06:00
stepper: Add get_endstops() / set_position wrappers
Add wrappers around mcu_endstop and mcu_stepper so that the kinematic classes do not need to directly access these low-level classes. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
eecf3b6ea8
commit
38643f52c9
6 changed files with 33 additions and 21 deletions
|
@ -61,6 +61,8 @@ class MCU_stepper:
|
|||
self._mcu.register_stepqueue(self._stepqueue)
|
||||
def get_oid(self):
|
||||
return self._oid
|
||||
def get_step_dist(self):
|
||||
return self._step_dist
|
||||
def set_position(self, pos):
|
||||
if pos >= 0.:
|
||||
steppos = int(pos * self._inv_step_dist + 0.5)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue