Interface IToolHeightCompensationDef
Tool height compensation state written by
ToolHeightOffsetSyntax.
Property names are used as JSON keys via nameof.
The JSON section can be deserialized to an instance implementing this interface.
Managed commands (ISO/Fanuc): G43, G44, G49. Fanuc extension: G43.4 (TCPM — parsed only in Fanuc syntax list). Siemens equivalent: TRAFOOF/TRAORI (handled by separate syntax). Heidenhain equivalent: TOOL CALL / M128/M129 (handled by separate syntax).
public interface IToolHeightCompensationDef
- Extension Methods
Examples
"ToolHeightCompensation": {
"Offset_mm": 99.98,
"Term": "G43",
"OffsetId": 1
}
Remarks
RTCP-rotary-dynamic state (whether the per-step MC path is non-linear while CL is commanded linearly) is signalled by a KindDynamic entry in the ProgramToMcTransform chain rather than by a flag on this section, so consumers detect it via HasDynamicEntry(JsonObject) without needing brand-specific strings.
Properties
OffsetId
Generic offset selector: Fanuc H number, Heidenhain T number, Mazak/Okuma H number. For Siemens (T+D addressing), see ISiemensToolOffsetConfig.
int OffsetId { get; set; }
Property Value
Offset_mm
Derived effective tool height compensation in mm. Computed from Term and OffsetId: looks up the offset table for OffsetId, obtains the effective height (geometry minus wear), then applies sign from Term (positive for G43/G43.4, negative for G44, zero for G49).
double Offset_mm { get; set; }
Property Value
Term
CNC term for tool height compensation: “G43”, “G43.4”, “G44”, “G49”. Brand-specific syntaxes may write equivalent terms (e.g., “TRAORI” for Siemens, “M128” for Heidenhain).
string Term { get; set; }