Quellcode durchsuchen

Update Marlin_main.cpp

Changed level and leveling to compensation (except with "verbose_level" and "lcd_reset_alert_level").
John Davis vor 10 Jahren
Ursprung
Commit
4315c2547a
1 geänderte Dateien mit 57 neuen und 57 gelöschten Zeilen
  1. 57
    57
      Marlin/Marlin_main.cpp

+ 57
- 57
Marlin/Marlin_main.cpp Datei anzeigen

@@ -29,12 +29,12 @@
29 29
 
30 30
 #include "Marlin.h"
31 31
 
32
-#ifdef ENABLE_AUTO_BED_LEVELING
32
+#ifdef ENABLE_AUTO_BED_COMPENSATION
33 33
 #include "vector_3.h"
34
-  #ifdef AUTO_BED_LEVELING_GRID
34
+  #ifdef AUTO_BED_COMPENSATION_GRID
35 35
     #include "qr_solve.h"
36 36
   #endif
37
-#endif // ENABLE_AUTO_BED_LEVELING
37
+#endif // ENABLE_AUTO_BED_COMPENSATION
38 38
 
39 39
 #include "ultralcd.h"
40 40
 #include "planner.h"
@@ -520,7 +520,7 @@ void servo_init()
520 520
   }
521 521
   #endif
522 522
 
523
-  #if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
523
+  #if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
524 524
   delay(PROBE_SERVO_DEACTIVATION_DELAY);
525 525
   servos[servo_endstops[Z_AXIS]].detach();
526 526
   #endif
@@ -962,16 +962,16 @@ static void axis_is_at_home(int axis) {
962 962
 #endif
963 963
 }
964 964
 
965
-#ifdef ENABLE_AUTO_BED_LEVELING
966
-#ifdef AUTO_BED_LEVELING_GRID
967
-static void set_bed_level_equation_lsq(double *plane_equation_coefficients)
965
+#ifdef ENABLE_AUTO_BED_COMPENSATION
966
+#ifdef AUTO_BED_COMPENSATION_GRID
967
+static void set_bed_compensation_equation_lsq(double *plane_equation_coefficients)
968 968
 {
969 969
     vector_3 planeNormal = vector_3(-plane_equation_coefficients[0], -plane_equation_coefficients[1], 1);
970 970
     planeNormal.debug("planeNormal");
971
-    plan_bed_level_matrix = matrix_3x3::create_look_at(planeNormal);
972
-    //bedLevel.debug("bedLevel");
971
+    plan_bed_compensation_matrix = matrix_3x3::create_look_at(planeNormal);
972
+    //bedCompensation.debug("bedCompensation");
973 973
 
974
-    //plan_bed_level_matrix.debug("bed level before");
974
+    //plan_bed_compensation_matrix.debug("bed compensation before");
975 975
     //vector_3 uncorrected_position = plan_get_position_mm();
976 976
     //uncorrected_position.debug("position before");
977 977
 
@@ -987,11 +987,11 @@ static void set_bed_level_equation_lsq(double *plane_equation_coefficients)
987 987
     plan_set_position(current_position[X_AXIS], current_position[Y_AXIS], current_position[Z_AXIS], current_position[E_AXIS]);
988 988
 }
989 989
 
990
-#else // not AUTO_BED_LEVELING_GRID
990
+#else // not AUTO_BED_COMPENSATION_GRID
991 991
 
