Table of Contents

Class HeidenhainPlaneSyntax

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

Syntax for the Heidenhain PLANE statement family. Fully structured (simulated by the Logic-stage tilt consumer):

  • PLANE RESET [STAY|MOVE|TURN]
  • PLANE SPATIAL SPA SPB SPC [SEQ±] [COORD ROT|TABLE ROT] [MOVE [DIST..] [F..]|TURN|STAY]
Recognized (captured with the same option set, simulated as recognized-but-not-simulated by the Logic consumer):
  • PLANE PROJECTED PROPR PROMIN ROT ...
  • PLANE VECTOR BX BY BZ NX NY NZ ... (corpus: 1.H)
  • PLANE EULER/POINTS/RELATIV/AXIAL ... — the mode word is captured and the unmodeled argument text is swept verbatim into the record's Args so no token can leak to the shared tag captures (e.g. a PLANE AXIAL B+45 B word must never become a rotary axis move).
Must run before the shared F tag-value syntax: the F of MOVE DIST100 F8000 is the repositioning feed and would otherwise pollute the modal feedrate (house.H corpus form; HardNc has exactly this defect).
public class HeidenhainPlaneSyntax : ISituNcSyntax, INcSyntax, IMakeXmlSource
Inheritance
HeidenhainPlaneSyntax
Implements
Inherited Members
Extension Methods

Examples

#BeforeBuild.UnparsedText: PLANE SPATIAL SPA+30 SPB+0 SPC-10 SEQ+ COORD ROT TURN #AfterBuild:

{
  "Parsing": {
    "PLANE": {
      "Mode": "SPATIAL",
      "SPA": 30, "SPB": 0, "SPC": -10,
      "SEQ": "+", "Rot": "COORD", "Positioning": "TURN"
    }
  }
}

#BeforeBuild.UnparsedText: PLANE PROJECTED PROPR+30 PROMIN+0 ROT+45 SEQ- TABLE ROT MOVE #AfterBuild:

{
  "Parsing": {
    "PLANE": {
      "Mode": "PROJECTED",
      "PROPR": 30, "PROMIN": 0, "ROT": 45,
      "SEQ": "-", "Rot": "TABLE", "Positioning": "MOVE"
    }
  }
}

#BeforeBuild.UnparsedText: PLANE RESET STAY #AfterBuild:

{
  "Parsing": {
    "PLANE": { "Mode": "RESET", "Positioning": "STAY" }
  }
}

The house.H MOVE form — DIST is glued to its value and the F is the repositioning feed (claimed here, kept out of the modal feedrate): #BeforeBuild.UnparsedText: PLANE SPATIAL SPA+0 SPB-45 SPC+0 MOVE DIST100 F8000 COORD ROT #AfterBuild:

{
  "Parsing": {
    "PLANE": {
      "Mode": "SPATIAL",
      "SPA": 0, "SPB": -45, "SPC": 0,
      "Rot": "COORD", "Positioning": "MOVE",
      "DIST": 100, "F": 8000
    }
  }
}

The TongTai turbine form — SEQ- glued to TABLE: #BeforeBuild.UnparsedText: PLANE SPATIAL SPA-77.516 SPB+0 SPC-10.365 STAY SEQ-TABLE ROT #AfterBuild:

{
  "Parsing": {
    "PLANE": {
      "Mode": "SPATIAL",
      "SPA": -77.516, "SPB": 0, "SPC": -10.365,
      "SEQ": "-", "Rot": "TABLE", "Positioning": "STAY"
    }
  }
}

PLANE VECTOR (1.H corpus form) — base and normal vectors captured: #BeforeBuild.UnparsedText: PLANE VECTOR BX1 BY0 BZ0 NX0 NY0 NZ1 STAY SEQ+ TABLE ROT #AfterBuild:

