Browse Source

Add delta_height variable in lieu of using home_offset

Thomas Moore 6 years ago
parent
commit
658e1ebe5a
5 changed files with 84 additions and 92 deletions
  1. 1
    1
      Marlin/Conditionals_post.h
  2. 2
    1
      Marlin/Marlin.h
  3. 24
    18
      Marlin/Marlin_main.cpp
  4. 56
    67
      Marlin/configuration_store.cpp
  5. 1
    5
      Marlin/ultralcd.cpp

+ 1
- 1
Marlin/Conditionals_post.h View File

@@ -1030,7 +1030,7 @@
1030 1030
   // Updated G92 behavior shifts the workspace
1031 1031
   #define HAS_POSITION_SHIFT DISABLED(NO_WORKSPACE_OFFSETS)
1032 1032
   // The home offset also shifts the coordinate space
1033
-  #define HAS_HOME_OFFSET (DISABLED(NO_WORKSPACE_OFFSETS) || ENABLED(DELTA))
1033
+  #define HAS_HOME_OFFSET (DISABLED(NO_WORKSPACE_OFFSETS) && DISABLED(DELTA))
1034 1034
   // Either offset yields extra calculations on all moves
1035 1035
   #define HAS_WORKSPACE_OFFSET (HAS_POSITION_SHIFT || HAS_HOME_OFFSET)
1036 1036
   // M206 doesn't apply to DELTA

+ 2
- 1
Marlin/Marlin.h View File

@@ -304,7 +304,8 @@ void report_current_position();
304 304
 #endif
305 305
 
306 306
 #if ENABLED(DELTA)
307
-  extern float delta_endstop_adj[ABC],
307
+  extern float delta_height,
308
+               delta_endstop_adj[ABC],
308 309
                delta_radius,
309 310
                delta_diagonal_rod,
310 311
                delta_calibration_radius,

+ 24
- 18
Marlin/Marlin_main.cpp View File

@@ -627,7 +627,8 @@ static uint8_t target_extruder;
627 627
   float delta[ABC];
628 628
 
629 629
   // Initialized by settings.load()
630
-  float delta_endstop_adj[ABC] = { 0 },
630
+  float delta_height,
631
+        delta_endstop_adj[ABC] = { 0 },
631 632
         delta_radius,
632 633
         delta_tower_angle_trim[ABC],
633 634
         delta_tower[ABC][2],
@@ -1443,6 +1444,12 @@ bool get_target_extruder_from_command(const uint16_t code) {
1443 1444
           soft_endstop_max[axis] = base_max_pos(axis) + offs;
1444 1445
         }
1445 1446
       }
1447
+    #elif ENABLED(DELTA)
1448
+      soft_endstop_min[axis] = base_min_pos(axis) + offs;
1449
+      soft_endstop_max[axis] = (axis == Z_AXIS ? delta_height : base_max_pos(axis)) + offs;
1450
+    #else
1451
+      soft_endstop_min[axis] = base_min_pos(axis) + offs;
1452
+      soft_endstop_max[axis] = base_max_pos(axis) + offs;
1446 1453
     #endif
1447 1454
 
1448 1455
     #if ENABLED(DEBUG_LEVELING_FEATURE)
@@ -1568,6 +1575,10 @@ static void set_axis_is_at_home(const AxisEnum axis) {
1568 1575
       soft_endstop_max[axis] = base_max_pos(axis); // + (cartes[axis] - base_home_pos(axis));
1569 1576
     }
1570 1577
     else
1578
+  #elif ENABLED(DELTA)
1579
+    if (axis == Z_AXIS)
1580
+      current_position[axis] = delta_height;
1581
+    else
1571 1582
   #endif
