Skip to content

Commit 7717beb

Browse files
kadirilkimenthinkyhead
authored andcommitted
✨ Polar Kinematics (MarlinFirmware#25214)
1 parent 33e5aad commit 7717beb

32 files changed

+376
-76
lines changed

Marlin/Configuration.h

+59-6
Original file line numberDiff line numberDiff line change
@@ -915,7 +915,7 @@
915915
#endif
916916

917917
// Print surface diameter/2 minus unreachable space (avoid collisions with vertical towers).
918-
#define DELTA_PRINTABLE_RADIUS 140.0 // (mm)
918+
#define PRINTABLE_RADIUS 140.0 // (mm)
919919

920920
// Maximum reachable area
921921
#define DELTA_MAX_RADIUS 140.0 // (mm)
@@ -969,7 +969,7 @@
969969
#if ENABLED(MORGAN_SCARA)
970970

971971
//#define DEBUG_SCARA_KINEMATICS
972-
#define SCARA_FEEDRATE_SCALING // Convert XY feedrate from mm/s to degrees/s on the fly
972+
#define FEEDRATE_SCALING // Convert XY feedrate from mm/s to degrees/s on the fly
973973

974974
// Radius around the center where the arm cannot reach
975975
#define MIDDLE_DEAD_ZONE_R 0 // (mm)
@@ -1004,7 +1004,7 @@
10041004
#define TPARA_OFFSET_Y 0 // (mm)
10051005
#define TPARA_OFFSET_Z 0 // (mm)
10061006

1007-
#define SCARA_FEEDRATE_SCALING // Convert XY feedrate from mm/s to degrees/s on the fly
1007+
#define FEEDRATE_SCALING // Convert XY feedrate from mm/s to degrees/s on the fly
10081008

10091009
// Radius around the center where the arm cannot reach
10101010
#define MIDDLE_DEAD_ZONE_R 0 // (mm)
@@ -1014,6 +1014,59 @@
10141014
#define PSI_HOMING_OFFSET 0
10151015
#endif
10161016

1017+
// @section polar
1018+
1019+
/**
1020+
* POLAR Kinematics
1021+
* developed by Kadir ilkimen for PolarBear CNC and babyBear
1022+
* https://github.com/kadirilkimen/Polar-Bear-Cnc-Machine
1023+
* https://github.com/kadirilkimen/babyBear-3D-printer
1024+
*
1025+
* A polar machine can have different configurations.
1026+
* This kinematics is only compatible with the following configuration:
1027+
* X : Independent linear
1028+
* Y or B : Polar
1029+
* Z : Independent linear
1030+
*
1031+
* For example, PolarBear has CoreXZ plus Polar Y or B.
1032+
*
1033+
* Motion problem for Polar axis near center / origin:
1034+
*
1035+
* 3D printing:
1036+
* Movements very close to the center of the polar axis take more time than others.
1037+
* This brief delay results in more material deposition due to the pressure in the nozzle.
1038+
*
1039+
* Current Kinematics and feedrate scaling deals with this by making the movement as fast
1040+
* as possible. It works for slow movements but doesn't work well with fast ones. A more
1041+
* complicated extrusion compensation must be implemented.
1042+
*
1043+
* Ideally, it should estimate that a long rotation near the center is ahead and will cause
1044+
* unwanted deposition. Therefore it can compensate the extrusion beforehand.
1045+
*
1046+
* Laser cutting:
1047+
* Same thing would be a problem for laser engraving too. As it spends time rotating at the
1048+
* center point, more likely it will burn more material than it should. Therefore similar
1049+
* compensation would be implemented for laser-cutting operations.
1050+
*
1051+
* Milling:
1052+
* This shouldn't be a problem for cutting/milling operations.
1053+
*/
1054+
//#define POLAR
1055+
#if ENABLED(POLAR)
1056+
#define DEFAULT_SEGMENTS_PER_SECOND 180 // If movement is choppy try lowering this value
1057+
#define PRINTABLE_RADIUS 82.0f // (mm) Maximum travel of X axis
1058+
1059+
// Movements fall inside POLAR_FAST_RADIUS are assigned the highest possible feedrate
1060+
// to compensate unwanted deposition related to the near-origin motion problem.
1061+
#define POLAR_FAST_RADIUS 3.0f // (mm)
1062+
1063+
// Radius which is unreachable by the tool.
1064+
// Needed if the tool is not perfectly aligned to the center of the polar axis.
1065+
#define POLAR_CENTER_OFFSET 0.0f // (mm)
1066+
1067+
#define FEEDRATE_SCALING // Convert XY feedrate from mm/s to degrees/s on the fly
1068+
#endif
1069+
10171070
// @section machine
10181071

10191072
// Articulated robot (arm). Joints are directly mapped to axes with no kinematics.
@@ -1420,13 +1473,13 @@
14201473
// 2 or 3 sets of coordinates for deploying and retracting the spring loaded touch probe on G29,
14211474
// if servo actuated touch probe is not defined. Uncomment as appropriate for your printer/probe.
14221475

1423-
#define Z_PROBE_ALLEN_KEY_DEPLOY_1 { 30.0, DELTA_PRINTABLE_RADIUS, 100.0 }
1476+
#define Z_PROBE_ALLEN_KEY_DEPLOY_1 { 30.0, PRINTABLE_RADIUS, 100.0 }
14241477
#define Z_PROBE_ALLEN_KEY_DEPLOY_1_FEEDRATE XY_PROBE_FEEDRATE
14251478

1426-
#define Z_PROBE_ALLEN_KEY_DEPLOY_2 { 0.0, DELTA_PRINTABLE_RADIUS, 100.0 }
1479+
#define Z_PROBE_ALLEN_KEY_DEPLOY_2 { 0.0, PRINTABLE_RADIUS, 100.0 }
14271480
#define Z_PROBE_ALLEN_KEY_DEPLOY_2_FEEDRATE (XY_PROBE_FEEDRATE)/10
14281481

1429-
#define Z_PROBE_ALLEN_KEY_DEPLOY_3 { 0.0, (DELTA_PRINTABLE_RADIUS) * 0.75, 100.0 }
1482+
#define Z_PROBE_ALLEN_KEY_DEPLOY_3 { 0.0, (PRINTABLE_RADIUS) * 0.75, 100.0 }
14301483
#define Z_PROBE_ALLEN_KEY_DEPLOY_3_FEEDRATE XY_PROBE_FEEDRATE
14311484

14321485
#define Z_PROBE_ALLEN_KEY_STOW_1 { -64.0, 56.0, 23.0 } // Move the probe into position

Marlin/src/MarlinCore.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,8 @@
168168
#include "module/polargraph.h"
169169
#elif IS_SCARA
170170
#include "module/scara.h"
171+
#elif ENABLED(POLAR)
172+
#include "module/polar.h"
171173
#endif
172174

173175
#if HAS_LEVELING

Marlin/src/core/language.h

+1
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,7 @@
279279
#define STR_S_SEG_PER_SEC "S<seg-per-sec>"
280280
#define STR_DELTA_SETTINGS "Delta (L<diagonal-rod> R<radius> H<height> S<seg-per-sec> XYZ<tower-angle-trim> ABC<rod-trim>)"
281281
#define STR_SCARA_SETTINGS "SCARA"
282+
#define STR_POLAR_SETTINGS "Polar"
282283
#define STR_POLARGRAPH_SETTINGS "Polargraph"
283284
#define STR_SCARA_P_T_Z "P<theta-psi-offset> T<theta-offset> Z<home-offset>"
284285
#define STR_ENDSTOP_ADJUSTMENT "Endstop adjustment"

Marlin/src/feature/bedlevel/ubl/ubl_motion.cpp

+15-17
Original file line numberDiff line numberDiff line change
@@ -334,16 +334,14 @@
334334
#else // UBL_SEGMENTED
335335

336336
#if IS_SCARA
337-
#define DELTA_SEGMENT_MIN_LENGTH 0.25 // SCARA minimum segment size is 0.25mm
338-
#elif ENABLED(DELTA)
339-
#define DELTA_SEGMENT_MIN_LENGTH 0.10 // mm (still subject to DEFAULT_SEGMENTS_PER_SECOND)
340-
#elif ENABLED(POLARGRAPH)
341-
#define DELTA_SEGMENT_MIN_LENGTH 0.10 // mm (still subject to DEFAULT_SEGMENTS_PER_SECOND)
337+
#define SEGMENT_MIN_LENGTH 0.25 // SCARA minimum segment size is 0.25mm
338+
#elif IS_KINEMATIC
339+
#define SEGMENT_MIN_LENGTH 0.10 // (mm) Still subject to DEFAULT_SEGMENTS_PER_SECOND
342340
#else // CARTESIAN
343341
#ifdef LEVELED_SEGMENT_LENGTH
344-
#define DELTA_SEGMENT_MIN_LENGTH LEVELED_SEGMENT_LENGTH
342+
#define SEGMENT_MIN_LENGTH LEVELED_SEGMENT_LENGTH
345343
#else
346-
#define DELTA_SEGMENT_MIN_LENGTH 1.00 // mm (similar to G2/G3 arc segmentation)
344+
#define SEGMENT_MIN_LENGTH 1.00 // (mm) Similar to G2/G3 arc segmentation
347345
#endif
348346
#endif
349347

@@ -361,23 +359,23 @@
361359
const xyze_pos_t total = destination - current_position;
362360

363361
const float cart_xy_mm_2 = HYPOT2(total.x, total.y),
364-
cart_xy_mm = SQRT(cart_xy_mm_2); // Total XY distance
362+
cart_xy_mm = SQRT(cart_xy_mm_2); // Total XY distance
365363

366364
#if IS_KINEMATIC
367-
const float seconds = cart_xy_mm / scaled_fr_mm_s; // Duration of XY move at requested rate
368-
uint16_t segments = LROUND(segments_per_second * seconds), // Preferred number of segments for distance @ feedrate
369-
seglimit = LROUND(cart_xy_mm * RECIPROCAL(DELTA_SEGMENT_MIN_LENGTH)); // Number of segments at minimum segment length
370-
NOMORE(segments, seglimit); // Limit to minimum segment length (fewer segments)
365+
const float seconds = cart_xy_mm / scaled_fr_mm_s; // Duration of XY move at requested rate
366+
uint16_t segments = LROUND(segments_per_second * seconds), // Preferred number of segments for distance @ feedrate
367+
seglimit = LROUND(cart_xy_mm * RECIPROCAL(SEGMENT_MIN_LENGTH)); // Number of segments at minimum segment length
368+
NOMORE(segments, seglimit); // Limit to minimum segment length (fewer segments)
371369
#else
372-
uint16_t segments = LROUND(cart_xy_mm * RECIPROCAL(DELTA_SEGMENT_MIN_LENGTH)); // Cartesian fixed segment length
370+
uint16_t segments = LROUND(cart_xy_mm * RECIPROCAL(SEGMENT_MIN_LENGTH)); // Cartesian fixed segment length
373371
#endif
374372

375-
NOLESS(segments, 1U); // Must have at least one segment
376-
const float inv_segments = 1.0f / segments; // Reciprocal to save calculation
373+
NOLESS(segments, 1U); // Must have at least one segment
374+
const float inv_segments = 1.0f / segments; // Reciprocal to save calculation
377375

378376
// Add hints to help optimize the move
379-
PlannerHints hints(SQRT(cart_xy_mm_2 + sq(total.z)) * inv_segments); // Length of each segment
380-
#if ENABLED(SCARA_FEEDRATE_SCALING)
377+
PlannerHints hints(SQRT(cart_xy_mm_2 + sq(total.z)) * inv_segments); // Length of each segment
378+
#if ENABLED(FEEDRATE_SCALING)
381379
hints.inv_duration = scaled_fr_mm_s / hints.millimeters;
382380
#endif
383381

Marlin/src/gcode/calibrate/G33.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -407,12 +407,12 @@ void GcodeSuite::G33() {
407407
towers_set = !parser.seen_test('T');
408408

409409
// The calibration radius is set to a calculated value
410-
float dcr = probe_at_offset ? DELTA_PRINTABLE_RADIUS : DELTA_PRINTABLE_RADIUS - PROBING_MARGIN;
410+
float dcr = probe_at_offset ? PRINTABLE_RADIUS : PRINTABLE_RADIUS - PROBING_MARGIN;
411411
#if HAS_PROBE_XY_OFFSET
412412
const float total_offset = HYPOT(probe.offset_xy.x, probe.offset_xy.y);
413413
dcr -= probe_at_offset ? _MAX(total_offset, PROBING_MARGIN) : total_offset;
414414
#endif
415-
NOMORE(dcr, DELTA_PRINTABLE_RADIUS);
415+
NOMORE(dcr, PRINTABLE_RADIUS);
416416
if (parser.seenval('R')) dcr -= _MAX(parser.value_float(), 0.0f);
417417
TERN_(HAS_DELTA_SENSORLESS_PROBING, dcr *= sensorless_radius_factor);
418418

Marlin/src/gcode/calibrate/M48.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ void GcodeSuite::M48() {
162162
float angle = random(0, 360);
163163
const float radius = random(
164164
#if ENABLED(DELTA)
165-
int(0.1250000000 * (DELTA_PRINTABLE_RADIUS)),
166-
int(0.3333333333 * (DELTA_PRINTABLE_RADIUS))
165+
int(0.1250000000 * (PRINTABLE_RADIUS)),
166+
int(0.3333333333 * (PRINTABLE_RADIUS))
167167
#else
168168
int(5), int(0.125 * _MIN(X_BED_SIZE, Y_BED_SIZE))
169169
#endif

Marlin/src/gcode/calibrate/M665.cpp

+19
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,25 @@
181181
);
182182
}
183183

184+
#elif ENABLED(POLAR)
185+
186+
#include "../../module/polar.h"
187+
188+
/**
189+
* M665: Set POLAR settings
190+
* Parameters:
191+
* S[segments] - Segments-per-second
192+
*/
193+
void GcodeSuite::M665() {
194+
if (!parser.seen_any()) return M665_report();
195+
if (parser.seenval('S')) segments_per_second = parser.value_float();
196+
}
197+
198+
void GcodeSuite::M665_report(const bool forReplay/*=true*/) {
199+
report_heading_etc(forReplay, F(STR_POLAR_SETTINGS));
200+
SERIAL_ECHOLNPGM_P(PSTR(" M665 S"), segments_per_second);
201+
}
202+
184203
#endif
185204

186205
#endif // IS_KINEMATIC

Marlin/src/gcode/gcode.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@
335335
#include "../feature/encoder_i2c.h"
336336
#endif
337337

338-
#if IS_SCARA || defined(G0_FEEDRATE)
338+
#if EITHER(IS_SCARA, POLAR) || defined(G0_FEEDRATE)
339339
#define HAS_FAST_MOVES 1
340340
#endif
341341

Marlin/src/gcode/host/M114.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171

7272
#if IS_KINEMATIC
7373
// Kinematics applied to the leveled position
74-
SERIAL_ECHOPGM(TERN(IS_SCARA, "ScaraK: ", "DeltaK: "));
74+
SERIAL_ECHOPGM(TERN(POLAR, "Polar", TERN(IS_SCARA, "Scara", "Delta")) "K: " );
7575
inverse_kinematics(leveled); // writes delta[]
7676
report_linear_axis_pos(delta);
7777
#endif

Marlin/src/gcode/host/M360.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,7 @@ void GcodeSuite::M360() {
161161
SERIAL_ECHOLNPGM(
162162
TERN_(DELTA, "Delta")
163163
TERN_(IS_SCARA, "SCARA")
164+
TERN_(POLAR, "Polar")
164165
TERN_(IS_CORE, "Core")
165166
TERN_(MARKFORGED_XY, "MarkForgedXY")
166167
TERN_(MARKFORGED_YX, "MarkForgedYX")

Marlin/src/gcode/motion/G0_G1.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ void GcodeSuite::G0_G1(TERN_(HAS_FAST_MOVES, const bool fast_move/*=false*/)) {
106106

107107
#endif // FWRETRACT
108108

109-
#if IS_SCARA
109+
#if EITHER(IS_SCARA, POLAR)
110110
fast_move ? prepare_fast_move_to_destination() : prepare_line_to_destination();
111111
#else
112112
prepare_line_to_destination();

Marlin/src/gcode/motion/G2_G3.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ void plan_arc(
218218

219219
// Add hints to help optimize the move
220220
PlannerHints hints;
221-
#if ENABLED(SCARA_FEEDRATE_SCALING)
221+
#if ENABLED(FEEDRATE_SCALING)
222222
hints.inv_duration = (scaled_fr_mm_s / flat_mm) * segments;
223223
#endif
224224

Marlin/src/inc/Conditionals_LCD.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1406,7 +1406,7 @@
14061406
#if ANY(MORGAN_SCARA, MP_SCARA, AXEL_TPARA)
14071407
#define IS_SCARA 1
14081408
#define IS_KINEMATIC 1
1409-
#elif EITHER(DELTA, POLARGRAPH)
1409+
#elif ANY(DELTA, POLARGRAPH, POLAR)
14101410
#define IS_KINEMATIC 1
14111411
#else
14121412
#define IS_CARTESIAN 1

Marlin/src/inc/Conditionals_post.h

+8-6
Original file line numberDiff line numberDiff line change
@@ -267,19 +267,19 @@
267267
*/
268268
#if IS_KINEMATIC
269269
#undef LCD_BED_TRAMMING
270+
#undef SLOWDOWN
270271
#endif
271272

272273
/**
273274
* SCARA cannot use SLOWDOWN and requires QUICKHOME
274275
* Printable radius assumes joints can fully extend
275276
*/
276277
#if IS_SCARA
277-
#undef SLOWDOWN
278278
#if ENABLED(AXEL_TPARA)
279-
#define SCARA_PRINTABLE_RADIUS (TPARA_LINKAGE_1 + TPARA_LINKAGE_2)
279+
#define PRINTABLE_RADIUS (TPARA_LINKAGE_1 + TPARA_LINKAGE_2)
280280
#else
281281
#define QUICK_HOME
282-
#define SCARA_PRINTABLE_RADIUS (SCARA_LINKAGE_1 + SCARA_LINKAGE_2)
282+
#define PRINTABLE_RADIUS (SCARA_LINKAGE_1 + SCARA_LINKAGE_2)
283283
#endif
284284
#endif
285285

@@ -378,7 +378,6 @@
378378
*/
379379
#if ENABLED(DELTA)
380380
#undef Z_SAFE_HOMING
381-
#undef SLOWDOWN
382381
#endif
383382

384383
#ifndef MESH_INSET
@@ -3083,7 +3082,10 @@
30833082
/**
30843083
* Only constrain Z on DELTA / SCARA machines
30853084
*/
3086-
#if IS_KINEMATIC
3085+
#if ENABLED(POLAR)
3086+
#undef MIN_SOFTWARE_ENDSTOP_Y
3087+
#undef MAX_SOFTWARE_ENDSTOP_Y
3088+
#elif IS_KINEMATIC
30873089
#undef MIN_SOFTWARE_ENDSTOP_X
30883090
#undef MIN_SOFTWARE_ENDSTOP_Y
30893091
#undef MAX_SOFTWARE_ENDSTOP_X
@@ -3154,7 +3156,7 @@
31543156
#if EITHER(MESH_BED_LEVELING, AUTO_BED_LEVELING_UBL)
31553157
#if IS_KINEMATIC
31563158
// Probing points may be verified at compile time within the radius
3157-
// using static_assert(HYPOT2(X2-X1,Y2-Y1)<=sq(DELTA_PRINTABLE_RADIUS),"bad probe point!")
3159+
// using static_assert(HYPOT2(X2-X1,Y2-Y1)<=sq(PRINTABLE_RADIUS),"bad probe point!")
31583160
// so that may be added to SanityCheck.h in the future.
31593161
#define _MESH_MIN_X (X_MIN_BED + MESH_INSET)
31603162
#define _MESH_MIN_Y (Y_MIN_BED + MESH_INSET)

Marlin/src/inc/SanityCheck.h

+19-4
Original file line numberDiff line numberDiff line change
@@ -658,6 +658,12 @@
658658
#error "(POLAR|DELTA|SCARA|TPARA)_SEGMENTS_PER_SECOND is now DEFAULT_SEGMENTS_PER_SECOND."
659659
#elif ANY(DGUS_LCD_UI_ORIGIN, DGUS_LCD_UI_FYSETC, DGUS_LCD_UI_HIPRECY, DGUS_LCD_UI_MKS, DGUS_LCD_UI_RELOADED) && !defined(DGUS_LCD_UI)
660660
#error "DGUS_LCD_UI_[TYPE] is now set using DGUS_LCD_UI TYPE."
661+
#elif defined(DELTA_PRINTABLE_RADIUS)
662+
#error "DELTA_PRINTABLE_RADIUS is now PRINTABLE_RADIUS."
663+
#elif defined(SCARA_PRINTABLE_RADIUS)
664+
#error "SCARA_PRINTABLE_RADIUS is now PRINTABLE_RADIUS."
665+
#elif defined(SCARA_FEEDRATE_SCALING)
666+
#error "SCARA_FEEDRATE_SCALING is now FEEDRATE_SCALING."
661667
#endif
662668

663669
// L64xx stepper drivers have been removed
@@ -1371,6 +1377,13 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
13711377
#endif
13721378
#endif
13731379

1380+
/**
1381+
* POLAR warnings
1382+
*/
1383+
#if BOTH(POLAR, S_CURVE_ACCELERATION)
1384+
#warning "POLAR Kinematics may not work well with S_CURVE_ACCELERATION."
1385+
#endif
1386+
13741387
/**
13751388
* Special tool-changing options
13761389
*/
@@ -1666,8 +1679,8 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
16661679
/**
16671680
* Allow only one kinematic type to be defined
16681681
*/
1669-
#if MANY(DELTA, MORGAN_SCARA, MP_SCARA, AXEL_TPARA, COREXY, COREXZ, COREYZ, COREYX, COREZX, COREZY, MARKFORGED_XY, MARKFORGED_YX, ARTICULATED_ROBOT_ARM, FOAMCUTTER_XYUV)
1670-
#error "Please enable only one of DELTA, MORGAN_SCARA, MP_SCARA, AXEL_TPARA, COREXY, COREXZ, COREYZ, COREYX, COREZX, COREZY, MARKFORGED_XY, MARKFORGED_YX, ARTICULATED_ROBOT_ARM, or FOAMCUTTER_XYUV."
1682+
#if MANY(DELTA, MORGAN_SCARA, MP_SCARA, AXEL_TPARA, COREXY, COREXZ, COREYZ, COREYX, COREZX, COREZY, MARKFORGED_XY, MARKFORGED_YX, ARTICULATED_ROBOT_ARM, FOAMCUTTER_XYUV, POLAR)
1683+
#error "Please enable only one of DELTA, MORGAN_SCARA, MP_SCARA, AXEL_TPARA, COREXY, COREXZ, COREYZ, COREYX, COREZX, COREZY, MARKFORGED_XY, MARKFORGED_YX, ARTICULATED_ROBOT_ARM, FOAMCUTTER_XYUV, or POLAR."
16711684
#endif
16721685

16731686
/**
@@ -1695,7 +1708,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
16951708
* Junction deviation is incompatible with kinematic systems.
16961709
*/
16971710
#if HAS_JUNCTION_DEVIATION && IS_KINEMATIC
1698-
#error "CLASSIC_JERK is required for DELTA and SCARA."
1711+
#error "CLASSIC_JERK is required for DELTA, SCARA, and POLAR."
16991712
#endif
17001713

17011714
/**
@@ -1913,7 +1926,7 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
19131926
static_assert(PROBING_MARGIN_RIGHT >= 0, "PROBING_MARGIN_RIGHT must be >= 0.");
19141927
#endif
19151928

1916-
#define _MARGIN(A) TERN(IS_SCARA, SCARA_PRINTABLE_RADIUS, TERN(DELTA, DELTA_PRINTABLE_RADIUS, ((A##_BED_SIZE) / 2)))
1929+
#define _MARGIN(A) TERN(IS_KINEMATIC, PRINTABLE_RADIUS, ((A##_BED_SIZE) / 2))
19171930
static_assert(PROBING_MARGIN < _MARGIN(X), "PROBING_MARGIN is too large.");
19181931
static_assert(PROBING_MARGIN_BACK < _MARGIN(Y), "PROBING_MARGIN_BACK is too large.");
19191932
static_assert(PROBING_MARGIN_FRONT < _MARGIN(Y), "PROBING_MARGIN_FRONT is too large.");
@@ -2004,6 +2017,8 @@ static_assert(Y_MAX_LENGTH >= Y_BED_SIZE, "Movement bounds (Y_MIN_POS, Y_MAX_POS
20042017

20052018
#if IS_SCARA
20062019
#error "AUTO_BED_LEVELING_UBL does not yet support SCARA printers."
2020+
#elif ENABLED(POLAR)
2021+
#error "AUTO_BED_LEVELING_UBL does not yet support POLAR printers."
20072022
#elif DISABLED(EEPROM_SETTINGS)
20082023
#error "AUTO_BED_LEVELING_UBL requires EEPROM_SETTINGS."
20092024
#elif !WITHIN(GRID_MAX_POINTS_X, 3, 15) || !WITHIN(GRID_MAX_POINTS_Y, 3, 15)

0 commit comments

Comments
 (0)