Browse Source

UBL_DELTA => UBL_SEGMENTED

Scott Lahteine 6 years ago
parent
commit
a71d2f3f40

+ 3
- 2
.travis.yml View File

@@ -79,13 +79,14 @@ script:
79 79
   - opt_set TEMP_SENSOR_3 20
80 80
   - opt_set TEMP_SENSOR_4 999
81 81
   - opt_set TEMP_SENSOR_BED 1
82
-  - opt_enable AUTO_BED_LEVELING_UBL DEBUG_LEVELING_FEATURE G26_MESH_EDITING ENABLE_LEVELING_FADE_HEIGHT EEPROM_SETTINGS EEPROM_CHITCHAT G3D_PANEL
82
+  - opt_enable AUTO_BED_LEVELING_UBL DEBUG_LEVELING_FEATURE G26_MESH_EDITING ENABLE_LEVELING_FADE_HEIGHT EEPROM_SETTINGS EEPROM_CHITCHAT G3D_PANEL SKEW_CORRECTION
83 83
   - opt_enable_adv CUSTOM_USER_MENUS I2C_POSITION_ENCODERS BABYSTEPPING LIN_ADVANCE NANODLP_Z_SYNC
84 84
   - build_marlin_pio ${TRAVIS_BUILD_DIR} ${TEST_PLATFORM}
85 85
   #
86
-  # And with a Sled Z Probe
86
+  # Add a Sled Z Probe, do non-segmented moves
87 87
   #
88 88
   - opt_enable Z_PROBE_SLED
89
+  - opt_disable SEGMENT_LEVELED_MOVES
89 90
   - opt_enable_adv BABYSTEP_ZPROBE_OFFSET DOUBLECLICK_FOR_Z_BABYSTEPPING
90 91
   - build_marlin_pio ${TRAVIS_BUILD_DIR} ${TEST_PLATFORM}
91 92
   #

+ 2
- 10
Marlin/src/feature/bedlevel/ubl/ubl_motion.cpp View File

@@ -458,15 +458,7 @@
458 458
     set_current_from_destination();
459 459
   }
460 460
 
461
-  #if UBL_DELTA
462
-
463
-    // macro to inline copy exactly 4 floats, don't rely on sizeof operator
464
-    #define COPY_XYZE( target, source ) { \
465
-                target[X_AXIS] = source[X_AXIS]; \
466
-                target[Y_AXIS] = source[Y_AXIS]; \
467
-                target[Z_AXIS] = source[Z_AXIS]; \
468
-                target[E_AXIS] = source[E_AXIS]; \
469
-            }
461
+  #if UBL_SEGMENTED
470 462
 
471 463
     #if IS_SCARA // scale the feed rate from mm/s to degrees/s
472 464
       static float scara_feed_factor, scara_oldA, scara_oldB;
@@ -675,6 +667,6 @@
675 667
       } // cell loop
676 668
     }
677 669
 
678
-  #endif // UBL_DELTA
670
+  #endif // UBL_SEGMENTED
679 671
 
680 672
 #endif // AUTO_BED_LEVELING_UBL

+ 1
- 1
Marlin/src/gcode/bedlevel/G26.cpp View File

