Toss obsolete DEBUG_LEVELING_FEATURE tests

This commit is contained in:
Scott Lahteine 2019-07-17 20:24:25 -05:00
parent ca4d6f4470
commit 42b5ccafc9
2 changed files with 31 additions and 52 deletions

View File

@ -538,10 +538,8 @@ void clean_up_after_endstop_or_probe_move() {
#endif #endif
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) if (DEBUGGING(LEVELING))
SERIAL_ECHOLNPAIR("Axis ", axis_codes[axis], " min:", soft_endstop[axis].min, " max:", soft_endstop[axis].max); SERIAL_ECHOLNPAIR("Axis ", axis_codes[axis], " min:", soft_endstop[axis].min, " max:", soft_endstop[axis].max);
#endif
} }
/** /**

View File

@ -605,61 +605,49 @@ inline void fast_line_to_current(const AxisEnum fr_axis) {
* 9. Apply Z hotend offset to current position * 9. Apply Z hotend offset to current position
*/ */
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) DEBUG_POS("Starting Autopark", current_position); if (DEBUGGING(LEVELING)) DEBUG_POS("Starting Autopark", current_position);
#endif
// 1. Raise Z-Axis to give enough clearance // 1. Raise Z-Axis to give enough clearance
current_position[Z_AXIS] += SWITCHING_TOOLHEAD_Z_HOP; current_position[Z_AXIS] += SWITCHING_TOOLHEAD_Z_HOP;
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) DEBUG_POS("(1) Raise Z-Axis ", current_position); if (DEBUGGING(LEVELING)) DEBUG_POS("(1) Raise Z-Axis ", current_position);
#endif
planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Z_AXIS], active_extruder); planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Z_AXIS], active_extruder);
// 2. Move to position near active extruder parking // 2. Move to position near active extruder parking
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
planner.synchronize(); planner.synchronize();
SERIAL_ECHOLNPAIR("(2) Move near active extruder parking", active_extruder); SERIAL_ECHOLNPAIR("(2) Move near active extruder parking", active_extruder);
DEBUG_POS("Moving ParkPos", current_position); DEBUG_POS("Moving ParkPos", current_position);
} }
#endif
current_position[X_AXIS] = placexpos + hotend_offset[X_AXIS][active_extruder]; current_position[X_AXIS] = placexpos + hotend_offset[X_AXIS][active_extruder];
current_position[Y_AXIS] = SWITCHING_TOOLHEAD_Y_POS + SWITCHING_TOOLHEAD_Y_CLEAR + hotend_offset[Y_AXIS][active_extruder]; current_position[Y_AXIS] = SWITCHING_TOOLHEAD_Y_POS + SWITCHING_TOOLHEAD_Y_CLEAR + hotend_offset[Y_AXIS][active_extruder];
planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[X_AXIS], active_extruder); planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[X_AXIS], active_extruder);
// 3. Move gently to park position of active extruder // 3. Move gently to park position of active extruder
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
planner.synchronize(); planner.synchronize();
SERIAL_ECHOLNPAIR("(3) Move gently to park position of active extruder", active_extruder); SERIAL_ECHOLNPAIR("(3) Move gently to park position of active extruder", active_extruder);
DEBUG_POS("Moving ParkPos", current_position); DEBUG_POS("Moving ParkPos", current_position);
} }
#endif
current_position[Y_AXIS] -= SWITCHING_TOOLHEAD_Y_CLEAR; current_position[Y_AXIS] -= SWITCHING_TOOLHEAD_Y_CLEAR;
planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5, active_extruder); planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5, active_extruder);
// 4. Disengage magnetic field, wait for delay // 4. Disengage magnetic field, wait for delay
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(4) Disengage magnet"); if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(4) Disengage magnet");
#endif
planner.synchronize(); planner.synchronize();
est_deactivate_solenoid(); est_deactivate_solenoid();
// 5. Leave extruder and move to position near new extruder parking // 5. Leave extruder and move to position near new extruder parking
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
SERIAL_ECHOLNPGM("(5) Move near new extruder parking"); SERIAL_ECHOLNPGM("(5) Move near new extruder parking");
DEBUG_POS("Moving ParkPos", current_position); DEBUG_POS("Moving ParkPos", current_position);
} }
#endif
current_position[Y_AXIS] += SWITCHING_TOOLHEAD_Y_CLEAR; current_position[Y_AXIS] += SWITCHING_TOOLHEAD_Y_CLEAR;
planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5f, active_extruder); planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5f, active_extruder);
@ -670,30 +658,25 @@ inline void fast_line_to_current(const AxisEnum fr_axis) {
// 6. Move gently to park position of new extruder // 6. Move gently to park position of new extruder
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
planner.synchronize(); planner.synchronize();
SERIAL_ECHOLNPGM("(6) Move near new extruder"); SERIAL_ECHOLNPGM("(6) Move near new extruder");
} }
#endif
current_position[Y_AXIS] -= SWITCHING_TOOLHEAD_Y_CLEAR; current_position[Y_AXIS] -= SWITCHING_TOOLHEAD_Y_CLEAR;
planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5f, active_extruder); planner.buffer_line(current_position, planner.settings.max_feedrate_mm_s[Y_AXIS] * 0.5f, active_extruder);
// 7. Engage magnetic field for new extruder parking // 7. Engage magnetic field for new extruder parking
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(7) Engage magnetic field");
#endif
planner.synchronize(); planner.synchronize();
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(7) Engage magnetic field");
est_activate_solenoid(); est_activate_solenoid();
// 8. Unpark extruder // 8. Unpark extruder
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(8) Unpark extruder"); if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("(8) Unpark extruder");
#endif
current_position[Y_AXIS] += SWITCHING_TOOLHEAD_Y_CLEAR; current_position[Y_AXIS] += SWITCHING_TOOLHEAD_Y_CLEAR;
@ -703,12 +686,10 @@ inline void fast_line_to_current(const AxisEnum fr_axis) {
current_position[Z_AXIS] += hotend_offset[Z_AXIS][active_extruder] - hotend_offset[Z_AXIS][tmp_extruder]; current_position[Z_AXIS] += hotend_offset[Z_AXIS][active_extruder] - hotend_offset[Z_AXIS][tmp_extruder];
#if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
planner.synchronize(); planner.synchronize();
DEBUG_POS("(9) Applying Z-offset", current_position); DEBUG_POS("(9) Applying Z-offset", current_position);
} }
#endif
} }
#endif // ELECTROMAGNETIC_SWITCHING_TOOLHEAD #endif // ELECTROMAGNETIC_SWITCHING_TOOLHEAD