UBL Marlin settings to cover whole bed This question is related to:
How to set Z-probe boundary limits in firmware when using automatic bed leveling?
I am trying to figure out how to set UBL In Marlin to cover as much bed as possible.
So My bed is size of 300x255 mm
#define NOZZLE_TO_PROBE_OFFSET { -34, -1, -2 }
My Probe can physically cover 255 mm (whole Y) and 272 mm (of X size)
Let's give it a bit of margin of the 0Y -&gt; 3 mm and from 0X -3 mm
So idea is to cover X from 3 mm to 269 mm and Y from 3 mm -&gt; 252 mm
How should I set
#define PROBING_MARGIN
and
#define MESH_INSET
so it covers my bed and probes 100 points ?
I tried different options, most of the time it stops at 57/100 and printer HALTs.
Only setting I got it working with was:
#define PROBING_MARGIN 30
#define MESH_INSET 50
But that does not cover whole bed. I am struggling to understand how it's calculated.
Other settings I found was commented as below.
#if PROBE_SELECTED &amp;&amp; !IS_KINEMATIC
  // #define PROBING_MARGIN_LEFT PROBING_MARGIN
  // #define PROBING_MARGIN_RIGHT PROBING_MARGIN
  // #define PROBING_MARGIN_FRONT PROBING_MARGIN
  // #define PROBING_MARGIN_BACK PROBING_MARGIN
#endif

Any suggestions ?
PROBING_MARGIN and MESH_INSET make the effective probing area smaller, so if you want to have more area, you should reduce the value of these constants.
As of Marlin 2.x, the probing area isn't defined directly by the firmware configuration settings, but calculated, based on the probe offset settings. The constants you mention are reducing the probing area to keep the carriage/nozzle on the build surface.
If you have enough space on your printer to accommodate probing the whole bed, you could minimize the marging and define edges:
#if PROBE_SELECTED &amp;&amp; !IS_KINEMATIC
  #define PROBING_MARGIN_LEFT PROBING_MARGIN
  #define PROBING_MARGIN_RIGHT PROBING_MARGIN
  #define PROBING_MARGIN_FRONT PROBING_MARGIN
  #define PROBING_MARGIN_BACK PROBING_MARGIN
#endif