@@ -220,7 +220,7 @@ mesh_index_pair find_closest_circle_to_print(const float &X, const float &Y) {
220 220
 void G26_line_to_destination(const float &feed_rate) {
221 221
   const float save_feedrate = feedrate_mm_s;
222 222
   feedrate_mm_s = feed_rate;      // use specified feed rate
223
-  prepare_move_to_destination();  // will ultimately call ubl.line_to_destination_cartesian or ubl.prepare_linear_move_to for UBL_DELTA
223
+  prepare_move_to_destination();  // will ultimately call ubl.line_to_destination_cartesian or ubl.prepare_linear_move_to for UBL_SEGMENTED
224 224
   feedrate_mm_s = save_feedrate;  // restore global feed rate
225 225
 }
226 226
 

+ 9
- 9
Marlin/src/inc/Conditionals_post.h View File

@@ -977,15 +977,15 @@
977 977
 /**
978 978
  * Set granular options based on the specific type of leveling
979 979
  */
980
-#define UBL_DELTA  (ENABLED(AUTO_BED_LEVELING_UBL) && (ENABLED(DELTA) || ENABLED(SEGMENT_LEVELED_MOVES)))
981
-#define ABL_PLANAR (ENABLED(AUTO_BED_LEVELING_LINEAR) || ENABLED(AUTO_BED_LEVELING_3POINT))
982
-#define ABL_GRID   (ENABLED(AUTO_BED_LEVELING_LINEAR) || ENABLED(AUTO_BED_LEVELING_BILINEAR))
983
-#define OLDSCHOOL_ABL         (ABL_PLANAR || ABL_GRID)
984
-#define HAS_ABL               (OLDSCHOOL_ABL || ENABLED(AUTO_BED_LEVELING_UBL))
985
-#define HAS_LEVELING          (HAS_ABL || ENABLED(MESH_BED_LEVELING))
986
-#define HAS_AUTOLEVEL         (HAS_ABL && DISABLED(PROBE_MANUALLY))
987
-#define HAS_MESH              (ENABLED(AUTO_BED_LEVELING_BILINEAR) || ENABLED(AUTO_BED_LEVELING_UBL) || ENABLED(MESH_BED_LEVELING))
988
-#define PLANNER_LEVELING      (OLDSCHOOL_ABL || ENABLED(MESH_BED_LEVELING) || UBL_DELTA)
980
+#define UBL_SEGMENTED  (ENABLED(AUTO_BED_LEVELING_UBL) && (ENABLED(DELTA) || ENABLED(SEGMENT_LEVELED_MOVES)))
981
+#define ABL_PLANAR     (ENABLED(AUTO_BED_LEVELING_LINEAR) || ENABLED(AUTO_BED_LEVELING_3POINT))
982
+#define ABL_GRID       (ENABLED(AUTO_BED_LEVELING_LINEAR) || ENABLED(AUTO_BED_LEVELING_BILINEAR))
983
+#define OLDSCHOOL_ABL  (ABL_PLANAR || ABL_GRID)
984
+#define HAS_ABL        (OLDSCHOOL_ABL || ENABLED(AUTO_BED_LEVELING_UBL))
985
+#define HAS_LEVELING   (HAS_ABL || ENABLED(MESH_BED_LEVELING))
986
+#define HAS_AUTOLEVEL  (HAS_ABL && DISABLED(PROBE_MANUALLY))
987
+#define HAS_MESH       (ENABLED(AUTO_BED_LEVELING_BILINEAR) || ENABLED(AUTO_BED_LEVELING_UBL) || ENABLED(MESH_BED_LEVELING))
988
+#define PLANNER_LEVELING      (OLDSCHOOL_ABL || ENABLED(MESH_BED_LEVELING))
989 989
 #define HAS_PROBING_PROCEDURE (HAS_ABL || ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST))
990 990
 #if HAS_PROBING_PROCEDURE
991 991
   #define PROBE_BED_WIDTH abs(RIGHT_PROBE_BED_POSITION - (LEFT_PROBE_BED_POSITION))

+ 1
- 4
Marlin/src/inc/SanityCheck.h View File

@@ -603,7 +603,7 @@ static_assert(1 >= 0
603 603
     #error "Delta probably shouldn't use Z_MIN_PROBE_ENDSTOP. Comment out this line to continue."
604 604
   #elif DISABLED(USE_XMAX_PLUG) && DISABLED(USE_YMAX_PLUG) && DISABLED(USE_ZMAX_PLUG)
605 605
     #error "You probably want to use Max Endstops for DELTA!"
606
-  #elif ENABLED(ENABLE_LEVELING_FADE_HEIGHT) && DISABLED(AUTO_BED_LEVELING_BILINEAR) && !UBL_DELTA
606
+  #elif ENABLED(ENABLE_LEVELING_FADE_HEIGHT) && DISABLED(AUTO_BED_LEVELING_BILINEAR) && !UBL_SEGMENTED
607 607
     #error "ENABLE_LEVELING_FADE_HEIGHT on DELTA requires AUTO_BED_LEVELING_BILINEAR or AUTO_BED_LEVELING_UBL."
608 608
   #elif ENABLED(DELTA_AUTO_CALIBRATION) && !(HAS_BED_PROBE || ENABLED(ULTIPANEL))
609 609
     #error "DELTA_AUTO_CALIBRATION requires a probe or LCD Controller."
@@ -1497,9 +1497,6 @@ static_assert(COUNT(sanity_arr_3) <= XYZE_N, "DEFAULT_MAX_ACCELERATION has too m
1497 1497
 #endif
1498 1498
 
1499 1499
 #if ENABLED(SKEW_CORRECTION)
1500
-  #if ENABLED(AUTO_BED_LEVELING_UBL) && !ENABLED(SEGMENT_LEVELED_MOVES)
1501
-    #error "SKEW_CORRECTION with AUTO_BED_LEVELING_UBL requires SEGMENT_LEVELED_MOVES."
1502
-  #endif
1503 1500
   #if !defined(XY_SKEW_FACTOR) && !(defined(XY_DIAG_AC) && defined(XY_DIAG_BD) && defined(XY_SIDE_AD))
1504 1501
     #error "SKEW_CORRECTION requires XY_SKEW_FACTOR or XY_DIAG_AC, XY_DIAG_BD, XY_SIDE_AD."
1505 1502
   #endif

+ 4
- 4
Marlin/src/module/motion.cpp View File

@@ -264,7 +264,7 @@ void buffer_line_to_destination(const float fr_mm_s) {
264 264
 
265 265
     gcode.refresh_cmd_timeout();
266 266
 
267
-    #if UBL_DELTA
267
+    #if UBL_SEGMENTED
268 268
       // ubl segmented line will do z-only moves in single segment
269 269
       ubl.prepare_segmented_line_to(destination, MMS_SCALED(fr_mm_s ? fr_mm_s : feedrate_mm_s));
270 270
     #else
@@ -495,7 +495,7 @@ float soft_endstop_min[XYZ] = { X_MIN_BED, Y_MIN_BED, Z_MIN_POS },
495 495
 
496 496
 #endif
497 497
 
498
-#if !UBL_DELTA
498
+#if !UBL_SEGMENTED
499 499
 #if IS_KINEMATIC
500 500
 
501 501
   #if ENABLED(AUTO_BED_LEVELING_BILINEAR)
@@ -762,7 +762,7 @@ float soft_endstop_min[XYZ] = { X_MIN_BED, Y_MIN_BED, Z_MIN_POS },
762 762
   }
763 763
 
764 764
 #endif // !IS_KINEMATIC
765
-#endif // !UBL_DELTA
765
+#endif // !UBL_SEGMENTED
766 766
 
767 767
 #if ENABLED(DUAL_X_CARRIAGE) || ENABLED(DUAL_NOZZLE_DUPLICATION_MODE)
768 768
   bool extruder_duplication_enabled = false;                              // Used in Dual X mode 2
@@ -907,7 +907,7 @@ void prepare_move_to_destination() {
907 907
   #endif // PREVENT_COLD_EXTRUSION || PREVENT_LENGTHY_EXTRUDE
908 908
 
909 909
   if (
910
-    #if UBL_DELTA // Also works for CARTESIAN (smaller segments follow mesh more closely)
910
+    #if UBL_SEGMENTED
911 911
       ubl.prepare_segmented_line_to(destination, MMS_SCALED(feedrate_mm_s))
912 912
     #elif IS_KINEMATIC
913 913
       prepare_kinematic_move_to(destination)

+ 1
- 1
Marlin/src/module/planner.cpp View File

@@ -616,7 +616,7 @@ void Planner::calculate_volumetric_multipliers() {
616 616
       #endif
617 617
 
618 618
       rz += (
619
-        #if ENABLED(AUTO_BED_LEVELING_UBL) // UBL_DELTA
619
+        #if ENABLED(AUTO_BED_LEVELING_UBL)
620 620
           ubl.get_z_correction(rx, ry) * fade_scaling_factor
621 621
         #elif ENABLED(MESH_BED_LEVELING)
622 622
           mbl.get_z(rx, ry

Loading…
Cancel
Save