Safe homing: Raise Z on G28 Z (#17501)
Co-Authored-By: RFBomb <robbery525@gmail.com>
This commit is contained in:
parent
a2e9a02429
commit
ac7b484703
@ -329,7 +329,7 @@ void GcodeSuite::G28() {
|
|||||||
? (parser.seenval('R') ? parser.value_linear_units() : Z_HOMING_HEIGHT)
|
? (parser.seenval('R') ? parser.value_linear_units() : Z_HOMING_HEIGHT)
|
||||||
: 0;
|
: 0;
|
||||||
|
|
||||||
if (z_homing_height && (doX || doY)) {
|
if (z_homing_height && (doX || doY || ENABLED(Z_SAFE_HOMING))) {
|
||||||
// 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 = z_homing_height + (TEST(axis_known_position, Z_AXIS) ? 0.0f : current_position.z);
|
destination.z = z_homing_height + (TEST(axis_known_position, Z_AXIS) ? 0.0f : current_position.z);
|
||||||
if (destination.z > current_position.z) {
|
if (destination.z > current_position.z) {
|
||||||
|
Loading…
Reference in New Issue
Block a user