Interpreter settings file

The settings file has SNCI (Sprut Numerical Control Interpreter) extension and XML format. The description of its elements is given below. Required parameters are marked with a sign in the corresponding column.


Description of the SNCI file elements

Element name

Field format

Description

Required

1

NCInterpreter

Tag

Root element

*

2

CNCSystem

String

Name of stand / machine

3

MachineType

String

Machine type. Variations:

  • Lathe

  • Mill

  • TurnMill

  • Robots

  • WireEDM

4

UseGeomCLData

Logical

Specifies the use of the interface of the tool motion path construction in geometric axes (Logical).

True - is that the INCT_GeomCLData interface is passed to the interpreter to form the trajectory of the tool movement from SprutCAM.

False - the INCT_CLData interface is passed to the interpreter to form the trajectory of the tool movement from SprutCAM.

The default value is False.


5

Date

Date

Interpreter date in dd.mm.yyyy format

6

Authors

String

Developer(-s)

7

Company

String

Company

8

Description

String

Description

9

Version

Number

Version

*

10

ID

GUID

Interpreter ID (must be unique)

*

11

LibraryID

GUID

Software library ID (must be unique)

*

12

LibraryFileName_Net

String

Link to the software library for the .NET platform

**

13

NetNamespaceClass

String

Namespace and name of the class that implements the interpreter (if the LibraryFileName_Net field is filled)

***

14

LibraryFileName_x32

String

Link to x32 software library (used if the LibraryFileName_Net field is not filled)

**

15

LibraryFileName_x64

String

Link to x64 software library (used if the LibraryFileName_Net field is not filled)

**

16

ParentID

GUID

Parent Interpreter ID (ID field in parent SNCI file)

*

17

ParentFileName

String

Link to the parent interpreter settings file (SNCI file)

*

18

FileExtension

String

File extension with NC code

*

19

Registers

Tag

List of interpreter registers

*

* - required field;

** - the LibraryFileName_Net field or both fields LibraryFileName_x32, LibraryFileName_x64 must be filled;

*** - the field must be filled in if the LibraryFileName_Net field is filled.


Description of each item from the register list (Registers):

Element name

Field format

Description

1

Address

String

Register address

2

Name

String

Register name

3

Id

String

Register ID

4

Comment

String

Comment

5

AddrOnly

String

Value options:

  • aoValue - The NC word consists only of the address and meaning

  • aoAddr - The NC word consists only of the address

  • aoBoth - The NC word that can consist of both an address and an address and value.

6

Sign

Integer

Value sign:

  • 0 - without sign

  • 1 - only '-'

  • 2 - '+' and '-'

7

NumeralsBeforePoint.Count

Integer

Characters to the point

8

NumeralsBeforePoint.Zeros

Boolean

Presence of leading zeros

9

DecimalPoint

Integer

Decimal point:

  • 0 - without '.'

  • 1 - '.'

  • 2 - always '.'

10

NumeralsAfterPoint.Count

Integer

Characters after the point

11

NumeralsAfterPoint.Zeros

Boolean

Trailing zeros

12

Scale

Number

Scale

13

Modal

Boolean

Sign of register modality

14

ModalGroupList

List of values

The list of values that can get the register


The Version field is reserved for future use.

Important elements of the interpreter's settings file are: its own identifier (ID), identifier (LibraryID) and link to .NET / x32 / x64 version software library files (LibraryFileName_*), identifier (ParentID) and link to parent interpreter (ParentFileName). The identifiers of the settings file and the program library must be unique (see the GUID article: Globally Unique Identifier).

The LibraryFileName_* field should point to files, with a program library, relative to the directory where the SNCI file is located. It is recommended to place the file with the program library in the directory with the SNCI file.

There are two options for connecting the program library to SprutCAM:

  1. The software library is designed for the .NET platform (for example, in C #).
    In this case, you must fill in the LibraryFileName_Net and NetNamespaceClass fields, where:
    LibraryFileName_Net - link to the program library.
    NetNamespaceClass is a namespace and class that implements the interface of interaction with the interpreter. Format: Namespace.Class, for example: sample.Interpreter.

  2. The program library is native (written in Delphi, C ++, etc.)
    In this case, the LibraryFileName_x32 and LibraryFileName_x64 fields should be filled in (reference to the x32 / x64 program library, respectively).Versions of the x32 / x64 software library should be called by the same name, but with different prefixes. For example: Sample_x32.dll / Sample_x64.dll or Sample_Win32.dll / Sample_Win64.dll. Where "Sample" is the name of the program library.

If the interpreter is not the inheritor of another interpreter, then the parent fields are filled with empty values:

<ParentID>{00000000-0000-0000-0000-000000000000}</ParentID>

<ParentFileName/>

The FileExtension field is reserved for future use.

In the Registers field is a list of registers for automatic selection of words from the NC code. The order of transmission of the control program frame is described in the following article. The interpreter configuration file may be not complete list of registers, it will be received by the interpreter program library, however tag <Registers/> must be attend.

The use of the interpreter settings file is given in the G-code based program interpretation section.


An example of the interpreter settings file for the native library (x32/x64):


<?xml version="1.0" encoding="UTF-8" ?>
<NCInterpreter>

<CNCSystem>Sample CNC (mill)</CNCSystem>
<MachineType>Mill</MachineType>
<Date>01.01.2019</Date>
<Authors>Ivan Danko</Authors>
<Company>SprutCAM Tech</Company>
<Description>Interpreter for Sample CNC</Description>
<Version>1</Version>
<ID>{79B1410C-67D5-42B6-867B-A3BF30AB3D8A}</ID>
<LibraryID>{80F754D9-EE7B-47CF-A802-A9424D9F6749}</LibraryID>
<LibraryFileName_x32>Sample_x32.dll</LibraryFileName_x32>
<LibraryFileName_x64>Sample_x64.dll</LibraryFileName_x64>
<ParentID>{00000000-0000-0000-0000-000000000000}</ParentID>
<ParentFileName/>
<FileExtension>*.cnc</FileExtension>
<Registers/></NCInterpreter>

download example Sample.snci.