@@ -2,6 +2,11 @@ o<qt_auto_probe_tool> sub
22;(debug, in change tool_in_spindle=#<tool_in_spindle> current_pocket=#<current_pocket>)
33;(debug, selected_tool=#<selected_tool> selected_pocket=#<selected_pocket>)
44
5+ ; calculate Z offset value based on current work offset (#5220) and
6+ ; G92/G52 offset if enabled (#5210)
7+ #<zworkoffset> = [#[5203 + #5220 * 20] + #5213 * #5210]
8+
9+
510#<tool> = #<selected_tool>
611#<pocket> = #<selected_pocket>
712; we must execute this only in the milltask interpreter
@@ -61,22 +66,27 @@ O400 endif
6166
6267F #<_hal[qtversaprobe.searchvel]>
6368G91
64- G38.2 Z- #<_ini[VERSA_TOOLSETTER]MAXPROBE>
69+ G38.3 Z- #<_ini[VERSA_TOOLSETTER]MAXPROBE>
6570G0 Z #<_hal[qtversaprobe.backoffdist]>
6671
67- ;reprobe at probe speed
68- F #<_hal[qtversaprobe.probevel]>
69- G38.2 Z- [#<_hal[qtversaprobe.backoffdist]> *1.2]
70-
7172O500 if [#5070 EQ 0]
7273G90
7374O500 return [-3] ; indicate probe contact failure to epilog
7475O500 endif
7576
77+ ;reprobe at probe speed
78+ F #<_hal[qtversaprobe.probevel]>
79+ G38.3 Z- [#<_hal[qtversaprobe.backoffdist]> *1.2]
80+
81+ O600 if [#5070 EQ 0]
82+ G90
83+ O600 return [-3] ; indicate probe contact failure to epilog
84+ O600 endif
85+
7686G90
7787G53 G0 Z[#<_ini[CHANGE_POSITION]Z>]
7888
79- #<touch_result> = #5063
89+ #<touch_result> = [ #5063 + #<zworkoffset>]
8090
8191(DEBUG, %fProbe Height: #<_hal[qtversaprobe.probeheight]>)
8292(DEBUG, %fBlock Height: #<_hal[qtversaprobe.blockheight]>)
0 commit comments