992
-static void set_bed_level_equation_3pts(float z_at_pt_1, float z_at_pt_2, float z_at_pt_3) {
992
+static void set_bed_compensation_equation_3pts(float z_at_pt_1, float z_at_pt_2, float z_at_pt_3) {
993 993
 
994
-    plan_bed_level_matrix.set_to_identity();
994
+    plan_bed_compensation_matrix.set_to_identity();
995 995
 
996 996
     vector_3 pt1 = vector_3(ABL_PROBE_PT_1_X, ABL_PROBE_PT_1_Y, z_at_pt_1);
997 997
     vector_3 pt2 = vector_3(ABL_PROBE_PT_2_X, ABL_PROBE_PT_2_Y, z_at_pt_2);
@@ -1002,7 +1002,7 @@ static void set_bed_level_equation_3pts(float z_at_pt_1, float z_at_pt_2, float
1002 1002
     vector_3 planeNormal = vector_3::cross(from_2_to_1, from_2_to_3).get_normal();
1003 1003
     planeNormal = vector_3(planeNormal.x, planeNormal.y, abs(planeNormal.z));
1004 1004
 
1005
-    plan_bed_level_matrix = matrix_3x3::create_look_at(planeNormal);
1005
+    plan_bed_compensation_matrix = matrix_3x3::create_look_at(planeNormal);
1006 1006
 
1007 1007
     vector_3 corrected_position = plan_get_position();
1008 1008
     current_position[X_AXIS] = corrected_position.x;
@@ -1016,10 +1016,10 @@ static void set_bed_level_equation_3pts(float z_at_pt_1, float z_at_pt_2, float
1016 1016
 
1017 1017
 }
1018 1018
 
1019
-#endif // AUTO_BED_LEVELING_GRID
1019
+#endif // AUTO_BED_COMPENSATION_GRID
1020 1020
 
1021 1021
 static void run_z_probe() {
1022
-    plan_bed_level_matrix.set_to_identity();
1022
+    plan_bed_compensation_matrix.set_to_identity();
1023 1023
     feedrate = homing_feedrate[Z_AXIS];
1024 1024
 
1025 1025
     // move down until you find the bed
@@ -1088,11 +1088,11 @@ static void engage_z_probe() {
1088 1088
     // Engage Z Servo endstop if enabled
1089 1089
     #ifdef SERVO_ENDSTOPS
1090 1090
     if (servo_endstops[Z_AXIS] > -1) {
1091
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1091
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1092 1092
         servos[servo_endstops[Z_AXIS]].attach(0);
1093 1093
 #endif
1094 1094
         servos[servo_endstops[Z_AXIS]].write(servo_endstop_angles[Z_AXIS * 2]);
1095
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1095
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1096 1096
         delay(PROBE_SERVO_DEACTIVATION_DELAY);
1097 1097
         servos[servo_endstops[Z_AXIS]].detach();
1098 1098
 #endif
@@ -1104,11 +1104,11 @@ static void retract_z_probe() {
1104 1104
     // Retract Z Servo endstop if enabled
1105 1105
     #ifdef SERVO_ENDSTOPS
1106 1106
     if (servo_endstops[Z_AXIS] > -1) {
1107
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1107
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1108 1108
         servos[servo_endstops[Z_AXIS]].attach(0);
1109 1109
 #endif
1110 1110
         servos[servo_endstops[Z_AXIS]].write(servo_endstop_angles[Z_AXIS * 2 + 1]);
1111
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1111
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1112 1112
         delay(PROBE_SERVO_DEACTIVATION_DELAY);
1113 1113
         servos[servo_endstops[Z_AXIS]].detach();
1114 1114
 #endif
@@ -1142,7 +1142,7 @@ static float probe_pt(float x, float y, float z_before) {
1142 1142
   return measured_z;
1143 1143
 }
1144 1144
 
1145
-#endif // #ifdef ENABLE_AUTO_BED_LEVELING
1145
+#endif // #ifdef ENABLE_AUTO_BED_COMPENSATION
1146 1146
 
1147 1147
 static void homeaxis(int axis) {
1148 1148
 #define HOMEAXIS_DO(LETTER) \
@@ -1165,7 +1165,7 @@ static void homeaxis(int axis) {
1165 1165
 #ifndef Z_PROBE_SLED
1166 1166
     // Engage Servo endstop if enabled
1167 1167
     #ifdef SERVO_ENDSTOPS
1168
-      #if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1168
+      #if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1169 1169
         if (axis==Z_AXIS) {
1170 1170
           engage_z_probe();
1171 1171
         }
@@ -1216,7 +1216,7 @@ static void homeaxis(int axis) {
1216 1216
         servos[servo_endstops[axis]].write(servo_endstop_angles[axis * 2 + 1]);
1217 1217
       }
1218 1218
     #endif
1219
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1219
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
1220 1220
   #ifndef Z_PROBE_SLED
1221 1221
     if (axis==Z_AXIS) retract_z_probe();
1222 1222
   #endif
@@ -1325,7 +1325,7 @@ void process_commands()
1325 1325
 {
1326 1326
   unsigned long codenum; //throw away variable
1327 1327
   char *starpos = NULL;
1328
-#ifdef ENABLE_AUTO_BED_LEVELING
1328
+#ifdef ENABLE_AUTO_BED_COMPENSATION
1329 1329
   float x_tmp, y_tmp, z_tmp, real_z;
1330 1330
 #endif
1331 1331
   if(code_seen('G'))
@@ -1399,9 +1399,9 @@ void process_commands()
1399 1399
       break;
1400 1400
       #endif //FWRETRACT
1401 1401
     case 28: //G28 Home all Axis one at a time
1402
-#ifdef ENABLE_AUTO_BED_LEVELING
1403
-      plan_bed_level_matrix.set_to_identity();  //Reset the plane ("erase" all leveling data)
1404
-#endif //ENABLE_AUTO_BED_LEVELING
1402
+#ifdef ENABLE_AUTO_BED_COMPENSATION
1403
+      plan_bed_compensation_matrix.set_to_identity();  //Reset the plane ("erase" all compensation data)
1404
+#endif //ENABLE_AUTO_BED_COMPENSATION
1405 1405
 
1406 1406
       saved_feedrate = feedrate;
1407 1407
       saved_feedmultiply = feedmultiply;
@@ -1605,7 +1605,7 @@ void process_commands()
1605 1605
           current_position[Z_AXIS]=code_value()+add_homing[Z_AXIS];
1606 1606
         }
1607 1607
       }
1608
-      #ifdef ENABLE_AUTO_BED_LEVELING
1608
+      #ifdef ENABLE_AUTO_BED_COMPENSATION
1609 1609
         if((home_all_axis) || (code_seen(axis_codes[Z_AXIS]))) {
1610 1610
           current_position[Z_AXIS] += zprobe_zoffset;  //Add Z_Probe offset (the distance is negative)
1611 1611
         }
@@ -1628,11 +1628,11 @@ void process_commands()
1628 1628
       endstops_hit_on_purpose();
1629 1629
       break;
1630 1630
 
1631
-#ifdef ENABLE_AUTO_BED_LEVELING
1631
+#ifdef ENABLE_AUTO_BED_COMPENSATION
1632 1632
     case 29: // G29 Detailed Z-Probe, probes the bed at 3 or more points.
1633 1633
         {
1634 1634
             #if Z_MIN_PIN == -1
1635
-            #error "You must have a Z_MIN endstop in order to enable Auto Bed Leveling feature!!! Z_MIN_PIN must point to a valid hardware pin."
1635
+            #error "You must have a Z_MIN endstop in order to enable Auto Bed Compensation feature!!! Z_MIN_PIN must point to a valid hardware pin."
1636 1636
             #endif
1637 1637
 
1638 1638
             // Prevent user from running a G29 without first homing in X and Y
@@ -1648,10 +1648,10 @@ void process_commands()
1648 1648
             dock_sled(false);
1649 1649
 #endif // Z_PROBE_SLED
1650 1650
             st_synchronize();
1651
-            // make sure the bed_level_rotation_matrix is identity or the planner will get it incorectly
1651
+            // make sure the bed_compensation_rotation_matrix is identity or the planner will get it incorectly
1652 1652
             //vector_3 corrected_position = plan_get_position_mm();
1653 1653
             //corrected_position.debug("position before G29");
1654
-            plan_bed_level_matrix.set_to_identity();
1654
+            plan_bed_compensation_matrix.set_to_identity();
1655 1655
             vector_3 uncorrected_position = plan_get_position();
1656 1656
             //uncorrected_position.debug("position durring G29");
1657 1657
             current_position[X_AXIS] = uncorrected_position.x;
@@ -1661,11 +1661,11 @@ void process_commands()
1661 1661
             setup_for_endstop_move();
1662 1662
 
1663 1663
             feedrate = homing_feedrate[Z_AXIS];
1664
-#ifdef AUTO_BED_LEVELING_GRID
1664
+#ifdef AUTO_BED_COMPENSATION_GRID
1665 1665
             // probe at the points of a lattice grid
1666 1666
 
1667
-            int xGridSpacing = (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION) / (AUTO_BED_LEVELING_GRID_POINTS-1);
1668
-            int yGridSpacing = (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION) / (AUTO_BED_LEVELING_GRID_POINTS-1);
1667
+            int xGridSpacing = (RIGHT_PROBE_BED_POSITION - LEFT_PROBE_BED_POSITION) / (AUTO_BED_COMPENSATION_GRID_POINTS-1);
1668
+            int yGridSpacing = (BACK_PROBE_BED_POSITION - FRONT_PROBE_BED_POSITION) / (AUTO_BED_COMPENSATION_GRID_POINTS-1);
1669 1669
 
1670 1670
 
1671 1671
             // solve the plane equation ax + by + d = z
@@ -1675,9 +1675,9 @@ void process_commands()
1675 1675
             // so Vx = -a Vy = -b Vz = 1 (we want the vector facing towards positive Z
1676 1676
 
1677 1677
             // "A" matrix of the linear system of equations
1678
-            double eqnAMatrix[AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS*3];
1678
+            double eqnAMatrix[AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS*3];
1679 1679
             // "B" vector of Z points
1680
-            double eqnBVector[AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS];
1680
+            double eqnBVector[AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS];
1681 1681
 
1682 1682
 
1683 1683
             int probePointCounter = 0;
@@ -1700,7 +1700,7 @@ void process_commands()
1700 1700
                 zig = true;
1701 1701
               }
1702 1702
 
1703
-              for (int xCount=0; xCount < AUTO_BED_LEVELING_GRID_POINTS; xCount++)
1703
+              for (int xCount=0; xCount < AUTO_BED_COMPENSATION_GRID_POINTS; xCount++)
1704 1704
               {
1705 1705
                 float z_before;
1706 1706
                 if (probePointCounter == 0)
@@ -1717,9 +1717,9 @@ void process_commands()
1717 1717
 
1718 1718
                 eqnBVector[probePointCounter] = measured_z;
1719 1719
 
1720
-                eqnAMatrix[probePointCounter + 0*AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS] = xProbe;
1721
-                eqnAMatrix[probePointCounter + 1*AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS] = yProbe;
1722
-                eqnAMatrix[probePointCounter + 2*AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS] = 1;
1720
+                eqnAMatrix[probePointCounter + 0*AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS] = xProbe;
1721
+                eqnAMatrix[probePointCounter + 1*AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS] = yProbe;
1722
+                eqnAMatrix[probePointCounter + 2*AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS] = 1;
1723 1723
                 probePointCounter++;
1724 1724
                 xProbe += xInc;
1725 1725
               }
@@ -1727,7 +1727,7 @@ void process_commands()
1727 1727
             clean_up_after_endstop_move();
1728 1728
 
1729 1729
             // solve lsq problem
1730
-            double *plane_equation_coefficients = qr_solve(AUTO_BED_LEVELING_GRID_POINTS*AUTO_BED_LEVELING_GRID_POINTS, 3, eqnAMatrix, eqnBVector);
1730
+            double *plane_equation_coefficients = qr_solve(AUTO_BED_COMPENSATION_GRID_POINTS*AUTO_BED_COMPENSATION_GRID_POINTS, 3, eqnAMatrix, eqnBVector);
1731 1731
 
1732 1732
             SERIAL_PROTOCOLPGM("Eqn coefficients: a: ");
1733 1733
             SERIAL_PROTOCOL(plane_equation_coefficients[0]);
@@ -1737,11 +1737,11 @@ void process_commands()
1737 1737
             SERIAL_PROTOCOLLN(plane_equation_coefficients[2]);
1738 1738
 
1739 1739
 
1740
-            set_bed_level_equation_lsq(plane_equation_coefficients);
1740
+            set_bed_compensation_equation_lsq(plane_equation_coefficients);
1741 1741
 
1742 1742
             free(plane_equation_coefficients);
1743 1743
 
1744
-#else // AUTO_BED_LEVELING_GRID not defined
1744
+#else // AUTO_BED_COMPENSATION_GRID not defined
1745 1745
 
1746 1746
             // Probe at 3 arbitrary points
1747 1747
             // probe 1
@@ -1755,21 +1755,21 @@ void process_commands()
1755 1755
 
1756 1756
             clean_up_after_endstop_move();
1757 1757
 
1758
-            set_bed_level_equation_3pts(z_at_pt_1, z_at_pt_2, z_at_pt_3);
1758
+            set_bed_compensation_equation_3pts(z_at_pt_1, z_at_pt_2, z_at_pt_3);
1759 1759
 
1760 1760
 
1761
-#endif // AUTO_BED_LEVELING_GRID
1761
+#endif // AUTO_BED_COMPENSATION_GRID
1762 1762
             st_synchronize();
1763 1763
 
1764 1764
             // The following code correct the Z height difference from z-probe position and hotend tip position.
1765 1765
             // The Z height on homing is measured by Z-Probe, but the probe is quite far from the hotend.
1766 1766
             // When the bed is uneven, this height must be corrected.
1767
-            real_z = float(st_get_position(Z_AXIS))/axis_steps_per_unit[Z_AXIS];  //get the real Z (since the auto bed leveling is already correcting the plane)
1767
+            real_z = float(st_get_position(Z_AXIS))/axis_steps_per_unit[Z_AXIS];  //get the real Z (since the auto bed compensation is already correcting the plane)
1768 1768
             x_tmp = current_position[X_AXIS] + X_PROBE_OFFSET_FROM_EXTRUDER;
1769 1769
             y_tmp = current_position[Y_AXIS] + Y_PROBE_OFFSET_FROM_EXTRUDER;
1770 1770
             z_tmp = current_position[Z_AXIS];
1771 1771
 
1772
-            apply_rotation_xyz(plan_bed_level_matrix, x_tmp, y_tmp, z_tmp);         //Apply the correction sending the probe offset
1772
+            apply_rotation_xyz(plan_bed_compensation_matrix, x_tmp, y_tmp, z_tmp);         //Apply the correction sending the probe offset
1773 1773
             current_position[Z_AXIS] = z_tmp - real_z + current_position[Z_AXIS];   //The difference is added to current position and sent to planner.
1774 1774
             plan_set_position(current_position[X_AXIS], current_position[Y_AXIS], current_position[Z_AXIS], current_position[E_AXIS]);
1775 1775
 #ifdef Z_PROBE_SLED
@@ -1782,7 +1782,7 @@ void process_commands()
1782 1782
         {
1783 1783
             engage_z_probe(); // Engage Z Servo endstop if available
1784 1784
             st_synchronize();
1785
-            // TODO: make sure the bed_level_rotation_matrix is identity or the planner will get set incorectly
1785
+            // TODO: make sure the bed_compensation_rotation_matrix is identity or the planner will get set incorectly
1786 1786
             setup_for_endstop_move();
1787 1787
 
1788 1788
             feedrate = homing_feedrate[Z_AXIS];
@@ -1809,7 +1809,7 @@ void process_commands()
1809 1809
         dock_sled(false);
1810 1810
         break;
1811 1811
 #endif // Z_PROBE_SLED
1812
-#endif // ENABLE_AUTO_BED_LEVELING
1812
+#endif // ENABLE_AUTO_BED_COMPENSATION
1813 1813
     case 90: // G90
1814 1814
       relative_mode = false;
1815 1815
       break;
@@ -2068,7 +2068,7 @@ void process_commands()
2068 2068
 //	
2069 2069
 // This function assumes the bed has been homed.  Specificaly, that a G28 command
2070 2070
 // as been issued prior to invoking the M48 Z-Probe repeatability measurement function.
2071
-// Any information generated by a prior G29 Bed leveling command will be lost and need to be
2071
+// Any information generated by a prior G29 Bed compensation command will be lost and need to be
2072 2072
 // regenerated.
2073 2073
 //
2074 2074
 // The number of samples will default to 10 if not specified.  You can use upper or lower case
@@ -2076,7 +2076,7 @@ void process_commands()
2076 2076
 // N for its communication protocol and will get horribly confused if you send it a capital N.
2077 2077
 //
2078 2078
 
2079
-#ifdef ENABLE_AUTO_BED_LEVELING
2079
+#ifdef ENABLE_AUTO_BED_COMPENSATION
2080 2080
 #ifdef Z_PROBE_REPEATABILITY_TEST 
2081 2081
 
2082 2082
     case 48: // M48 Z-Probe repeatability
@@ -2154,7 +2154,7 @@ void process_commands()
2154 2154
 //
2155 2155
 
2156 2156
         st_synchronize();
2157
-        plan_bed_level_matrix.set_to_identity();
2157
+        plan_bed_compensation_matrix.set_to_identity();
2158 2158
 	plan_buffer_line( X_current, Y_current, Z_start_location,
2159 2159
 			ext_position,
2160 2160
     			homing_feedrate[Z_AXIS]/60,
@@ -2333,7 +2333,7 @@ Sigma_Exit:
2333 2333
         break;
2334 2334
 	}
2335 2335
 #endif		// Z_PROBE_REPEATABILITY_TEST 
2336
-#endif		// ENABLE_AUTO_BED_LEVELING
2336
+#endif		// ENABLE_AUTO_BED_COMPENSATION
2337 2337
 
2338 2338
     case 104: // M104
2339 2339
       if(setTargetedHotend(104)){
@@ -3093,11 +3093,11 @@ Sigma_Exit:
3093 3093
         if (code_seen('S')) {
3094 3094
           servo_position = code_value();
3095 3095
           if ((servo_index >= 0) && (servo_index < NUM_SERVOS)) {
3096
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
3096
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
3097 3097
 		      servos[servo_index].attach(0);
3098 3098
 #endif
3099 3099
             servos[servo_index].write(servo_position);
3100
-#if defined (ENABLE_AUTO_BED_LEVELING) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
3100
+#if defined (ENABLE_AUTO_BED_COMPENSATION) && (PROBE_SERVO_DEACTIVATION_DELAY > 0)
3101 3101
               delay(PROBE_SERVO_DEACTIVATION_DELAY);
3102 3102
               servos[servo_index].detach();
3103 3103
 #endif
@@ -3362,7 +3362,7 @@ Sigma_Exit:
3362 3362
       st_synchronize();
3363 3363
     }
3364 3364
     break;
3365
-#if defined(ENABLE_AUTO_BED_LEVELING) && defined(SERVO_ENDSTOPS) && not defined(Z_PROBE_SLED)
3365
+#if defined(ENABLE_AUTO_BED_COMPENSATION) && defined(SERVO_ENDSTOPS) && not defined(Z_PROBE_SLED)
3366 3366
     case 401:
3367 3367
     {
3368 3368
         engage_z_probe();    // Engage Z Servo endstop if available

Laden…
Abbrechen
Speichern