Use 0 as the bed position (not Z_MIN_POS)

This commit is contained in:
Scott Lahteine 2018-04-17 20:32:56 -05:00
parent 428c54f2ad
commit df2f24617b
4 changed files with 7 additions and 7 deletions

View file

@ -473,7 +473,7 @@ void GcodeSuite::G29() {
enable_soft_endstops = soft_endstops_enabled; enable_soft_endstops = soft_endstops_enabled;
#endif #endif
// Move close to the bed before the first point // Move close to the bed before the first point
do_blocking_move_to_z(Z_MIN_POS); do_blocking_move_to_z(0);
} }
else { else {

View file

@ -105,7 +105,7 @@ void GcodeSuite::G29() {
enable_soft_endstops = soft_endstops_enabled; enable_soft_endstops = soft_endstops_enabled;
#endif #endif
// Move close to the bed before the first point // Move close to the bed before the first point
do_blocking_move_to_z(Z_MIN_POS); do_blocking_move_to_z(0);
} }
else { else {
// For G29 S2 after adjusting Z. // For G29 S2 after adjusting Z.
@ -127,7 +127,7 @@ void GcodeSuite::G29() {
} }
else { else {
// One last "return to the bed" (as originally coded) at completion // One last "return to the bed" (as originally coded) at completion
current_position[Z_AXIS] = Z_MIN_POS + MANUAL_PROBE_HEIGHT; current_position[Z_AXIS] = MANUAL_PROBE_HEIGHT;
line_to_current_position(); line_to_current_position();
stepper.synchronize(); stepper.synchronize();
@ -141,7 +141,7 @@ void GcodeSuite::G29() {
set_bed_leveling_enabled(true); set_bed_leveling_enabled(true);
#if ENABLED(MESH_G28_REST_ORIGIN) #if ENABLED(MESH_G28_REST_ORIGIN)
current_position[Z_AXIS] = Z_MIN_POS; current_position[Z_AXIS] = 0;
set_destination_from_current(); set_destination_from_current();
buffer_line_to_destination(homing_feedrate(Z_AXIS)); buffer_line_to_destination(homing_feedrate(Z_AXIS));
stepper.synchronize(); stepper.synchronize();

View file

@ -85,7 +85,7 @@ void GcodeSuite::M701() {
// Restore Z axis // Restore Z axis
if (park_point.z > 0) if (park_point.z > 0)
do_blocking_move_to_z(max(current_position[Z_AXIS] - park_point.z, Z_MIN_POS), NOZZLE_PARK_Z_FEEDRATE); do_blocking_move_to_z(max(current_position[Z_AXIS] - park_point.z, 0), NOZZLE_PARK_Z_FEEDRATE);
#if EXTRUDERS > 1 #if EXTRUDERS > 1
// Restore toolhead if it was changed // Restore toolhead if it was changed
@ -158,7 +158,7 @@ void GcodeSuite::M702() {
// Restore Z axis // Restore Z axis
if (park_point.z > 0) if (park_point.z > 0)
do_blocking_move_to_z(max(current_position[Z_AXIS] - park_point.z, Z_MIN_POS), NOZZLE_PARK_Z_FEEDRATE); do_blocking_move_to_z(max(current_position[Z_AXIS] - park_point.z, 0), NOZZLE_PARK_Z_FEEDRATE);
#if EXTRUDERS > 1 #if EXTRUDERS > 1
// Restore toolhead if it was changed // Restore toolhead if it was changed

View file

@ -1820,7 +1820,7 @@ void kill_screen(const char* lcd_msg) {
if (!lcd_wait_for_move) { if (!lcd_wait_for_move) {
#if MANUAL_PROBE_HEIGHT > 0 && DISABLED(MESH_BED_LEVELING) #if MANUAL_PROBE_HEIGHT > 0 && DISABLED(MESH_BED_LEVELING)
// Display "Done" screen and wait for moves to complete // Display "Done" screen and wait for moves to complete
line_to_z(Z_MIN_POS + MANUAL_PROBE_HEIGHT); line_to_z(MANUAL_PROBE_HEIGHT);
lcd_synchronize(PSTR(MSG_LEVEL_BED_DONE)); lcd_synchronize(PSTR(MSG_LEVEL_BED_DONE));
#endif #endif
lcd_goto_previous_menu_no_defer(); lcd_goto_previous_menu_no_defer();