{
  "Parsing": {
    "PLANE": {
      "Mode": "VECTOR",
      "BX": 1, "BY": 0, "BZ": 0, "NX": 0, "NY": 0, "NZ": 1,
      "SEQ": "+", "Rot": "TABLE", "Positioning": "STAY"
    }
  }
}

Unmodeled mode — the argument text is swept into Args so no token leaks: #BeforeBuild.UnparsedText: PLANE AXIAL B+45 TURN #AfterBuild:

{
  "Parsing": {
    "PLANE": { "Mode": "AXIAL", "Positioning": "TURN", "Args": "B+45" }
  }
}

Constructors

HeidenhainPlaneSyntax()

Initializes a new instance with default settings.

public HeidenhainPlaneSyntax()

HeidenhainPlaneSyntax(XElement)

Initializes a new instance by deserializing from the given XML element.

public HeidenhainPlaneSyntax(XElement src)

Parameters

src XElement

Source XML element.

Fields

ArgsKey

Record key holding the swept argument text of unmodeled PLANE modes.

public const string ArgsKey = "Args"

Field Value

string

KeyConst

Key of the record written to Parsing.

public const string KeyConst = "PLANE"

Field Value

string

ModeKey

Record key for the mode word (SPATIAL/RESET/VECTOR/...).

public const string ModeKey = "Mode"

Field Value

string

PositioningKey

Record key for the positioning word (“MOVE”/“TURN”/“STAY”).

public const string PositioningKey = "Positioning"

Field Value

string

ProjectedTagList

Projected tags for PLANE PROJECTED command. PROPR: projection angle, PROMIN: minimum angle, ROT: rotation of tilted plane.

public static readonly string[] ProjectedTagList

Field Value

string[]

RotKey

Record key for the rotation strategy (“COORD” or “TABLE”).

public const string RotKey = "Rot"

Field Value

string

SeqKey

Record key for the SEQ solution preference ("+" or "-").

public const string SeqKey = "SEQ"

Field Value

string

SpatialTagList

Spatial axis tags for PLANE SPATIAL command.

public static readonly string[] SpatialTagList

Field Value

string[]

UnmodeledModeList

PLANE modes captured as recognized-but-unmodeled: the mode word is recorded and the remaining argument text is swept into ArgsKey.

public static readonly string[] UnmodeledModeList

Field Value

string[]

VectorTagList

Base-vector and normal-vector tags for PLANE VECTOR command.

public static readonly string[] VectorTagList

Field Value

string[]

Properties

Name

Syntax kind name (typically the concrete type name).

public string Name { get; }

Property Value

string

XName

XML element name used to register this syntax with XFactory.

public static string XName { get; }

Property Value

string

Methods

Build(LazyLinkedListNode<SyntaxPiece>, List<INcDependency>, NcDiagnosticProgress)

Build syntax arrangement into the syntaxPieceNode in-place.

public void Build(LazyLinkedListNode<SyntaxPiece> syntaxPieceNode, List<INcDependency> ncDependencyList, NcDiagnosticProgress ncDiagnosticProgress)

Parameters

syntaxPieceNode LazyLinkedListNode<SyntaxPiece>
ncDependencyList List<INcDependency>
ncDiagnosticProgress NcDiagnosticProgress

MakeXmlSource(string, string, bool)

Creates an XML representation of the object. This method may also generate additional resources such as related files.

public XElement MakeXmlSource(string baseDirectory, string relFile, bool exhibitionOnly)

Parameters

baseDirectory string

The base directory for resolving relative paths

relFile string

The relative file path for the XML source

exhibitionOnly bool

if true, the extended file creation is suppressed.

Returns

XElement

An XML element representing the object's state

Remarks

For the demand of easy moving source folder (especially project folder) without configuration file path corruption, the relative file path is applied. The baseDirectory is typically the folder at the nearest configuration file folder. Since the folder can be moving with the configuration file.

Reg(XFactory)

Registers this type's deserializer with the given XFactory (or Default when factory is null). Idempotent.

public static void Reg(XFactory factory = null)

Parameters

factory XFactory