|
@@ -1167,6 +1167,12 @@ XYZ_CONSTS_FROM_CONFIG(signed char, home_dir, HOME_DIR);
|
1167
|
1167
|
#endif
|
1168
|
1168
|
|
1169
|
1169
|
static void set_axis_is_at_home(AxisEnum axis) {
|
|
1170
|
+ #if ENABLED(DEBUG_LEVELING_FEATURE)
|
|
1171
|
+ if (DEBUGGING(LEVELING)) {
|
|
1172
|
+ SERIAL_ECHOPAIR("set_axis_is_at_home(", (unsigned long)axis);
|
|
1173
|
+ SERIAL_ECHOLNPGM(") >>>");
|
|
1174
|
+ }
|
|
1175
|
+ #endif
|
1170
|
1176
|
|
1171
|
1177
|
#if ENABLED(DUAL_X_CARRIAGE)
|
1172
|
1178
|
if (axis == X_AXIS) {
|
|
@@ -1234,17 +1240,27 @@ static void set_axis_is_at_home(AxisEnum axis) {
|
1234
|
1240
|
max_pos[axis] = base_max_pos(axis) + home_offset[axis];
|
1235
|
1241
|
|
1236
|
1242
|
#if ENABLED(AUTO_BED_LEVELING_FEATURE) && Z_HOME_DIR < 0
|
1237
|
|
- if (axis == Z_AXIS) current_position[Z_AXIS] -= zprobe_zoffset;
|
|
1243
|
+ if (axis == Z_AXIS) {
|
|
1244
|
+ current_position[Z_AXIS] -= zprobe_zoffset;
|
|
1245
|
+ #if ENABLED(DEBUG_LEVELING_FEATURE)
|
|
1246
|
+ if (DEBUGGING(LEVELING)) SERIAL_ECHOPAIR("> zprobe_zoffset==", zprobe_zoffset);
|
|
1247
|
+ #endif
|
|
1248
|
+ }
|
1238
|
1249
|
#endif
|
1239
|
1250
|
|
1240
|
1251
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
1241
|
1252
|
if (DEBUGGING(LEVELING)) {
|
1242
|
|
- SERIAL_ECHOPAIR("set_axis_is_at_home ", (unsigned long)axis);
|
1243
|
|
- SERIAL_ECHOPAIR(" > (home_offset[axis]==", home_offset[axis]);
|
1244
|
|
- print_xyz(") > current_position", current_position);
|
|
1253
|
+ SERIAL_ECHOPAIR("> home_offset[axis]==", home_offset[axis]);
|
|
1254
|
+ print_xyz(" > current_position", current_position);
|
1245
|
1255
|
}
|
1246
|
1256
|
#endif
|
1247
|
1257
|
}
|
|
1258
|
+ #if ENABLED(DEBUG_LEVELING_FEATURE)
|
|
1259
|
+ if (DEBUGGING(LEVELING)) {
|
|
1260
|
+ SERIAL_ECHOPAIR("<<< set_axis_is_at_home(", (unsigned long)axis);
|
|
1261
|
+ SERIAL_ECHOLNPGM(")");
|
|
1262
|
+ }
|
|
1263
|
+ #endif
|
1248
|
1264
|
}
|
1249
|
1265
|
|
1250
|
1266
|
/**
|
|
@@ -2754,12 +2770,12 @@ inline void gcode_G28() {
|
2754
|
2770
|
#endif
|
2755
|
2771
|
|
2756
|
2772
|
#if ENABLED(ENDSTOPS_ONLY_FOR_HOMING)
|
|
2773
|
+ enable_endstops(false);
|
2757
|
2774
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
2758
|
2775
|
if (DEBUGGING(LEVELING)) {
|
2759
|
2776
|
SERIAL_ECHOLNPGM("ENDSTOPS_ONLY_FOR_HOMING enable_endstops(false)");
|
2760
|
2777
|
}
|
2761
|
2778
|
#endif
|
2762
|
|
- enable_endstops(false);
|
2763
|
2779
|
#endif
|
2764
|
2780
|
|
2765
|
2781
|
// For mesh leveling move back to Z=0
|
|
@@ -2999,6 +3015,7 @@ inline void gcode_G28() {
|
2999
|
3015
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
3000
|
3016
|
if (DEBUGGING(LEVELING)) {
|
3001
|
3017
|
SERIAL_ECHOLNPGM("gcode_G29 >>>");
|
|
3018
|
+ print_xyz("> current_position", current_position);
|
3002
|
3019
|
}
|
3003
|
3020
|
#endif
|
3004
|
3021
|
|