소스 검색

Move Z up before, or down after XY, for "blocking move"

Scott Lahteine 9 년 전
부모
커밋
6803c8e37e
1개의 변경된 파일13개의 추가작업 그리고 6개의 파일을 삭제
  1. 13
    6
      Marlin/Marlin_main.cpp

+ 13
- 6
Marlin/Marlin_main.cpp 파일 보기

1666
 
1666
 
1667
     #else
1667
     #else
1668
 
1668
 
1669
-      feedrate = homing_feedrate[Z_AXIS];
1670
-
1671
-      current_position[Z_AXIS] = z;
1672
-      line_to_current_position();
1673
-      stepper.synchronize();
1669
+      // If Z needs to raise, do it before moving XY
1670
+      if (current_position[Z_AXIS] < z) {
1671
+        feedrate = homing_feedrate[Z_AXIS];
1672
+        current_position[Z_AXIS] = z;
1673
+        line_to_current_position();
1674
+      }
1674
 
1675
 
1675
       feedrate = XY_PROBE_FEEDRATE;
1676
       feedrate = XY_PROBE_FEEDRATE;
1676
-
1677
       current_position[X_AXIS] = x;
1677
       current_position[X_AXIS] = x;
1678
       current_position[Y_AXIS] = y;
1678
       current_position[Y_AXIS] = y;
1679
       line_to_current_position();
1679
       line_to_current_position();
1680
 
1680
 
1681
+      // If Z needs to lower, do it after moving XY
1682
+      if (current_position[Z_AXIS] > z) {
1683
+        feedrate = homing_feedrate[Z_AXIS];
1684
+        current_position[Z_AXIS] = z;
1685
+        line_to_current_position();
1686
+      }
1687
+
1681
     #endif
1688
     #endif
1682
 
1689
 
1683
     stepper.synchronize();
1690
     stepper.synchronize();

Loading…
취소
저장