1572 1583
   {
1573 1584
     current_position[axis] = base_home_pos(axis);
@@ -2378,11 +2389,7 @@ static void clean_up_after_endstop_or_probe_move() {
2378 2389
       }
2379 2390
     #endif
2380 2391
 
2381
-    return current_position[Z_AXIS] + zprobe_zoffset
2382
-      #if ENABLED(DELTA)
2383
-        + home_offset[Z_AXIS] // Account for delta height adjustment
2384
-      #endif
2385
-    ;
2392
+    return current_position[Z_AXIS] + zprobe_zoffset;
2386 2393
   }
2387 2394
 
2388 2395
   /**
@@ -3931,14 +3938,13 @@ inline void gcode_G4() {
3931 3938
     sync_plan_position();
3932 3939
 
3933 3940
     // Move all carriages together linearly until an endstop is hit.
3934
-    current_position[X_AXIS] = current_position[Y_AXIS] = current_position[Z_AXIS] = (DELTA_HEIGHT + home_offset[Z_AXIS] + 10);
3941
+    current_position[X_AXIS] = current_position[Y_AXIS] = current_position[Z_AXIS] = (delta_height + 10);
3935 3942
     feedrate_mm_s = homing_feedrate(X_AXIS);
3936 3943
     line_to_current_position();
3937 3944
     stepper.synchronize();
3938 3945
 
3939 3946
     // If an endstop was not hit, then damage can occur if homing is continued.
3940
-    // This can occur if the delta height (DELTA_HEIGHT + home_offset[Z_AXIS]) is
3941
-    // not set correctly.
3947
+    // This can occur if the delta height not set correctly.
3942 3948
     if (!(Endstops::endstop_hit_bits & (_BV(X_MAX) | _BV(Y_MAX) | _BV(Z_MAX)))) {
3943 3949
       LCD_MESSAGEPGM(MSG_ERR_HOMING_FAILED);
3944 3950
       SERIAL_ERROR_START();
@@ -5483,7 +5489,7 @@ void home_all_axes() { gcode_G28(true); }
5483 5489
   }
5484 5490
 
5485 5491
   static void print_G33_settings(const bool end_stops, const bool tower_angles) {
5486
-    SERIAL_PROTOCOLPAIR(".Height:", DELTA_HEIGHT + home_offset[Z_AXIS]);
5492
+    SERIAL_PROTOCOLPAIR(".Height:", delta_height);
5487 5493
     if (end_stops) {
5488 5494
       print_signed_float(PSTR("Ex"), delta_endstop_adj[A_AXIS]);
5489 5495
       print_signed_float(PSTR("Ey"), delta_endstop_adj[B_AXIS]);
@@ -5731,7 +5737,7 @@ void home_all_axes() { gcode_G28(true); }
5731 5737
         delta_endstop_adj[(axis + 1) % 3] -= 1.0 / 4.5;
5732 5738
         delta_endstop_adj[(axis + 2) % 3] += 1.0 / 4.5;
5733 5739
         z_temp = MAX3(delta_endstop_adj[A_AXIS], delta_endstop_adj[B_AXIS], delta_endstop_adj[C_AXIS]);
5734
-        home_offset[Z_AXIS] -= z_temp;
5740
+        delta_height -= z_temp;
5735 5741
         LOOP_XYZ(axis) delta_endstop_adj[axis] -= z_temp;
5736 5742
         recalc_delta_settings(delta_radius, delta_diagonal_rod, delta_tower_angle_trim);
5737 5743
 
@@ -5751,7 +5757,7 @@ void home_all_axes() { gcode_G28(true); }
5751 5757
         delta_endstop_adj[(axis+1) % 3] += 1.0/4.5;
5752 5758
         delta_endstop_adj[(axis+2) % 3] -= 1.0/4.5;
5753 5759
         z_temp = MAX3(delta_endstop_adj[A_AXIS], delta_endstop_adj[B_AXIS], delta_endstop_adj[C_AXIS]);
5754
-        home_offset[Z_AXIS] -= z_temp;
5760
+        delta_height -= z_temp;
5755 5761
         LOOP_XYZ(axis) delta_endstop_adj[axis] -= z_temp;
5756 5762
         recalc_delta_settings(delta_radius, delta_diagonal_rod, delta_tower_angle_trim);
5757 5763
         switch (axis) {
@@ -5860,7 +5866,7 @@ void home_all_axes() { gcode_G28(true); }
5860 5866
             delta_endstop_adj[C_AXIS]
5861 5867
           },
5862 5868
           dr_old = delta_radius,
5863
-          zh_old = home_offset[Z_AXIS],
5869
+          zh_old = delta_height,
5864 5870
           ta_old[ABC] = {
5865 5871
             delta_tower_angle_trim[A_AXIS],
5866 5872
             delta_tower_angle_trim[B_AXIS],
@@ -5939,7 +5945,7 @@ void home_all_axes() { gcode_G28(true); }
5939 5945
         if (zero_std_dev < zero_std_dev_min) {
5940 5946
           COPY(e_old, delta_endstop_adj);
5941 5947
           dr_old = delta_radius;
5942
-          zh_old = home_offset[Z_AXIS];
5948
+          zh_old = delta_height;
5943 5949
           COPY(ta_old, delta_tower_angle_trim);
5944 5950
         }
5945 5951
 
@@ -6023,7 +6029,7 @@ void home_all_axes() { gcode_G28(true); }
6023 6029
       else if (zero_std_dev >= test_precision) {   // step one back
6024 6030
         COPY(delta_endstop_adj, e_old);
6025 6031
         delta_radius = dr_old;
6026
-        home_offset[Z_AXIS] = zh_old;
6032
+        delta_height = zh_old;
6027 6033
         COPY(delta_tower_angle_trim, ta_old);
6028 6034
       }
6029 6035
 
@@ -6037,7 +6043,7 @@ void home_all_axes() { gcode_G28(true); }
6037 6043
 
6038 6044
         // adjust delta_height and endstops by the max amount
6039 6045
         const float z_temp = MAX3(delta_endstop_adj[A_AXIS], delta_endstop_adj[B_AXIS], delta_endstop_adj[C_AXIS]);
6040
-        home_offset[Z_AXIS] -= z_temp;
6046
+        delta_height -= z_temp;
6041 6047
         LOOP_XYZ(axis) delta_endstop_adj[axis] -= z_temp;
6042 6048
       }
6043 6049
       recalc_delta_settings(delta_radius, delta_diagonal_rod, delta_tower_angle_trim);
@@ -8993,7 +8999,7 @@ inline void gcode_M205() {
8993 8999
    */
