Browse Source

fix for #8669 (#8679)

* fix for #8669

* Update G28.cpp
pull/1/head
revilor 7 years ago
committed by Scott Lahteine
parent
commit
9e3fbcf35c
  1. 24
      Marlin/src/gcode/calibrate/G28.cpp

24
Marlin/src/gcode/calibrate/G28.cpp

@ -205,23 +205,21 @@ void GcodeSuite::G28(const bool always_home_all) {
#endif #endif
} }
#else #endif
if (home_all || homeX || homeY) { if (home_all || homeX || homeY) {
// Raise Z before homing any other axes and z is not already high enough (never lower z) // Raise Z before homing any other axes and z is not already high enough (never lower z)
destination[Z_AXIS] = Z_HOMING_HEIGHT; destination[Z_AXIS] = Z_HOMING_HEIGHT;
if (destination[Z_AXIS] > current_position[Z_AXIS]) { if (destination[Z_AXIS] > current_position[Z_AXIS]) {
#if ENABLED(DEBUG_LEVELING_FEATURE) #if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) if (DEBUGGING(LEVELING))
SERIAL_ECHOLNPAIR("Raise Z (before homing) to ", destination[Z_AXIS]); SERIAL_ECHOLNPAIR("Raise Z (before homing) to ", destination[Z_AXIS]);
#endif #endif
do_blocking_move_to_z(destination[Z_AXIS]); do_blocking_move_to_z(destination[Z_AXIS]);
}
} }
}
#endif
#if ENABLED(QUICK_HOME) #if ENABLED(QUICK_HOME)

Loading…
Cancel
Save