Update G29.cpp#28418
Open
Maker-Paul wants to merge 3 commits into
Open
Conversation
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Description
Simple update to G29.cpp (ABL) only. Adds automatic probe trigger height determination to set the Probe Z offset. avoids the probe trigger height above Z stop (Z=0) being incorrectly stored in all the bed level mesh values.
Only on machines that do not use the probe for homing when using ABL bed leveling. The probe offset will usually be larger than the home offset in these setups (it doesn't matter if its lower). When the G29 routine starts it sets the Z = 0 or home position using the homing device. But goes on to measure the bed level mesh points relative to the Z = 0 this causes all the mesh points to appear high or low by the difference between the home trigger height and the probe trigger height. This pull request simply reads the probe trigger height (which is the difference between Z home and probe trigger height) and adjusts the Z offset to account for that difference at the start of G29.
Requirements
No special requirements does not affect machines with only Z stops or machines that use the probe for Z homing.
Benefits
Machines with separate methods for homing and creating the bed level mesh will not include probe Z offset in the mesh values just the bed topology. The user can still set the Z home offset as normal.
Configurations
definitions required in configuration.h
// #define Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
// #define USE_PROBE_FOR_Z_HOMING
#define Z_SAFE_HOMING
#define AUTO_BED_LEVELING_BILINEAR
Related Issues
yes
will fix #27680 a simple way.
#28393
may fix other
#22653
#21727
#21833
Also #28380 identifies an issue where the mesh is incorrectly shifted by the X and Y probe offsets. it is easy to see in the bed level maps I have posted on the #28380 pull request. So should also be merged please.