8994 9000
   inline void gcode_M665() {
8995 9001
     if (parser.seen('H')) {
8996
-      home_offset[Z_AXIS] = parser.value_linear_units() - DELTA_HEIGHT;
9002
+      delta_height = parser.value_linear_units();
8997 9003
       update_software_endstops(Z_AXIS);
8998 9004
     }
8999 9005
     if (parser.seen('L')) delta_diagonal_rod             = parser.value_linear_units();
@@ -10101,7 +10107,7 @@ inline void gcode_M502() {
10101 10107
       #endif
10102 10108
 
10103 10109
       #if ENABLED(DELTA) // correct the delta_height
10104
-        home_offset[Z_AXIS] -= diff;
10110
+        delta_height -= diff;
10105 10111
       #endif
10106 10112
     }
10107 10113
 

+ 56
- 67
Marlin/configuration_store.cpp View File

@@ -36,7 +36,7 @@
36 36
  *
37 37
  */
38 38
 
39
-#define EEPROM_VERSION "V44"
39
+#define EEPROM_VERSION "V45"
40 40
 
41 41
 // Change EEPROM version if these are changed:
42 42
 #define EEPROM_OFFSET 100
@@ -91,15 +91,16 @@
91 91
  *  324  G29 A     planner.leveling_active          (bool)
92 92
  *  325  G29 S     ubl.storage_slot                 (int8_t)
93 93
  *
94
- * DELTA:                                           40 bytes
95
- *  352  M666 XYZ  delta_endstop_adj                (float x3)
96
- *  364  M665 R    delta_radius                     (float)
97
- *  368  M665 L    delta_diagonal_rod               (float)
98
- *  372  M665 S    delta_segments_per_second        (float)
99
- *  376  M665 B    delta_calibration_radius         (float)
100
- *  380  M665 X    delta_tower_angle_trim[A]        (float)
101
- *  384  M665 Y    delta_tower_angle_trim[B]        (float)
102
- *  388  M665 Z    delta_tower_angle_trim[C]        (float)
94
+ * DELTA:                                           44 bytes
95
+ *  352  M666 H    delta_height                     (float)
96
+ *  364  M666 XYZ  delta_endstop_adj                (float x3)
97
+ *  368  M665 R    delta_radius                     (float)
98
+ *  372  M665 L    delta_diagonal_rod               (float)
99
+ *  376  M665 S    delta_segments_per_second        (float)
100
+ *  380  M665 B    delta_calibration_radius         (float)
101
+ *  384  M665 X    delta_tower_angle_trim[A]        (float)
102
+ *  388  M665 Y    delta_tower_angle_trim[B]        (float)
103
+ *  392  M665 Z    delta_tower_angle_trim[C]        (float)
103 104
  *
104 105
  * [XYZ]_DUAL_ENDSTOPS:                             12 bytes
105 106
  *  352  M666 X    x_endstop_adj                    (float)
@@ -107,65 +108,65 @@
107 108
  *  360  M666 Z    z_endstop_adj                    (float)
108 109
  *
109 110
  * ULTIPANEL:                                       6 bytes
110
- *  392  M145 S0 H lcd_preheat_hotend_temp          (int x2)
111
- *  396  M145 S0 B lcd_preheat_bed_temp             (int x2)
112
- *  400  M145 S0 F lcd_preheat_fan_speed            (int x2)
111
+ *  396  M145 S0 H lcd_preheat_hotend_temp          (int x2)
112
+ *  400  M145 S0 B lcd_preheat_bed_temp             (int x2)
113
+ *  404  M145 S0 F lcd_preheat_fan_speed            (int x2)
113 114
  *
114 115
  * PIDTEMP:                                         82 bytes
115
- *  404  M301 E0 PIDC  Kp[0], Ki[0], Kd[0], Kc[0]   (float x4)
116
- *  420  M301 E1 PIDC  Kp[1], Ki[1], Kd[1], Kc[1]   (float x4)
117
- *  436  M301 E2 PIDC  Kp[2], Ki[2], Kd[2], Kc[2]   (float x4)
118
- *  452  M301 E3 PIDC  Kp[3], Ki[3], Kd[3], Kc[3]   (float x4)
119
- *  468  M301 E4 PIDC  Kp[3], Ki[3], Kd[3], Kc[3]   (float x4)
120
- *  484  M301 L        lpq_len                      (int)
116
+ *  408  M301 E0 PIDC  Kp[0], Ki[0], Kd[0], Kc[0]   (float x4)
117
+ *  428  M301 E1 PIDC  Kp[1], Ki[1], Kd[1], Kc[1]   (float x4)
118
+ *  440  M301 E2 PIDC  Kp[2], Ki[2], Kd[2], Kc[2]   (float x4)
119
+ *  456  M301 E3 PIDC  Kp[3], Ki[3], Kd[3], Kc[3]   (float x4)
120
+ *  472  M301 E4 PIDC  Kp[3], Ki[3], Kd[3], Kc[3]   (float x4)
121
+ *  488  M301 L        lpq_len                      (int)
121 122
  *
122 123
  * PIDTEMPBED:                                      12 bytes
123
- *  486  M304 PID  thermalManager.bedKp, .bedKi, .bedKd (float x3)
124
+ *  490  M304 PID  thermalManager.bedKp, .bedKi, .bedKd (float x3)
124 125
  *
125 126
  * DOGLCD:                                          2 bytes
126
- *  498  M250 C    lcd_contrast                     (uint16_t)
127
+ *  502  M250 C    lcd_contrast                     (uint16_t)
127 128
  *
128 129
  * FWRETRACT:                                       33 bytes
129
- *  500  M209 S    autoretract_enabled              (bool)
130
- *  501  M207 S    retract_length                   (float)
131
- *  505  M207 F    retract_feedrate_mm_s            (float)
132
- *  509  M207 Z    retract_zlift                    (float)
133
- *  513  M208 S    retract_recover_length           (float)
134
- *  517  M208 F    retract_recover_feedrate_mm_s    (float)
135
- *  521  M207 W    swap_retract_length              (float)
136
- *  525  M208 W    swap_retract_recover_length      (float)
137
- *  529  M208 R    swap_retract_recover_feedrate_mm_s (float)
130
+ *  504  M209 S    autoretract_enabled              (bool)
131
+ *  505  M207 S    retract_length                   (float)
132
+ *  509  M207 F    retract_feedrate_mm_s            (float)
133
+ *  513  M207 Z    retract_zlift                    (float)
134
+ *  517  M208 S    retract_recover_length           (float)
135
+ *  521  M208 F    retract_recover_feedrate_mm_s    (float)
136
+ *  525  M207 W    swap_retract_length              (float)
137
+ *  529  M208 W    swap_retract_recover_length      (float)
138
+ *  533  M208 R    swap_retract_recover_feedrate_mm_s (float)
138 139
  *
139 140
  * Volumetric Extrusion:                            21 bytes
140
- *  533  M200 D    volumetric_enabled               (bool)
141
- *  534  M200 T D  filament_size                    (float x5) (T0..3)
141
+ *  537  M200 D    volumetric_enabled               (bool)
142
+ *  538  M200 T D  filament_size                    (float x5) (T0..3)
142 143
  *
143 144
  * HAVE_TMC2130:                                    22 bytes
144
- *  554  M906 X    Stepper X current                (uint16_t)
145
- *  556  M906 Y    Stepper Y current                (uint16_t)
146
- *  558  M906 Z    Stepper Z current                (uint16_t)
147
- *  560  M906 X2   Stepper X2 current               (uint16_t)
148
- *  562  M906 Y2   Stepper Y2 current               (uint16_t)
149
- *  564  M906 Z2   Stepper Z2 current               (uint16_t)
150
- *  566  M906 E0   Stepper E0 current               (uint16_t)
151
- *  568  M906 E1   Stepper E1 current               (uint16_t)
152
- *  570  M906 E2   Stepper E2 current               (uint16_t)
153
- *  572  M906 E3   Stepper E3 current               (uint16_t)
154
- *  574  M906 E4   Stepper E4 current               (uint16_t)
145
+ *  558  M906 X    Stepper X current                (uint16_t)
146
+ *  560  M906 Y    Stepper Y current                (uint16_t)
147
+ *  562  M906 Z    Stepper Z current                (uint16_t)
148
+ *  564  M906 X2   Stepper X2 current               (uint16_t)
149
+ *  566  M906 Y2   Stepper Y2 current               (uint16_t)
150
+ *  568  M906 Z2   Stepper Z2 current               (uint16_t)
151
+ *  570  M906 E0   Stepper E0 current               (uint16_t)
152
+ *  572  M906 E1   Stepper E1 current               (uint16_t)
153
+ *  574  M906 E2   Stepper E2 current               (uint16_t)
154
+ *  576  M906 E3   Stepper E3 current               (uint16_t)
155
+ *  578  M906 E4   Stepper E4 current               (uint16_t)
155 156
  *
156 157
  * LIN_ADVANCE:                                     8 bytes
157
- *  576  M900 K    extruder_advance_k               (float)
158
- *  580  M900 WHD  advance_ed_ratio                 (float)
158
+ *  580  M900 K    extruder_advance_k               (float)
159
+ *  584  M900 WHD  advance_ed_ratio                 (float)
159 160
  *
160 161
  * HAS_MOTOR_CURRENT_PWM:
161
- *  584  M907 X    Stepper XY current               (uint32_t)
162
- *  588  M907 Z    Stepper Z current                (uint32_t)
163
- *  592  M907 E    Stepper E current                (uint32_t)
162
+ *  588  M907 X    Stepper XY current               (uint32_t)
163
+ *  592  M907 Z    Stepper Z current                (uint32_t)
164
+ *  596  M907 E    Stepper E current                (uint32_t)
164 165
  *
165 166
  * CNC_COORDINATE_SYSTEMS                           108 bytes
166
- *  596  G54-G59.3 coordinate_system                (float x 27)
167
+ *  600  G54-G59.3 coordinate_system                (float x 27)
167 168
  *
168
- *  704                                Minimum end-point
169
+ *  708                                Minimum end-point
169 170
  * 2025 (704 + 36 + 9 + 288 + 988)     Maximum end-point
170 171
  *
171 172
  * ========================================================================
@@ -354,15 +355,7 @@ void MarlinSettings::postprocess() {
354 355
     #if !HAS_HOME_OFFSET
355 356
       const float home_offset[XYZ] = { 0 };
356 357
     #endif
357
-    #if ENABLED(DELTA)
358
-      dummy = 0.0;
359
-      EEPROM_WRITE(dummy);
360
-      EEPROM_WRITE(dummy);
361
-      dummy = DELTA_HEIGHT + home_offset[Z_AXIS];
362
-      EEPROM_WRITE(dummy);
363
-    #else
364
-      EEPROM_WRITE(home_offset);
365
-    #endif
358
+    EEPROM_WRITE(home_offset);
366 359
 
367 360
     #if HOTENDS > 1
368 361
       // Skip hotend 0 which must be 0
@@ -465,6 +458,7 @@ void MarlinSettings::postprocess() {
465 458
 
466 459
     // 10 floats for DELTA / [XYZ]_DUAL_ENDSTOPS
467 460
     #if ENABLED(DELTA)
461
+      EEPROM_WRITE(delta_height);              // 1 float
468 462
       EEPROM_WRITE(delta_endstop_adj);         // 3 floats
469 463
       EEPROM_WRITE(delta_radius);              // 1 float
470 464
       EEPROM_WRITE(delta_diagonal_rod);        // 1 float
@@ -786,12 +780,6 @@ void MarlinSettings::postprocess() {
786 780
       #endif
787 781
       EEPROM_READ(home_offset);
788 782
 
789
-      #if ENABLED(DELTA)
790
-        home_offset[X_AXIS] = 0.0;
791
-        home_offset[Y_AXIS] = 0.0;
792
-        home_offset[Z_AXIS] -= DELTA_HEIGHT;
793
-      #endif
794
-
795 783
       //
796 784
       // Hotend Offsets, if any
797 785
       //
@@ -897,6 +885,7 @@ void MarlinSettings::postprocess() {
897 885
       //
898 886
 
899 887
       #if ENABLED(DELTA)
888
+        EEPROM_READ(delta_height);              // 1 float
900 889
         EEPROM_READ(delta_endstop_adj);         // 3 floats
901 890
         EEPROM_READ(delta_radius);              // 1 float
902 891
         EEPROM_READ(delta_diagonal_rod);        // 1 float
@@ -1347,13 +1336,13 @@ void MarlinSettings::reset() {
1347 1336
   #if ENABLED(DELTA)
1348 1337
     const float adj[ABC] = DELTA_ENDSTOP_ADJ,
1349 1338
                 dta[ABC] = DELTA_TOWER_ANGLE_TRIM;
1339
+    delta_height = DELTA_HEIGHT;
1350 1340
     COPY(delta_endstop_adj, adj);
1351 1341
     delta_radius = DELTA_RADIUS;
1352 1342
     delta_diagonal_rod = DELTA_DIAGONAL_ROD;
1353 1343
     delta_segments_per_second = DELTA_SEGMENTS_PER_SECOND;
1354 1344
     delta_calibration_radius = DELTA_CALIBRATION_RADIUS;
1355 1345
     COPY(delta_tower_angle_trim, dta);
1356
-    home_offset[Z_AXIS] = 0;
1357 1346
 
1358 1347
   #elif ENABLED(X_DUAL_ENDSTOPS) || ENABLED(Y_DUAL_ENDSTOPS) || ENABLED(Z_DUAL_ENDSTOPS)
1359 1348
 
@@ -1790,7 +1779,7 @@ void MarlinSettings::reset() {
1790 1779
       CONFIG_ECHO_START;
1791 1780
       SERIAL_ECHOPAIR("  M665 L", LINEAR_UNIT(delta_diagonal_rod));
1792 1781
       SERIAL_ECHOPAIR(" R", LINEAR_UNIT(delta_radius));
1793
-      SERIAL_ECHOPAIR(" H", LINEAR_UNIT(DELTA_HEIGHT + home_offset[Z_AXIS]));
1782
+      SERIAL_ECHOPAIR(" H", LINEAR_UNIT(delta_height));
1794 1783
       SERIAL_ECHOPAIR(" S", delta_segments_per_second);
1795 1784
       SERIAL_ECHOPAIR(" B", LINEAR_UNIT(delta_calibration_radius));
1796 1785
       SERIAL_ECHOPAIR(" X", LINEAR_UNIT(delta_tower_angle_trim[A_AXIS]));

+ 1
- 5
Marlin/ultralcd.cpp View File

@@ -2742,19 +2742,15 @@ void kill_screen(const char* lcd_msg) {
2742 2742
     void _goto_tower_z() { _man_probe_pt(cos(RADIANS( 90)) * delta_calibration_radius, sin(RADIANS( 90)) * delta_calibration_radius); }
2743 2743
     void _goto_center()  { _man_probe_pt(0,0); }
2744 2744
 
2745
-    static float _delta_height = DELTA_HEIGHT;
2746 2745
     void _lcd_set_delta_height() {
2747
-      home_offset[Z_AXIS] = _delta_height - DELTA_HEIGHT;
2748 2746
       update_software_endstops(Z_AXIS);
2749 2747
     }
2750 2748
 
2751 2749
     void lcd_delta_settings() {
2752 2750
       START_MENU();
2753 2751
       MENU_BACK(MSG_DELTA_CALIBRATE);
2754
-      float Tz = 0.00;
2755 2752
       MENU_ITEM_EDIT(float52, MSG_DELTA_DIAG_ROG, &delta_diagonal_rod, DELTA_DIAGONAL_ROD - 5.0, DELTA_DIAGONAL_ROD + 5.0);
2756
-      _delta_height = DELTA_HEIGHT + home_offset[Z_AXIS];
2757
-      MENU_MULTIPLIER_ITEM_EDIT_CALLBACK(float52, MSG_DELTA_HEIGHT, &_delta_height, _delta_height - 10.0, _delta_height + 10.0, _lcd_set_delta_height);
2753
+      MENU_MULTIPLIER_ITEM_EDIT_CALLBACK(float52, MSG_DELTA_HEIGHT, &delta_height, delta_height - 10.0, delta_height + 10.0, _lcd_set_delta_height);
2758 2754
       MENU_ITEM_EDIT(float43, "Ex", &delta_endstop_adj[A_AXIS], -5.0, 5.0);
2759 2755
       MENU_ITEM_EDIT(float43, "Ey", &delta_endstop_adj[B_AXIS], -5.0, 5.0);
2760 2756
       MENU_ITEM_EDIT(float43, "Ez", &delta_endstop_adj[C_AXIS], -5.0, 5.0);

Loading…
Cancel
Save