The fix in #6251 for bilinear Z offset was flawed and broke the Z parameter of G29 for bilinear levelling. This is reverted and a different fix is used for the double-addition of the Z-probe offset to the bilinear correction grid.
Since run_probe was altered to return the probe Z position rather than the nozzle Z position bilinear levelling has been broken because the Z-offset has been applied twice - once in the run_probe function, and then again in the G29 code for bilinear levelling.
- Make all `unified_bed_leveling` data/methods static
- Move some UBL-related variables into the class
- Replace `map_[xy]_index_to_bed_location` with `mesh_index_to_[xy]pos`
With the the current definition of echo_command I cannot compile RCBugFix (Arduino IDE 1.8.1) with the error "invalid conversion from 'const char*' to 'char*'". This change resolves that.
Made the double touch portion a conditional compile based on the
PROBE_DOUBLE_TOUCH flag.
==============================================
Bugfix
The current G38 only stopped a move if it involved the Z axis.
Moved all the G38 code to it's own section and put it where it would
always be executed no matter what axis was moving or if the endstop was
enabled.
Also added a comment to configuration_adv to alert the user the double
tap had to be turned on.
==============================================
Change G38 back to using Z_MIN_PROBE
There's no Z_MIN endstop if Z_DUAL_ENDSTOPS is enabled and you have them
set to the top of the gantry.
G38 started out as using the Z_MIN_PROBE pin. I don't remember why we
changed it to the Z_MIN endstop.