Browse Source

🐛 Update H-bot / Core for 6-axis (#22600)

Followup to #19112
vanilla_fb_2.0.x
Fjederhaek 3 years ago
committed by Scott Lahteine
parent
commit
f7ce107ac6
  1. 21
      Marlin/src/module/planner.cpp

21
Marlin/src/module/planner.cpp

@ -2002,15 +2002,15 @@ bool Planner::_populate_block(block_t * const block, bool split_move,
// Number of steps for each axis // Number of steps for each axis
// See https://www.corexy.com/theory.html // See https://www.corexy.com/theory.html
#if CORE_IS_XY #if CORE_IS_XY
block->steps.set(ABS(da + db), ABS(da - db), ABS(dc)); block->steps.set(LINEAR_AXIS_LIST(ABS(da + db), ABS(da - db), ABS(dc), ABS(di), ABS(dj), ABS(dk)));
#elif CORE_IS_XZ #elif CORE_IS_XZ
block->steps.set(ABS(da + dc), ABS(db), ABS(da - dc)); block->steps.set(LINEAR_AXIS_LIST(ABS(da + dc), ABS(db), ABS(da - dc), ABS(di), ABS(dj), ABS(dk)));
#elif CORE_IS_YZ #elif CORE_IS_YZ
block->steps.set(ABS(da), ABS(db + dc), ABS(db - dc)); block->steps.set(LINEAR_AXIS_LIST(ABS(da), ABS(db + dc), ABS(db - dc), ABS(di), ABS(dj), ABS(dk)));
#elif ENABLED(MARKFORGED_XY) #elif ENABLED(MARKFORGED_XY)
block->steps.set(ABS(da + db), ABS(db), ABS(dc)); block->steps.set(LINEAR_AXIS_LIST(ABS(da + db), ABS(db), ABS(dc), ABS(di), ABS(dj), ABS(dk)));
#elif IS_SCARA #elif IS_SCARA
block->steps.set(ABS(da), ABS(db), ABS(dc)); block->steps.set(LINEAR_AXIS_LIST(ABS(da), ABS(db), ABS(dc), ABS(di), ABS(dj), ABS(dk)));
#else #else
// default non-h-bot planning // default non-h-bot planning
block->steps.set(LINEAR_AXIS_LIST(ABS(da), ABS(db), ABS(dc), ABS(di), ABS(dj), ABS(dk))); block->steps.set(LINEAR_AXIS_LIST(ABS(da), ABS(db), ABS(dc), ABS(di), ABS(dj), ABS(dk)));
@ -2208,6 +2208,17 @@ bool Planner::_populate_block(block_t * const block, bool split_move,
if (block->steps.k) ENABLE_AXIS_K() if (block->steps.k) ENABLE_AXIS_K()
); );
#endif #endif
#if EITHER(IS_CORE, MARKFORGED_XY)
#if LINEAR_AXES >= 4
if (block->steps.i) ENABLE_AXIS_I();
#endif
#if LINEAR_AXES >= 5
if (block->steps.j) ENABLE_AXIS_J();
#endif
#if LINEAR_AXES >= 6
if (block->steps.k) ENABLE_AXIS_K();
#endif
#endif
// Enable extruder(s) // Enable extruder(s)
#if HAS_EXTRUDERS #if HAS_EXTRUDERS

Loading…
Cancel
Save