瀏覽代碼

Fix the Z un-hop on G11

Co-Authored-By: zarthcode <anthony.clay@zarthcode.com>
Scott Lahteine 6 年之前
父節點
當前提交
21d812d502
共有 1 個檔案被更改,包括 2 行新增1 行删除
  1. 2
    1
      Marlin/src/feature/fwretract.cpp

+ 2
- 1
Marlin/src/feature/fwretract.cpp 查看文件

@@ -154,7 +154,8 @@ void FWRetract::retract(const bool retracting
154 154
   else {
155 155
     // If a hop was done and Z hasn't changed, undo the Z hop
156 156
     if (hop_amount) {
157
-      destination[Z_AXIS] -= hop_amount;                  // Move back down by the total hop amount
157
+      current_position[Z_AXIS] += hop_amount;             // Restore the actual Z position
158
+      SYNC_PLAN_POSITION_KINEMATIC();                     // Unspoof the position planner
158 159
       feedrate_mm_s = planner.max_feedrate_mm_s[Z_AXIS];  // Z feedrate to max
159 160
       prepare_move_to_destination();                      // Lower Z, set_current_to_destination
160 161
       hop_amount = 0.0;                                   // Clear the hop amount

Loading…
取消
儲存