Adjust usage of stepper.synchronize
This commit is contained in:
@ -240,8 +240,6 @@ void move_to(const float &rx, const float &ry, const float &z, const float &e_de
|
||||
destination[E_AXIS] = current_position[E_AXIS];
|
||||
|
||||
G26_line_to_destination(feed_value);
|
||||
|
||||
stepper.synchronize();
|
||||
set_destination_from_current();
|
||||
}
|
||||
|
||||
@ -256,8 +254,6 @@ void move_to(const float &rx, const float &ry, const float &z, const float &e_de
|
||||
destination[E_AXIS] += e_delta;
|
||||
|
||||
G26_line_to_destination(feed_value);
|
||||
|
||||
stepper.synchronize();
|
||||
set_destination_from_current();
|
||||
}
|
||||
|
||||
@ -499,13 +495,11 @@ inline bool prime_nozzle() {
|
||||
if (Total_Prime >= EXTRUDE_MAXLENGTH) return G26_ERR;
|
||||
#endif
|
||||
G26_line_to_destination(planner.max_feedrate_mm_s[E_AXIS] / 15.0);
|
||||
|
||||
set_destination_from_current();
|
||||
stepper.synchronize(); // Without this synchronize, the purge is more consistent,
|
||||
// but because the planner has a buffer, we won't be able
|
||||
// to stop as quickly. So we put up with the less smooth
|
||||
// action to give the user a more responsive 'Stop'.
|
||||
set_destination_from_current();
|
||||
idle();
|
||||
}
|
||||
|
||||
wait_for_release();
|
||||
@ -526,7 +520,6 @@ inline bool prime_nozzle() {
|
||||
set_destination_from_current();
|
||||
destination[E_AXIS] += g26_prime_length;
|
||||
G26_line_to_destination(planner.max_feedrate_mm_s[E_AXIS] / 15.0);
|
||||
stepper.synchronize();
|
||||
set_destination_from_current();
|
||||
retract_filament(destination);
|
||||
}
|
||||
@ -700,7 +693,6 @@ void GcodeSuite::G26() {
|
||||
|
||||
if (current_position[Z_AXIS] < Z_CLEARANCE_BETWEEN_PROBES) {
|
||||
do_blocking_move_to_z(Z_CLEARANCE_BETWEEN_PROBES);
|
||||
stepper.synchronize();
|
||||
set_current_from_destination();
|
||||
}
|
||||
|
||||
|
@ -949,8 +949,8 @@ void GcodeSuite::G29() {
|
||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("Z Probe End Script: ", Z_PROBE_END_SCRIPT);
|
||||
#endif
|
||||
enqueue_and_echo_commands_P(PSTR(Z_PROBE_END_SCRIPT));
|
||||
stepper.synchronize();
|
||||
enqueue_and_echo_commands_P(PSTR(Z_PROBE_END_SCRIPT));
|
||||
#endif
|
||||
|
||||
// Auto Bed Leveling is complete! Enable if possible.
|
||||
|
@ -108,7 +108,6 @@ void GcodeSuite::M81() {
|
||||
safe_delay(1000); // Wait 1 second before switching off
|
||||
|
||||
#if HAS_SUICIDE
|
||||
stepper.synchronize();
|
||||
suicide();
|
||||
#elif HAS_POWER_SWITCH
|
||||
PSU_OFF();
|
||||
|
@ -43,8 +43,6 @@
|
||||
|
||||
void report_current_position_detail() {
|
||||
|
||||
stepper.synchronize();
|
||||
|
||||
SERIAL_PROTOCOLPGM("\nLogical:");
|
||||
const float logical[XYZ] = {
|
||||
LOGICAL_X_POSITION(current_position[X_AXIS]),
|
||||
@ -79,6 +77,8 @@
|
||||
report_xyz(delta);
|
||||
#endif
|
||||
|
||||
stepper.synchronize();
|
||||
|
||||
SERIAL_PROTOCOLPGM("Stepper:");
|
||||
LOOP_XYZE(i) {
|
||||
SERIAL_CHAR(' ');
|
||||
|
@ -58,6 +58,8 @@ void GcodeSuite::M0_M1() {
|
||||
|
||||
const bool has_message = !hasP && !hasS && args && *args;
|
||||
|
||||
stepper.synchronize();
|
||||
|
||||
#if ENABLED(ULTIPANEL)
|
||||
|
||||
if (has_message)
|
||||
@ -81,8 +83,6 @@ void GcodeSuite::M0_M1() {
|
||||
KEEPALIVE_STATE(PAUSED_FOR_USER);
|
||||
wait_for_user = true;
|
||||
|
||||
stepper.synchronize();
|
||||
|
||||
if (ms > 0) {
|
||||
ms += millis(); // wait until this time for a click
|
||||
while (PENDING(millis(), ms) && wait_for_user) idle();
|
||||
|
Reference in New Issue
Block a user