Browse Source

Toss obsolete DEBUG_LEVELING_FEATURE tests

pull/1/head
Scott Lahteine 5 years ago
parent
commit
42b5ccafc9
  1. 6
      Marlin/src/module/motion.cpp
  2. 77
      Marlin/src/module/tool_change.cpp

6
Marlin/src/module/motion.cpp

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

77
Marlin/src/module/tool_change.cpp

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

Loading…
Cancel
Save