mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-24 07:04:01 -06:00
toolhead: Fill cmove in toolhead instead of in each kinematic class
This simplifies the kinematic classes. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
8faab46ed2
commit
b988596519
4 changed files with 15 additions and 28 deletions
|
@ -22,8 +22,6 @@ class CoreXYKinematics:
|
|||
self.limits = [(1.0, -1.0)] * 3
|
||||
# Setup iterative solver
|
||||
ffi_main, ffi_lib = chelper.get_ffi()
|
||||
self.cmove = ffi_main.gc(ffi_lib.move_alloc(), ffi_lib.free)
|
||||
self.move_fill = ffi_lib.move_fill
|
||||
self.rails[0].setup_itersolve(ffi_main.gc(
|
||||
ffi_lib.corexy_stepper_alloc('+'), ffi_lib.free))
|
||||
self.rails[1].setup_itersolve(ffi_main.gc(
|
||||
|
@ -128,13 +126,7 @@ class CoreXYKinematics:
|
|||
if self.need_motor_enable:
|
||||
self._check_motor_enable(print_time, move)
|
||||
axes_d = move.axes_d
|
||||
cmove = self.cmove
|
||||
self.move_fill(
|
||||
cmove, print_time,
|
||||
move.accel_t, move.cruise_t, move.decel_t,
|
||||
move.start_pos[0], move.start_pos[1], move.start_pos[2],
|
||||
axes_d[0], axes_d[1], axes_d[2],
|
||||
move.start_v, move.cruise_v, move.accel)
|
||||
cmove = move.cmove
|
||||
rail_x, rail_y, rail_z = self.rails
|
||||
if axes_d[0] or axes_d[1]:
|
||||
rail_x.step_itersolve(cmove)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue