|
@@ -1312,7 +1312,7 @@ void Planner::_buffer_line(const float &a, const float &b, const float &c, const
|
1312
|
1312
|
|
1313
|
1313
|
// The junction velocity will be shared between successive segments. Limit the junction velocity to their minimum.
|
1314
|
1314
|
const bool prev_speed_larger = previous_nominal_speed > block->nominal_speed;
|
1315
|
|
- float smaller_speed_factor = prev_speed_larger ? (block->nominal_speed / previous_nominal_speed) : (previous_nominal_speed / block->nominal_speed);
|
|
1315
|
+ const float smaller_speed_factor = prev_speed_larger ? (block->nominal_speed / previous_nominal_speed) : (previous_nominal_speed / block->nominal_speed);
|
1316
|
1316
|
// Pick the smaller of the nominal speeds. Higher speed shall not be achieved at the junction during coasting.
|
1317
|
1317
|
vmax_junction = prev_speed_larger ? block->nominal_speed : previous_nominal_speed;
|
1318
|
1318
|
// Factor to multiply the previous / current nominal velocities to get componentwise limited velocities.
|
|
@@ -1444,10 +1444,10 @@ void Planner::_set_position_mm(const float &a, const float &b, const float &c, c
|
1444
|
1444
|
#else
|
1445
|
1445
|
#define _EINDEX E_AXIS
|
1446
|
1446
|
#endif
|
1447
|
|
- long na = position[X_AXIS] = LROUND(a * axis_steps_per_mm[X_AXIS]),
|
1448
|
|
- nb = position[Y_AXIS] = LROUND(b * axis_steps_per_mm[Y_AXIS]),
|
1449
|
|
- nc = position[Z_AXIS] = LROUND(c * axis_steps_per_mm[Z_AXIS]),
|
1450
|
|
- ne = position[E_AXIS] = LROUND(e * axis_steps_per_mm[_EINDEX]);
|
|
1447
|
+ const long na = position[X_AXIS] = LROUND(a * axis_steps_per_mm[X_AXIS]),
|
|
1448
|
+ nb = position[Y_AXIS] = LROUND(b * axis_steps_per_mm[Y_AXIS]),
|
|
1449
|
+ nc = position[Z_AXIS] = LROUND(c * axis_steps_per_mm[Z_AXIS]),
|
|
1450
|
+ ne = position[E_AXIS] = LROUND(e * axis_steps_per_mm[_EINDEX]);
|
1451
|
1451
|
#if ENABLED(LIN_ADVANCE)
|
1452
|
1452
|
position_float[X_AXIS] = a;
|
1453
|
1453
|
position_float[Y_AXIS] = b;
|