|
|
|
@ -1201,7 +1201,8 @@ void Planner::buffer_line(ARG_X, ARG_Y, ARG_Z, const float &e, float fr_mm_s, co
|
|
|
|
|
} // buffer_line()
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Directly set the planner XYZ position (hence the stepper positions).
|
|
|
|
|
* Directly set the planner XYZ position (and stepper positions)
|
|
|
|
|
* converting mm (or angles for SCARA) into steps.
|
|
|
|
|
*
|
|
|
|
|
* On CORE machines stepper ABC will be translated from the given XYZ.
|
|
|
|
|
*/
|
|
|
|
@ -1229,12 +1230,12 @@ void Planner::sync_from_steppers() {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Directly set the planner E position (hence the stepper E position).
|
|
|
|
|
* Setters for planner position (also setting stepper position).
|
|
|
|
|
*/
|
|
|
|
|
void Planner::set_e_position_mm(const float& e) {
|
|
|
|
|
position[E_AXIS] = lround(e * axis_steps_per_mm[E_AXIS]);
|
|
|
|
|
stepper.set_e_position(position[E_AXIS]);
|
|
|
|
|
previous_speed[E_AXIS] = 0.0;
|
|
|
|
|
void Planner::set_position_mm(const AxisEnum axis, const float& v) {
|
|
|
|
|
position[axis] = lround(v * axis_steps_per_mm[axis]);
|
|
|
|
|
stepper.set_position(axis, v);
|
|
|
|
|
previous_speed[axis] = 0.0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Recalculate the steps/s^2 acceleration rates, based on the mm/s^2
|
|
|
|
|