# Calculate measuring offsets (G101/G102)

The measuring offset is the offset depicted in the figure below between the recorded measuring position and the target point. It is calculated as follows:

Measurement offset = measuring point – target point

 Syntax: G101 .. { .. } non-modal
 G101 Include measuring offset calculation in offset .. Axis-specific factor to include measuring offset in calculation

## Notice

Several axes can also be specified for measurement type 2 if a separate measurement run was conducted for each of these axes beforehand.

For the programmed coordinates, the measuring offset determined from the measured values is included in the calculation of an additional offset between programmed and absolute coordinates. An error message is output if no measured values were detected beforehand. The numeral after the axis designation represents the inclusion factor.

The offset caused by the measurement offset is valid until it is deselected by G102.

## Programing Example

Calculate measuring offsets (G101/G102)

Includes the measuring offset for X in the calculation with factor 1 and for Y with factor 7 in the offset between programmed and absolute coordinates.

N10 G101 X1 Y7

 Syntax: G102 { .. } non-modal
 G102 Extract measuring offset from offset .. Axis for which the measuring offset is extracted. Compared to G101, the value behind the axis specified is meaningless but required due to syntactical reasons.

The measured values adopted with G100 and included in the calculation as further offsets with G101 are extracted according to the following rule:

If one or more axes are programmed, only these axes are calculated. If no axis was programmed, all offsets are extracted.

An error message is generated if an axis was programmed for which no measuring offset is included in the calculation.

The offset included in the calculation with G101 is always extracted.

## Programing Example

Calculate measuring offsets (G101/G102)

Extract an axis/all axes

N10 G102 X1 ;Only extract offset of X-axis

N20 G102     ;Extract offsets of all axes