Procházet zdrojové kódy

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 před 9 roky
rodič
revize
97a69d9b1c
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2
    2
      Marlin/Marlin_main.cpp

+ 2
- 2
Marlin/Marlin_main.cpp Zobrazit soubor

@@ -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…
Zrušit
Uložit