M851 XY 3 point followup (incomplete) (#15361)

This commit is contained in:
InsanityAutomation
2019-09-25 03:43:41 -04:00
committed by Scott Lahteine
parent 66d0221077
commit e9cf46a9a5
120 changed files with 67 additions and 1617 deletions

View File

@ -200,6 +200,10 @@
#undef SLOWDOWN
#endif
#ifndef MESH_INSET
#define MESH_INSET 0
#endif
/**
* Safe Homing Options
*/
@ -1490,15 +1494,6 @@ constexpr float nozzle_to_probe_offset[XYZ] = NOZZLE_TO_PROBE_OFFSET;
#define PROBE_Y_MIN (Y_CENTER - (SCARA_PRINTABLE_RADIUS) + MIN_PROBE_EDGE)
#define PROBE_X_MAX (X_CENTER + SCARA_PRINTABLE_RADIUS - (MIN_PROBE_EDGE))
#define PROBE_Y_MAX (Y_CENTER + SCARA_PRINTABLE_RADIUS - (MIN_PROBE_EDGE))
#else
// Boundaries for Cartesian probing based on bed limits
#define PROBE_X_MIN (_MAX(X_MIN_BED + MIN_PROBE_EDGE, X_MIN_POS + nozzle_to_probe_offset[X_AXIS]))
#define PROBE_Y_MIN (_MAX(Y_MIN_BED + MIN_PROBE_EDGE, Y_MIN_POS + nozzle_to_probe_offset[Y_AXIS]))
#define PROBE_X_MAX (_MIN(X_MAX_BED - (MIN_PROBE_EDGE), X_MAX_POS + nozzle_to_probe_offset[X_AXIS]))
#define PROBE_Y_MAX (_MIN(Y_MAX_BED - (MIN_PROBE_EDGE), Y_MAX_POS + nozzle_to_probe_offset[Y_AXIS]))
#endif
#if ENABLED(SEGMENT_LEVELED_MOVES) && !defined(LEVELED_SEGMENT_LENGTH)
@ -1508,7 +1503,7 @@ constexpr float nozzle_to_probe_offset[XYZ] = NOZZLE_TO_PROBE_OFFSET;
/**
* Default mesh area is an area with an inset margin on the print area.
*/
#if EITHER(MESH_BED_LEVELING, AUTO_BED_LEVELING_UBL)
#if ANY(MESH_BED_LEVELING, AUTO_BED_LEVELING_UBL, AUTO_BED_LEVELING_BILINEAR)
#if IS_KINEMATIC
// Probing points may be verified at compile time within the radius
// using static_assert(HYPOT2(X2-X1,Y2-Y1)<=sq(DELTA_PRINTABLE_RADIUS),"bad probe point!")
@ -1548,54 +1543,6 @@ constexpr float nozzle_to_probe_offset[XYZ] = NOZZLE_TO_PROBE_OFFSET;
#endif // MESH_BED_LEVELING || AUTO_BED_LEVELING_UBL
#if EITHER(AUTO_BED_LEVELING_UBL, AUTO_BED_LEVELING_3POINT)
#if IS_KINEMATIC
#define SIN0 0.0
#define SIN120 0.866025
#define SIN240 -0.866025
#define COS0 1.0
#define COS120 -0.5
#define COS240 -0.5
#ifndef PROBE_PT_1_X
#define PROBE_PT_1_X (X_CENTER + (_PROBE_RADIUS) * COS0)
#endif
#ifndef PROBE_PT_1_Y
#define PROBE_PT_1_Y (Y_CENTER + (_PROBE_RADIUS) * SIN0)
#endif
#ifndef PROBE_PT_2_X
#define PROBE_PT_2_X (X_CENTER + (_PROBE_RADIUS) * COS120)
#endif
#ifndef PROBE_PT_2_Y
#define PROBE_PT_2_Y (Y_CENTER + (_PROBE_RADIUS) * SIN120)
#endif
#ifndef PROBE_PT_3_X
#define PROBE_PT_3_X (X_CENTER + (_PROBE_RADIUS) * COS240)
#endif
#ifndef PROBE_PT_3_Y
#define PROBE_PT_3_Y (Y_CENTER + (_PROBE_RADIUS) * SIN240)
#endif
#else
#ifndef PROBE_PT_1_X
#define PROBE_PT_1_X PROBE_X_MIN
#endif
#ifndef PROBE_PT_1_Y
#define PROBE_PT_1_Y PROBE_Y_MIN
#endif
#ifndef PROBE_PT_2_X
#define PROBE_PT_2_X PROBE_X_MAX
#endif
#ifndef PROBE_PT_2_Y
#define PROBE_PT_2_Y PROBE_Y_MIN
#endif
#ifndef PROBE_PT_3_X
#define PROBE_PT_3_X X_CENTER
#endif
#ifndef PROBE_PT_3_Y
#define PROBE_PT_3_Y PROBE_Y_MAX
#endif
#endif
#endif
/**
* Buzzer/Speaker
*/