Przeglądaj źródła

Include the position_shift when splitting mesh lines

Scott Lahteine 8 lat temu
rodzic
commit
799a31cd30
1 zmienionych plików z 4 dodań i 4 usunięć
  1. 4
    4
      Marlin/Marlin_main.cpp

+ 4
- 4
Marlin/Marlin_main.cpp Wyświetl plik

@@ -7863,7 +7863,7 @@ void mesh_buffer_line(float x, float y, float z, const float e, float fr_mm_s, c
7863 7863
   }
7864 7864
   float nx, ny, nz, ne, normalized_dist;
7865 7865
   if (cx > pcx && TEST(x_splits, cx)) {
7866
-    nx = mbl.get_probe_x(cx) + home_offset[X_AXIS];
7866
+    nx = mbl.get_probe_x(cx) + home_offset[X_AXIS] + position_shift[X_AXIS];
7867 7867
     normalized_dist = (nx - current_position[X_AXIS]) / (x - current_position[X_AXIS]);
7868 7868
     ny = current_position[Y_AXIS] + (y - current_position[Y_AXIS]) * normalized_dist;
7869 7869
     nz = current_position[Z_AXIS] + (z - current_position[Z_AXIS]) * normalized_dist;
@@ -7871,7 +7871,7 @@ void mesh_buffer_line(float x, float y, float z, const float e, float fr_mm_s, c
7871 7871
     CBI(x_splits, cx);
7872 7872
   }
7873 7873
   else if (cx < pcx && TEST(x_splits, pcx)) {
7874
-    nx = mbl.get_probe_x(pcx) + home_offset[X_AXIS];
7874
+    nx = mbl.get_probe_x(pcx) + home_offset[X_AXIS] + position_shift[X_AXIS];
7875 7875
     normalized_dist = (nx - current_position[X_AXIS]) / (x - current_position[X_AXIS]);
7876 7876
     ny = current_position[Y_AXIS] + (y - current_position[Y_AXIS]) * normalized_dist;
7877 7877
     nz = current_position[Z_AXIS] + (z - current_position[Z_AXIS]) * normalized_dist;
@@ -7879,7 +7879,7 @@ void mesh_buffer_line(float x, float y, float z, const float e, float fr_mm_s, c
7879 7879
     CBI(x_splits, pcx);
7880 7880
   }
7881 7881
   else if (cy > pcy && TEST(y_splits, cy)) {
7882
-    ny = mbl.get_probe_y(cy) + home_offset[Y_AXIS];
7882
+    ny = mbl.get_probe_y(cy) + home_offset[Y_AXIS] + position_shift[Y_AXIS];
7883 7883
     normalized_dist = (ny - current_position[Y_AXIS]) / (y - current_position[Y_AXIS]);
7884 7884
     nx = current_position[X_AXIS] + (x - current_position[X_AXIS]) * normalized_dist;
7885 7885
     nz = current_position[Z_AXIS] + (z - current_position[Z_AXIS]) * normalized_dist;
@@ -7887,7 +7887,7 @@ void mesh_buffer_line(float x, float y, float z, const float e, float fr_mm_s, c
7887 7887
     CBI(y_splits, cy);
7888 7888
   }
7889 7889
   else if (cy < pcy && TEST(y_splits, pcy)) {
7890
-    ny = mbl.get_probe_y(pcy) + home_offset[Y_AXIS];
7890
+    ny = mbl.get_probe_y(pcy) + home_offset[Y_AXIS] + position_shift[Y_AXIS];
7891 7891
     normalized_dist = (ny - current_position[Y_AXIS]) / (y - current_position[Y_AXIS]);
7892 7892
     nx = current_position[X_AXIS] + (x - current_position[X_AXIS]) * normalized_dist;
7893 7893
     nz = current_position[Z_AXIS] + (z - current_position[Z_AXIS]) * normalized_dist;

Ładowanie…
Anuluj
Zapisz