o sub F#<_ini[TOOLSENSOR]RAPID_FEED> G90 G53 G1 Z[#<_ini[AXIS_Z]MAX_LIMIT>] G53 G1 X[#<_ini[TOOLSENSOR]X_PROBE_COORD>] Y[#<_ini[TOOLSENSOR]Y_PROBE_COORD>] G53 G1 Z[#<_ini[TOOLSENSOR]Z_START>] G4 P0.5 G91 F #<_ini[TOOLSENSOR]SEARCH_FEED> G49 G38.2 Z #<_ini[TOOLSENSOR]Z_MAXPROBE> # = [#[5203 + #5220 * 20] + #5213 * #5210] G10 L1 P#5400 Z# (set new tool offset) G43 G90 G53 G1 Z[#<_ini[TOOLSENSOR]Z_START>] F#<_ini[TOOLSENSOR]RAPID_FEED> o endsub M2 Say we are in G55 then #5220 would equal 2. (20 * 2) = 40. (5203 + 40) = 5243 which would be the Z location in G55. 5241-5250 - Coordinate System 2, G55 for X, Y, Z, A, B, C, U, V, W & R. Persistent. probe_cal_round_boss.ngc: # = #[5203 + [20 * #5220]] ( INI SECTION PARAMETERS ) ( [TOOLSENSOR] ) ( RAPID_FEED = 30 ) ( SEARCH_FEED = 15 ) ( PROBE_LEVEL_FEED = 5 ) ( X_PROBE_COORD = 1 ) ( Y_PROBE_COORD = 1 ) ( Z_START = -.1 ) ( Z_MAXPROBE = -2 ) in the linuxcnc documentation this example of gcode is provided G49 G38.2 Z-100 F100 # = [#[5203 + #5220 * 20] + #5213 * #5210] G10 L1 P#5400 Z# (set new tool offset) G43 i want to understand this equation # = [#[5203 + #5220 * 20] + #5213 * #5210]. any help is appreciated #[5203 + #5220 * 20] This is the value of the z offset of the currently active work offset system Note: the offset value registers of all the work offset systems [1..9] are 20 registers apart. + #5213 * #5210] This adds the z offset of 52/G92 if it is applied, if it is not applied the product is equal to zero