瀏覽代碼

Correct XYZ after obtaining plan_bed_level_matrix

The current position needs to be updated by using the inverse
`plan_bed_level_matrix` on X, Y, and Z. All moves in the planner are
transformed by the `plan_bed_level_matrix` from this point forward.
Scott Lahteine 9 年之前
父節點
當前提交
97a69d9b1c
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2
    2
      Marlin/Marlin_main.cpp

+ 2
- 2
Marlin/Marlin_main.cpp 查看文件

@@ -1055,7 +1055,7 @@ inline void sync_plan_position() {
1055 1055
         //corrected_position.debug("position after");
1056 1056
         current_position[X_AXIS] = corrected_position.x;
1057 1057
         current_position[Y_AXIS] = corrected_position.y;
1058
-        current_position[Z_AXIS] = zprobe_zoffset; // was: corrected_position.z
1058
+        current_position[Z_AXIS] = corrected_position.z;
1059 1059
 
1060 1060
         sync_plan_position();
1061 1061
       }
@@ -1084,7 +1084,7 @@ inline void sync_plan_position() {
1084 1084
       vector_3 corrected_position = plan_get_position();
1085 1085
       current_position[X_AXIS] = corrected_position.x;
1086 1086
       current_position[Y_AXIS] = corrected_position.y;
1087
-      current_position[Z_AXIS] = zprobe_zoffset; // was: corrected_position.z
1087
+      current_position[Z_AXIS] = corrected_position.z;
1088 1088
 
1089 1089
       sync_plan_position();
1090 1090
     }

Loading…
取消
儲存