Archived
304 lines
16 KiB
HTML
304 lines
16 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title>Class HeidenhainIncrementalAxisWordUtil | HiAPI-C# 2025 </title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta name="title" content="Class HeidenhainIncrementalAxisWordUtil | HiAPI-C# 2025 ">
|
|
|
|
<meta name="description" content="The klartext I-prefixed incremental axis word — IX+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 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[&ldquo;CYCL CALL&rdquo;].X for a cycle-call position) and stamps &ldquo;PositioningOverride&rdquo;: { &ldquo;X&rdquo;: &ldquo;Incremental&rdquo; } on the block root; the conversion to absolute stays with the existing consumers — for linear axes (the Heidenhain instance also walks the CC record), for rotary axes, and 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 ). The plain axis grab (NcSyntaxUtil.GrabTagValue) cannot see the X inside IX: 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.">
|
|
<link rel="icon" href="../img/HiAPI.favicon.ico">
|
|
<link rel="stylesheet" href="../public/docfx.min.css">
|
|
<link rel="stylesheet" href="../public/main.css">
|
|
<meta name="docfx:navrel" content="../toc.html">
|
|
<meta name="docfx:tocrel" content="toc.html">
|
|
|
|
<meta name="docfx:rel" content="../">
|
|
|
|
|
|
|
|
<meta name="loc:inThisArticle" content="In this article">
|
|
<meta name="loc:searchResultsCount" content="{count} results for "{query}"">
|
|
<meta name="loc:searchNoResults" content="No results for "{query}"">
|
|
<meta name="loc:tocFilter" content="Filter by title">
|
|
<meta name="loc:nextArticle" content="Next">
|
|
<meta name="loc:prevArticle" content="Previous">
|
|
<meta name="loc:themeLight" content="Light">
|
|
<meta name="loc:themeDark" content="Dark">
|
|
<meta name="loc:themeAuto" content="Auto">
|
|
<meta name="loc:changeTheme" content="Change theme">
|
|
<meta name="loc:copy" content="Copy">
|
|
<meta name="loc:downloadPdf" content="Download PDF">
|
|
|
|
<script type="module" src="./../public/docfx.min.js"></script>
|
|
|
|
<script>
|
|
const theme = localStorage.getItem('theme') || 'auto'
|
|
document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme)
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body class="tex2jax_ignore" data-layout="" data-yaml-mime="ManagedReference">
|
|
<header class="bg-body border-bottom">
|
|
<nav id="autocollapse" class="navbar navbar-expand-md" role="navigation">
|
|
<div class="container-xxl flex-nowrap">
|
|
<a class="navbar-brand" href="../index.html">
|
|
<img id="logo" class="svg" src="../img/HiAPI.logo.png" alt="">
|
|
|
|
</a>
|
|
<button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation">
|
|
<i class="bi bi-three-dots"></i>
|
|
</button>
|
|
<div class="collapse navbar-collapse" id="navpanel">
|
|
<div id="navbar">
|
|
<form class="search" role="search" id="search">
|
|
<i class="bi bi-search"></i>
|
|
<input class="form-control" id="search-query" type="search" disabled placeholder="Search" autocomplete="off" aria-label="Search">
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</nav>
|
|
</header>
|
|
|
|
<main class="container-xxl">
|
|
<div class="toc-offcanvas">
|
|
<div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel">
|
|
<div class="offcanvas-header">
|
|
<h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5>
|
|
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button>
|
|
</div>
|
|
<div class="offcanvas-body">
|
|
<nav class="toc" id="toc"></nav>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="content">
|
|
<div class="actionbar">
|
|
<button class="btn btn-lg border-0 d-md-none" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents">
|
|
<i class="bi bi-list"></i>
|
|
</button>
|
|
|
|
<nav id="breadcrumb"></nav>
|
|
</div>
|
|
|
|
<article data-uid="Hi.NcParsers.ParsingSyntaxs.Heidenhain.HeidenhainIncrementalAxisWordUtil">
|
|
|
|
|
|
|
|
<h1 id="Hi_NcParsers_ParsingSyntaxs_Heidenhain_HeidenhainIncrementalAxisWordUtil" data-uid="Hi.NcParsers.ParsingSyntaxs.Heidenhain.HeidenhainIncrementalAxisWordUtil" class="text-break">
|
|
Class HeidenhainIncrementalAxisWordUtil
|
|
</h1>
|
|
|
|
<div class="facts text-secondary">
|
|
<dl><dt>Namespace</dt><dd><a class="xref" href="Hi.html">Hi</a>.<a class="xref" href="Hi.NcParsers.html">NcParsers</a>.<a class="xref" href="Hi.NcParsers.ParsingSyntaxs.html">ParsingSyntaxs</a>.<a class="xref" href="Hi.NcParsers.ParsingSyntaxs.Heidenhain.html">Heidenhain</a></dd></dl>
|
|
<dl><dt>Assembly</dt><dd>HiMech.dll</dd></dl>
|
|
</div>
|
|
|
|
<div class="markdown summary"><p>The klartext <b>I-prefixed incremental axis word</b> — <code>IX+20</code>,
|
|
<code>IY-15</code>, <code>IZ+Q1</code>, rotary <code>IC+90</code>: the same axis word
|
|
as the absolute <code>X+20</code>, read as a distance from the last
|
|
programmed position instead of a coordinate. Any word of a block may
|
|
be incremental on its own (<code>L X+60 IY-10</code> mixes both), which is
|
|
exactly the per-word shape the shared
|
|
<a class="xref" href="Hi.NcParsers.Keywords.PositioningOverride.html">PositioningOverride</a> section models for the
|
|
Siemens <code>IC()</code> wrapper. So the grab here writes the value under
|
|
the <b>plain</b> axis key of the caller's section (<code>Parsing.X</code>
|
|
for an <code>L</code>/<code>C</code> endpoint, <code>Parsing.CC.X</code> for a circle
|
|
center, <code>Parsing[“CYCL CALL”].X</code> for a cycle-call position) and
|
|
stamps <code>“PositioningOverride”: { “X”: “Incremental” }</code> on the
|
|
block root; the conversion to absolute stays with the existing
|
|
consumers — <a class="xref" href="Hi.NcParsers.LogicSyntaxs.IncrementalResolveSyntax.html">IncrementalResolveSyntax</a> for
|
|
linear axes (the Heidenhain instance also walks the <code>CC</code> record),
|
|
<a class="xref" href="Hi.NcParsers.LogicSyntaxs.McAbcSyntax.html">McAbcSyntax</a> for rotary axes, and
|
|
<a class="xref" href="Hi.NcParsers.LogicSyntaxs.Heidenhain.HeidenhainCannedCycleSyntax.html">HeidenhainCannedCycleSyntax</a> on
|
|
the spot for the words it consumes ahead of the resolve — and no
|
|
second incremental mechanism exists. The one klartext <code>I</code> word
|
|
that is NOT a distance from the tool position, the <code>CYCL DEF 7</code>
|
|
datum shift, deliberately does not use this helper (see
|
|
<a class="xref" href="Hi.NcParsers.ParsingSyntaxs.Heidenhain.CyclDefSyntaxs.HeidenhainDatumShiftSyntax.html">HeidenhainDatumShiftSyntax</a>).</p>
|
|
<p>
|
|
The plain axis grab (<code>NcSyntaxUtil.GrabTagValue</code>) cannot see the
|
|
<code>X</code> inside <code>IX</code>: <a class="xref" href="Hi.NcParsers.SoftNcUtil.html#Hi_NcParsers_SoftNcUtil_RegexFlagPrefix">RegexFlagPrefix</a>
|
|
demands a word boundary, a digit or whitespace before the tag, and
|
|
<code>I</code> is a word character. That guard is what keeps the plain grab
|
|
from half-reading an incremental block (<code>L X+60 IY-10</code> 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 (<code>IX</code>, <code>IY</code>, …) instead of relaxing the guard.
|
|
The value grammar is the shared one (signed number, <code>Q</code>
|
|
variable, bracket expression), and a glued run (<code>LIX+20IY-15</code>)
|
|
parses like the absolute glued shape because the digit alternative of
|
|
the prefix guard admits the second word.
|
|
</p>
|
|
</div>
|
|
<div class="markdown conceptual"></div>
|
|
|
|
<div class="codewrapper">
|
|
<pre><code class="lang-csharp hljs">public static class HeidenhainIncrementalAxisWordUtil</code></pre>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<dl class="typelist inheritance">
|
|
<dt>Inheritance</dt>
|
|
<dd>
|
|
<div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
|
|
<div><span class="xref">HeidenhainIncrementalAxisWordUtil</span></div>
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
<dl class="typelist inheritedMembers">
|
|
<dt>Inherited Members</dt>
|
|
<dd>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object)">object.Equals(object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object-system-object)">object.Equals(object, object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.gethashcode">object.GetHashCode()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.gettype">object.GetType()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone">object.MemberwiseClone()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.referenceequals">object.ReferenceEquals(object, object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.tostring">object.ToString()</a>
|
|
</div>
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h2 class="section" id="fields">Fields
|
|
</h2>
|
|
|
|
|
|
|
|
<h3 id="Hi_NcParsers_ParsingSyntaxs_Heidenhain_HeidenhainIncrementalAxisWordUtil_Prefix" data-uid="Hi.NcParsers.ParsingSyntaxs.Heidenhain.HeidenhainIncrementalAxisWordUtil.Prefix">
|
|
Prefix
|
|
|
|
</h3>
|
|
|
|
<div class="markdown level1 summary"><p>The klartext incremental prefix letter.</p>
|
|
</div>
|
|
<div class="markdown level1 conceptual"></div>
|
|
|
|
<div class="codewrapper">
|
|
<pre><code class="lang-csharp hljs">public const string Prefix = "I"</code></pre>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<h4 class="section">Field Value</h4>
|
|
<dl class="parameters">
|
|
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
|
|
<dd></dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<h2 class="section" id="methods">Methods
|
|
</h2>
|
|
|
|
|
|
<a id="Hi_NcParsers_ParsingSyntaxs_Heidenhain_HeidenhainIncrementalAxisWordUtil_GrabIncrementalAxisWords_" data-uid="Hi.NcParsers.ParsingSyntaxs.Heidenhain.HeidenhainIncrementalAxisWordUtil.GrabIncrementalAxisWords*"></a>
|
|
|
|
<h3 id="Hi_NcParsers_ParsingSyntaxs_Heidenhain_HeidenhainIncrementalAxisWordUtil_GrabIncrementalAxisWords_System_Text_Json_Nodes_JsonObject_System_Text_Json_Nodes_JsonObject_System_Collections_Generic_IEnumerable_System_String__System_String__System_Collections_Generic_IEnumerable_System_String__" data-uid="Hi.NcParsers.ParsingSyntaxs.Heidenhain.HeidenhainIncrementalAxisWordUtil.GrabIncrementalAxisWords(System.Text.Json.Nodes.JsonObject,System.Text.Json.Nodes.JsonObject,System.Collections.Generic.IEnumerable{System.String},System.String@,System.Collections.Generic.IEnumerable{System.String})">
|
|
GrabIncrementalAxisWords(JsonObject, JsonObject, IEnumerable<string>, ref string, IEnumerable<string>)
|
|
|
|
</h3>
|
|
|
|
<div class="markdown level1 summary"><p>Grabs every I-prefixed incremental word of <code class="paramref">axisTags</code>
|
|
from <code class="paramref">unparsedText</code>, writes each value under its
|
|
plain axis key of the object at <code class="paramref">sectionPath</code> below
|
|
<code class="paramref">parsing</code> (parsed via
|
|
<a class="xref" href="Hi.NcParsers.ParsingSyntaxs.FloatTagValueSyntax.html#Hi_NcParsers_ParsingSyntaxs_FloatTagValueSyntax_ToFloat_System_String_">ToFloat(string)</a>, like the absolute words)
|
|
and stamps an <a class="xref" href="Hi.NcParsers.Keywords.Positioning.html#Hi_NcParsers_Keywords_Positioning_Incremental">Incremental</a> entry per axis
|
|
into the block-root <a class="xref" href="Hi.NcParsers.Keywords.PositioningOverride.html">PositioningOverride</a>
|
|
section of <code class="paramref">block</code>. No words → nothing is written
|
|
(no empty override section appears).</p>
|
|
</div>
|
|
<div class="markdown level1 conceptual"></div>
|
|
|
|
<div class="codewrapper">
|
|
<pre><code class="lang-csharp hljs">public static void GrabIncrementalAxisWords(JsonObject block, JsonObject parsing, IEnumerable<string> sectionPath, ref string unparsedText, IEnumerable<string> axisTags)</code></pre>
|
|
</div>
|
|
|
|
<h4 class="section">Parameters</h4>
|
|
<dl class="parameters">
|
|
<dt><code>block</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.text.json.nodes.jsonobject">JsonObject</a></dt>
|
|
<dd><p>Block-root JSON object (owner of the override section).</p>
|
|
</dd>
|
|
<dt><code>parsing</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.text.json.nodes.jsonobject">JsonObject</a></dt>
|
|
<dd><p>The block's <a class="xref" href="Hi.NcParsers.Keywords.IParsingDef.html#Hi_NcParsers_Keywords_IParsingDef_Parsing">Parsing</a> object.</p>
|
|
</dd>
|
|
<dt><code>sectionPath</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable</a><<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a>></dt>
|
|
<dd><p>Path below <code class="paramref">parsing</code> that receives the axis values (empty = the Parsing root).</p>
|
|
</dd>
|
|
<dt><code>unparsedText</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
|
|
<dd><p>Block text; the grabbed words are removed.</p>
|
|
</dd>
|
|
<dt><code>axisTags</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable</a><<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a>></dt>
|
|
<dd><p>Plain axis tags to look for behind the prefix (the caller's own tag list).</p>
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</article>
|
|
|
|
<div class="contribution d-print-none">
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
<div class="affix">
|
|
<nav id="affix"></nav>
|
|
</div>
|
|
</main>
|
|
|
|
<div class="container-xxl search-results" id="search-results"></div>
|
|
|
|
<footer class="border-top text-secondary">
|
|
<div class="container-xxl">
|
|
<div class="flex-fill">
|
|
<span> Copyright © 2025 <a href='https://superhightech.com.tw'>Tech Coordinate</a>. All rights reserved. <a href='https://superhightech.com.tw'>超級高科技股份有限公司</a> © 2025 版權所有 </span>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
</body>
|
|
</html>
|