소스 검색

Merge pull request #1987 from thinkyhead/fix_homing_zpos

Disable endstops between homing bumps
Scott Lahteine 10 년 전
부모
커밋
c1dd9bda7f
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6
    0
      Marlin/Marlin_main.cpp

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

1546
     current_position[axis] = 0;
1546
     current_position[axis] = 0;
1547
     sync_plan_position();
1547
     sync_plan_position();
1548
 
1548
 
1549
+    enable_endstops(false); // Disable endstops while moving away
1550
+
1549
     // Move away from the endstop by the axis HOME_BUMP_MM
1551
     // Move away from the endstop by the axis HOME_BUMP_MM
1550
     destination[axis] = -home_bump_mm(axis) * axis_home_dir;
1552
     destination[axis] = -home_bump_mm(axis) * axis_home_dir;
1551
     line_to_destination();
1553
     line_to_destination();
1552
     st_synchronize();
1554
     st_synchronize();
1553
 
1555
 
1556
+    enable_endstops(true); // Enable endstops for next homing move
1557
+
1554
     // Slow down the feedrate for the next move
1558
     // Slow down the feedrate for the next move
1555
     set_homing_bump_feedrate(axis);
1559
     set_homing_bump_feedrate(axis);
1556
 
1560
 
1587
     #ifdef DELTA
1591
     #ifdef DELTA
1588
       // retrace by the amount specified in endstop_adj
1592
       // retrace by the amount specified in endstop_adj
1589
       if (endstop_adj[axis] * axis_home_dir < 0) {
1593
       if (endstop_adj[axis] * axis_home_dir < 0) {
1594
+        enable_endstops(false); // Disable endstops while moving away
1590
         sync_plan_position();
1595
         sync_plan_position();
1591
         destination[axis] = endstop_adj[axis];
1596
         destination[axis] = endstop_adj[axis];
1592
         line_to_destination();
1597
         line_to_destination();
1593
         st_synchronize();
1598
         st_synchronize();
1599
+        enable_endstops(true); // Enable endstops for next homing move
1594
       }
1600
       }
1595
     #endif
1601
     #endif
1596
 
1602
 

Loading…
취소
저장