|
@@ -2620,13 +2620,15 @@ bool Planner::buffer_line(const float &rx, const float &ry, const float &rz, con
|
2620
|
2620
|
if (mm == 0.0)
|
2621
|
2621
|
mm = (delta_mm_cart.x != 0.0 || delta_mm_cart.y != 0.0) ? delta_mm_cart.magnitude() : ABS(delta_mm_cart.z);
|
2622
|
2622
|
|
|
2623
|
+ // Cartesian XYZ to kinematic ABC, stored in global 'delta'
|
2623
|
2624
|
inverse_kinematics(machine);
|
2624
|
2625
|
|
2625
|
2626
|
#if ENABLED(SCARA_FEEDRATE_SCALING)
|
2626
|
2627
|
// For SCARA scale the feed rate from mm/s to degrees/s
|
2627
|
2628
|
// i.e., Complete the angular vector in the given time.
|
2628
|
2629
|
const float duration_recip = inv_duration ?: fr_mm_s / mm;
|
2629
|
|
- const feedRate_t feedrate = HYPOT(delta.a - position_float.a, delta.b - position_float.b) * duration_recip;
|
|
2630
|
+ const xyz_pos_t diff = delta - position_float;
|
|
2631
|
+ const feedRate_t feedrate = diff.magnitude() * duration_recip;
|
2630
|
2632
|
#else
|
2631
|
2633
|
const feedRate_t feedrate = fr_mm_s;
|
2632
|
2634
|
#endif
|