Repository navigation
preview and DROs: G52 offsets and the tilted work plane - #4841
Open
grandixximo wants to merge 2 commits into
Open
grandixximo wants to merge 2 commits into
grandixximo wants to merge 2 commits into
Conversation
The preview started from the startup code, which often clears the G92 offsets with G92.1, and then restated the "G92 applied" mode as G92.3, which reads them back from the preview's copy of the parameters. A G52 set in MDI was lost, so the program was drawn without it, and with a tilted work plane active the G92.3 came after the plane, which refuses a change to the G92 offsets: the preview stopped at line 0 with "Cannot change G92 offsets while a tilted work plane (G68.2) is active". The preview now restates the offsets with G52 and the machine's values, ahead of the plane, which sits inside them. tests/workplane-preview checks a G52 alone and under a plane: both ended 7 mm off or refused before, the same end as the machine now. Reported by Sigma1912.
hal_glib's get_position(), which gmoccapy's and qtvcp's DROs read, and the gladevcp DRO widget left out the tilted work plane, which AXIS takes off after G92: after G68.2 Z30 and G0 X0 Y0 Z0 they showed Z30. Both now take the plane off as AXIS does. Reported by Sigma1912.
grandixximo
added a commit
to grandixximo/linuxcnc
that referenced
this pull request
Nov 14, 2026
Under the machine frame kinematics the plane is cut through the machine's second feature coordinate system, which comes after the whole offset chain; AXIS takes it off first. hal_glib's get_position() and the gladevcp DRO widget left it out: in a plane under G13.1, G0 X1 Y2 Z3 showed X-4.1 Y-88.7 Z27.1. Both now take it off as AXIS does. To fold into the lane that taught AXIS the same, once LinuxCNC#4841 has merged.
grandixximo
added a commit
to grandixximo/linuxcnc
that referenced
this pull request
Nov 14, 2026
Under the machine frame kinematics the plane is cut through the machine's second feature coordinate system, which comes after the whole offset chain; AXIS takes it off first. hal_glib's get_position() and the gladevcp DRO widget left it out: in a plane under G13.1, G0 X1 Y2 Z3 showed X-4.1 Y-88.7 Z27.1. Both now take it off as AXIS does. To fold into the lane that taught AXIS the same, once LinuxCNC#4841 has merged.
grandixximo
added a commit
to grandixximo/linuxcnc
that referenced
this pull request
Nov 14, 2026
Under the machine frame kinematics the plane is cut through the machine's second feature coordinate system, which comes after the whole offset chain; AXIS takes it off first. hal_glib's get_position() and the gladevcp DRO widget left it out: in a plane under G13.1, G0 X1 Y2 Z3 showed X-4.1 Y-88.7 Z27.1. Both now take it off as AXIS does. To fold into the lane that taught AXIS the same, once LinuxCNC#4841 has merged.
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.
Three bugs Sigma1912 found:
G68.2 Z30andG0 X0 Y0 Z0they showed Z30. hal_glib'sget_position()and the gladevcp DRO widget now take the plane off after G92, as AXIS does.tests/workplane-preview gets two cases, a G52 alone and a G52 under a plane. On master the first ends 7 mm off and the second is refused; with the fix both end where the machine does. The DRO code needs a display, so I checked it on a sim under xvfb rather than in a test.