Table of Contents

Class HeidenhainIncrementalAxisWordUtil

Namespace
Hi.NcParsers.ParsingSyntaxs.Heidenhain
Assembly
HiMech.dll

The klartext I-prefixed incremental axis wordIX+20, IY-15, IZ+Q1, rotary IC+90: the same axis word as the absolute X+20, read as a distance from the last programmed position instead of a coordinate. Any word of a block may be incremental on its own (L X+60 IY-10 mixes both), which is exactly the per-word shape the shared PositioningOverride section models for the Siemens IC() wrapper. So the grab here writes the value under the plain axis key of the caller's section (Parsing.X for an L/C endpoint, Parsing.CC.X for a circle center, Parsing[“CYCL CALL”].X for a cycle-call position) and stamps “PositioningOverride”: { “X”: “Incremental” } on the block root; the conversion to absolute stays with the existing consumers — IncrementalResolveSyntax for linear axes (the Heidenhain instance also walks the CC record), McAbcSyntax for rotary axes, and HeidenhainCannedCycleSyntax on the spot for the words it consumes ahead of the resolve — and no second incremental mechanism exists. The one klartext I word that is NOT a distance from the tool position, the CYCL DEF 7 datum shift, deliberately does not use this helper (see HeidenhainDatumShiftSyntax).

The plain axis grab (NcSyntaxUtil.GrabTagValue) cannot see the X inside IX: RegexFlagPrefix demands a word boundary, a digit or whitespace before the tag, and I is a word character. That guard is what keeps the plain grab from half-reading an incremental block (L X+60 IY-10 used to take X and drop the Y — a motion to the wrong place, not a missing one), so the incremental words are grabbed by their own two-letter tags (IX, IY, …) instead of relaxing the guard. The value grammar is the shared one (signed number, Q variable, bracket expression), and a glued run (LIX+20IY-15) parses like the absolute glued shape because the digit alternative of the prefix guard admits the second word.

public static class HeidenhainIncrementalAxisWordUtil
Inheritance
HeidenhainIncrementalAxisWordUtil
Inherited Members

Fields

Prefix

The klartext incremental prefix letter.

public const string Prefix = "I"

Field Value

string

Methods

GrabIncrementalAxisWords(JsonObject, JsonObject, IEnumerable<string>, ref string, IEnumerable<string>)

Grabs every I-prefixed incremental word of axisTags from unparsedText, writes each value under its plain axis key of the object at sectionPath below parsing (parsed via ToFloat(string), like the absolute words) and stamps an Incremental entry per axis into the block-root PositioningOverride section of block. No words → nothing is written (no empty override section appears).

public static void GrabIncrementalAxisWords(JsonObject block, JsonObject parsing, IEnumerable<string> sectionPath, ref string unparsedText, IEnumerable<string> axisTags)

Parameters

block JsonObject

Block-root JSON object (owner of the override section).

parsing JsonObject

The block's Parsing object.

sectionPath IEnumerable<string>

Path below parsing that receives the axis values (empty = the Parsing root).

unparsedText string

Block text; the grabbed words are removed.

axisTags IEnumerable<string>

Plain axis tags to look for behind the prefix (the caller's own tag list).