Browse Source

[2.0.x] Fix dual enstop home (#10980)

Giuliano 6 years ago
parent
commit
b64cc9329e
1 changed files with 3 additions and 3 deletions
  1. 3
    3
      Marlin/src/module/motion.cpp

+ 3
- 3
Marlin/src/module/motion.cpp View File

1335
       if (axis == X_AXIS) {
1335
       if (axis == X_AXIS) {
1336
         const float adj = ABS(endstops.x_endstop_adj);
1336
         const float adj = ABS(endstops.x_endstop_adj);
1337
         if (pos_dir ? (endstops.x_endstop_adj > 0) : (endstops.x_endstop_adj < 0)) stepper.set_x_lock(true); else stepper.set_x2_lock(true);
1337
         if (pos_dir ? (endstops.x_endstop_adj > 0) : (endstops.x_endstop_adj < 0)) stepper.set_x_lock(true); else stepper.set_x2_lock(true);
1338
-        do_homing_move(axis, pos_dir ? adj : -adj);
1338
+        do_homing_move(axis, pos_dir ? -adj : adj);
1339
         stepper.set_x_lock(false);
1339
         stepper.set_x_lock(false);
1340
         stepper.set_x2_lock(false);
1340
         stepper.set_x2_lock(false);
1341
       }
1341
       }
1344
       if (axis == Y_AXIS) {
1344
       if (axis == Y_AXIS) {
1345
         const float adj = ABS(endstops.y_endstop_adj);
1345
         const float adj = ABS(endstops.y_endstop_adj);
1346
         if (pos_dir ? (endstops.y_endstop_adj > 0) : (endstops.y_endstop_adj < 0)) stepper.set_y_lock(true); else stepper.set_y2_lock(true);
1346
         if (pos_dir ? (endstops.y_endstop_adj > 0) : (endstops.y_endstop_adj < 0)) stepper.set_y_lock(true); else stepper.set_y2_lock(true);
1347
-        do_homing_move(axis, pos_dir ? adj : -adj);
1347
+        do_homing_move(axis, pos_dir ? -adj : adj);
1348
         stepper.set_y_lock(false);
1348
         stepper.set_y_lock(false);
1349
         stepper.set_y2_lock(false);
1349
         stepper.set_y2_lock(false);
1350
       }
1350
       }
1353
       if (axis == Z_AXIS) {
1353
       if (axis == Z_AXIS) {
1354
         const float adj = ABS(endstops.z_endstop_adj);
1354
         const float adj = ABS(endstops.z_endstop_adj);
1355
         if (pos_dir ? (endstops.z_endstop_adj > 0) : (endstops.z_endstop_adj < 0)) stepper.set_z_lock(true); else stepper.set_z2_lock(true);
1355
         if (pos_dir ? (endstops.z_endstop_adj > 0) : (endstops.z_endstop_adj < 0)) stepper.set_z_lock(true); else stepper.set_z2_lock(true);
1356
-        do_homing_move(axis, pos_dir ? adj : -adj);
1356
+        do_homing_move(axis, pos_dir ? -adj : adj);
1357
         stepper.set_z_lock(false);
1357
         stepper.set_z_lock(false);
1358
         stepper.set_z2_lock(false);
1358
         stepper.set_z2_lock(false);
1359
       }
1359
       }

Loading…
Cancel
Save