Skip to content

Commit

Permalink
Trust XY after Quiet Probing short sleep (#21237)
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Mar 2, 2021
1 parent 5ee1087 commit 2f97505
Showing 1 changed file with 24 additions and 12 deletions.
36 changes: 24 additions & 12 deletions Marlin/src/module/probe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,20 +238,32 @@ xyz_pos_t Probe::offset; // Initialized by settings.load()

#if QUIET_PROBING

void Probe::set_probing_paused(const bool p) {
TERN_(PROBING_HEATERS_OFF, thermalManager.pause(p));
TERN_(PROBING_FANS_OFF, thermalManager.set_fans_paused(p));
#ifndef DELAY_BEFORE_PROBING
#define DELAY_BEFORE_PROBING 25
#endif

void Probe::set_probing_paused(const bool dopause) {
TERN_(PROBING_HEATERS_OFF, thermalManager.pause(dopause));
TERN_(PROBING_FANS_OFF, thermalManager.set_fans_paused(dopause));
#if ENABLED(PROBING_STEPPERS_OFF)
disable_e_steppers();
#if NONE(DELTA, HOME_AFTER_DEACTIVATE)
DISABLE_AXIS_X(); DISABLE_AXIS_Y();
#endif
IF_DISABLED(DELTA, static uint8_t old_known);
if (dopause) {
#if DISABLED(DELTA)
old_known = axis_known_position;
DISABLE_AXIS_X();
DISABLE_AXIS_Y();
#endif
disable_e_steppers();
}
else {
#if DISABLED(DELTA)
if (TEST(old_known, X_AXIS)) ENABLE_AXIS_X();
if (TEST(old_known, Y_AXIS)) ENABLE_AXIS_Y();
#endif
axis_known_position = old_trusted;
}
#endif
if (p) safe_delay(25
#if DELAY_BEFORE_PROBING > 25
- 25 + DELAY_BEFORE_PROBING
#endif
);
if (dopause) safe_delay(_MAX(DELAY_BEFORE_PROBING, 25));
}

#endif // QUIET_PROBING
Expand Down

0 comments on commit 2f97505

Please sign in to comment.