Configuration Desk Syntax TRCfile
Configuration Desk Syntax TRCfile
If possible, always provide the serial number of the hardware, the relevant dSPACE License
ID, or the serial number of the CmContainer in your support request.
Important Notice
This publication contains proprietary information that is protected by copyright. All rights
are reserved. The publication may be printed for personal or internal use provided all the
proprietary markings are retained on all printed copies. In all other cases, the publication
must not be copied, photocopied, reproduced, translated, or reduced to any electronic
medium or machine-readable form, in whole or in part, without the prior written consent
of dSPACE GmbH.
This publication and the contents hereof are subject to change without notice.
Contents
Keywords............................................................................................................... 14
_author......................................................................................................... 15
_description.................................................................................................. 15
_floating_point_type()................................................................................... 16
_gendate.......................................................................................... ............ 16
_genname..................................................................................................... 17
_genversion...................................................................................... ............ 17
_integer_type().............................................................................................. 18
_model............................................................................................. ............ 18
endgroup...................................................................................................... 18
endstruct.......................................................................................... ............ 19
enum............................................................................................................ 20
group............................................................................................................ 20
sampling_period[daq_raster_index]............................................................... 21
struct............................................................................................................ 22
typedef......................................................................................................... 23
3
May 2024 ConfigurationDesk Syntax of the TRC File
Contents
refelem......................................................................................................... 33
refgroup........................................................................................................ 35
refvar............................................................................................................ 36
scale................................................................................................. ............ 36
scaleback...................................................................................................... 37
type (Data Type, Data Format and Type Definition)......................................... 37
unit............................................................................................................... 41
value............................................................................................................. 41
Index 43
4
ConfigurationDesk Syntax of the TRC File May 2024
About This Document
Objective If you use custom code, the variables in it are initially not accessible to
the experiment software. To make the global variables accessible, you must
provide an additional variable description file. When writing a user variable
description file, you must use the syntax described in this document, and name
it <model>_usr.trc. During the build process, the user file is inserted into
the main variable description file. It must be created before the build process is
started. It has to be located in the working folder of the behavior model. You can
write variable description files also for each referenced model in your behavior
model.
Symbol Description
Indicates a hazardous situation that, if not avoided,
V DANGER
will result in death or serious injury.
Indicates a hazardous situation that, if not avoided,
V WARNING could result in death or serious injury.
Indicates a hazardous situation that, if not avoided,
V CAUTION could result in minor or moderate injury.
Indicates a hazard that, if not avoided, could result in
NOTICE
property damage.
Indicates important information that you should take
Note
into account to avoid malfunctions.
Indicates tips that can make your work easier.
Tip
Indicates a link that refers to a definition in the
glossary, which you can find at the end of the
document unless stated otherwise.
Follows the document title in a link that refers to
another document.
Naming conventions dSPACE user documentation uses the following naming conventions:
5
May 2024 ConfigurationDesk Syntax of the TRC File
About This Document
Special Windows folders Windows‑based software products use the following special folders:
Accessing dSPACE Help and After you install and decrypt Windows‑based dSPACE software, the
PDF files documentation for the installed products is available in dSPACE Help and as PDF
files.
dSPACE Help (local) You can open your local installation of dSPACE Help:
§ On its home page via Windows Start Menu
§ On specific content using context-sensitive help via F1
PDF files You can access PDF files via the icon in dSPACE Help. The PDF
opens on the first page.
6
ConfigurationDesk Syntax of the TRC File May 2024
Syntax of the TRC File
Introduction The TRC file provides information on the variables of a real‑time application
that is required to connect variables to instruments in a ControlDesk layout,
for example. It is an ASCII file that can either be generated automatically by
ConfigurationDesk, or written manually.
Note
If you write a TRC file manually, you must adhere to the syntax of the TRC
file. Then, you can easily switch from a simulation on the Simulink platform
to an application running on a dSPACE real‑time board.
TRC file syntax To structure variables, for example, in the Variable Browser of ControlDesk, you
can divide all model variables into hierarchical levels of subgroups. This feature is
called grouping, see Grouping on page 9.
Refer to the following sections for information on the syntax elements of a TRC
file:
§ Keywords on page 14
§ Variable Names on page 11
§ Variable and Group Properties on page 25
§ Comments on page 11
Error file If you write your own TRC file incorrectly, an Error file is generated when you
download the corresponding application: see Error File on page 12. Use this file
to correct your own TRC file.
7
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
Keywords................................................................................................ 14
8
ConfigurationDesk Syntax of the TRC File May 2024
Principles of the TRC File
Grouping................................................................................................... 9
Variable Names........................................................................................ 11
Comments.............................................................................................. 11
Error File.................................................................................................. 12
Grouping
Defining groups For large real‑time applications with numerous variables, it is useful to arrange
these variables into several groups. To define a group, enclose the corresponding
variables in the keywords group and endgroup. Nesting group – endgroup
statements allows you to create multilevel tree structures. An endgroup
statement always belongs to the most recent group statement. Variables that
are declared between these statements belong to this group and will be listed in
the Variable List of the corresponding browser node.
Naming of groups The keyword group must be followed by a name enclosed in quotation marks
(“…”). If quotation marks are used in the string, they must appear twice. The
name must be of the same format as described in alias on page 28. If two
successive slashes occur in a name (//), they are transformed into a single one.
Note
Example The following extract is taken from the smd_xxxx_hc.trc file found in the
ControlDesk demo project, that is available as backup file in
<RCP_HIL_InstallationPath>\Demos\dsxxxx\GettingStarted\HandCode
.
9
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
group "Model"
x_disp flt
f flt
x flt
v flt
a flt
group "Model Parameters"
d flt
c flt
m flt
endgroup
endgroup
Note
At the end of the TRC file an empty line has to be inserted to avoid an error
message caused by the TRC file parser.
Appearance of groups In ControlDesk's Variables controlbar, for example, a group will appear as a
in ControlDesk's node (unless the node has the flag HIDDEN, see flags on page 31).
Variables controlbar
Keywords................................................................................................................................. 14
Variable and Group Properties.................................................................................................. 25
Variable Names......................................................................................................................... 11
References
Comments............................................................................................................................... 11
10
ConfigurationDesk Syntax of the TRC File May 2024
Principles of the TRC File
Variable Names
Variable names The name of the variable can be a scalar or an array and is limited to a
maximum of 4096 characters. The name (or its alias) will appear in ControlDesk's
Variables controlbar, for example. The name of the variable must be identical
to the name of the corresponding global variable of the real‑time program.
Variables declared as static cannot be accessed, for example by ControlDesk,
unless their address is explicitly given in the TRC file because such variables do
not appear in the MAP file. If a variable is not defined in <model>.c, the line in
the TRC file is accepted only if the absolute address is given.
Note
Example X[0]
{
type: flt
}
Grouping.................................................................................................................................... 9
Keywords................................................................................................................................. 14
Variable and Group Properties.................................................................................................. 25
References
alias.......................................................................................................................................... 28
Comments
Syntax of a comment TRC files may contain comments. Initial double minus characters –– declare a line
in the TRC file as a comment.
Note
11
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
Grouping.................................................................................................................................... 9
Keywords................................................................................................................................. 14
Variable and Group Properties.................................................................................................. 25
Variable Names......................................................................................................................... 11
Error File
Error messages The experiment software parses the TRC file together with the Linker MAP file. If
you write your own TRC file incorrectly, an error message will be displayed, for
example, when you download the corresponding application.
Error Description
Syntax error
identifier expected A line must begin with a name or a keyword; a group instruction must
be followed by a name.
type, [or expected An identifier can only be followed by the given symbols.
type expected Array declarations must be followed by a type.
number expected A type can only be followed by an address or a comment.
illegal numeric format Illegal syntax used for a numeric value (decimal or hex with a leading 0x
or a trailing h).
float number expected A floating-point number is expected, either in absolute or exponential
format.
extra characters Superfluous characters given; maybe a comment without --.
] expected A right bracket is expected.
string exceeds end of line (" expected) The terminating quotes of a string could not be found; multi-line strings
are not allowed.
endgroup missing Each group statement requires a matching endgroup statement.
illegal endgroup There is no matching group statement for the endgroup statement.
groupname must not be empty The matching group statement must be followed by a group name in
" ", or the description block must contain an alias statement.
filename is empty The keyword _application must be followed by a string constant that
contains a file name.
keyword _application must not occur The keyword _application may occur only once in the TRC file.
multiple
illegal data size The data size can only be 32-bit or 64-bit (TI floating-point data
format can only be 32-bit).
illegal data format The data format can only be TI or IEEE.
12
ConfigurationDesk Syntax of the TRC File May 2024
Principles of the TRC File
Error Description
illegal index or array declaration An array must be defined in one of the following formats:
1. [2]
2. [4.6]
unexpected symbol A symbol does not fit the TRC file structure.
illegal use of keyword A keyword was not expected to be on its position.
string constant expected The keyword _application must be followed by a string constant.
Semantic error
invalid index range The first index of an array declaration is higher than the last one.
group already defined A group name must not occur multiple times in the same subgroup.
13
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
Keywords
Introduction In TRC files different keywords are used to store information on the TRC file and
structure the contents.
Rules for keywords Each keyword is optional and is followed by a string containing the
corresponding value. If a keyword definition appears more than once in a TRC
file, the latest definition will be applied.
Note
_author................................................................................................... 15
To indicate the name of the author creating the model.
_description............................................................................................. 15
To give additional information on the model.
_floating_point_type()............................................................................. 16
To set a new default size for floating‑point variables (flt, float).
_gendate................................................................................................. 16
To indicate the date and time when the TRC file was created.
_genname............................................................................................... 17
To indicate the name of the tool generating the TRC file.
_genversion............................................................................................. 17
To indicate the version of the tool generating the TRC file.
_integer_type()........................................................................................ 18
To set a new default size for integer variables (int) and unsigned integer
variables (uint).
_model.................................................................................................... 18
To indicate the name of the model.
endgroup................................................................................................ 18
To indicate the end of a subgroup.
14
ConfigurationDesk Syntax of the TRC File May 2024
Keywords
endstruct................................................................................................. 19
To indicate the end of a structure data type.
enum...................................................................................................... 20
To define enumeration values.
group...................................................................................................... 20
To define a group.
sampling_period[daq_raster_index].......................................................... 21
To specify a DAQ raster for data capturing
struct....................................................................................................... 22
To define a structure data type.
typedef.................................................................................................... 23
To define a new customized datatype.
_author
Description This keyword is used to indicate the name of the model’s author. The keyword is
case sensitive. The entire name must be enclosed in quotation marks (“…”).
_description
Description This keyword can be used to describe the model more precisely or to add further
information. The keyword is case sensitive. The entire value must be enclosed in
quotation marks (“…”).
15
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
_floating_point_type()
Purpose To set a new default size for floating‑point variables (flt, float).
Description By default all types are evaluated as 32‑bit variables, and floating‑point values are
supposed to be defined in the Texas Instruments format.
Note
_gendate
Purpose To indicate the date and time when the TRC file was created.
16
ConfigurationDesk Syntax of the TRC File May 2024
Keywords
Description This keyword is used to indicate the date and time when the TRC file was
created. The keyword is case sensitive. The entire value must be enclosed in
quotation marks (“…”).
_genname
Purpose To indicate the name of the tool generating the TRC file.
Description This information is useful when the format of any of the blocks used in the
real‑time application has to be ascertained. The keyword is case sensitive. The
entire value must be enclosed in quotation marks (“…”).
_genversion
Purpose To indicate the version of the tool generating the TRC file.
Description If the TRC file is generated automatically, this keyword indicates the version
number of the generating tool. The keyword is case sensitive. The entire value
must be enclosed in quotation marks (“…”).
17
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
_integer_type()
Syntax _integer_type(size)
Purpose To set a new default size for integer variables (int) and unsigned integer variables
(uint).
Description The keyword _integer_type changes the default size (32‑bit) of all variables
defined as int, int* or uint, uint*. The size can be set to 8‑bit, 16‑bit,
32‑bit or 64‑bit. This value follows the keyword enclosed in parentheses.
The scope of _integer_type ranges from its current position within the TRC
file until the end of file or until another _integer_type occurs.
Example _integer_type(64)
_model
Description This keyword is used to indicate the name of the model and is case sensitive. The
entire value must be enclosed in quotation marks ("…").
endgroup
Syntax endgroup
18
ConfigurationDesk Syntax of the TRC File May 2024
Keywords
Description The keyword endgroup is used to close a group. Refer to Grouping on page 9.
Example ...
endgroup
group....................................................................................................................................... 20
endstruct
Syntax endstruct
Description The keyword endstruct is used to close a structure definition in a TRC file.
Example ...
endstruct
struct........................................................................................................................................ 22
19
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
enum
Description Enums specified in MATLAB/Simulink are generated into the Variable Description
File and can be used for experimentation.
The definition of the myLED variable using the enum data type:
myLED
{
type: enum LEDState
alias: "myLED"
flags: PARAM
}
group
20
ConfigurationDesk Syntax of the TRC File May 2024
Keywords
Description The keyword group is used as an initialization command of a group in a TRC file.
For example, in ControlDesk's Variables controlbar, this group will appear as a
node. For further information please refer to Grouping on page 9.
endgroup................................................................................................................................. 18
sampling_period[daq_raster_index]
Syntax sampling_period[daq_raster_index]
{
value:
alias:
unit:
}
Description To measure variables (e.g., task information variables) stored in the TRC file
synchronously with a task, for example, in dSPACE's ControlDesk, the DAQ
raster must be enabled for that task. The sample time of the task defines the
measurement raster or DAQ raster, respectively.
A real-time application can have up to 31 tasks that have their DAQ raster
enabled. A task's DAQ raster is enabled if the DAQ raster name field is not
empty. For each DAQ raster one sampling_period[daq_raster_index] entry
is located in the TRC file. The daq_raster_index entry represents the DAQ
raster number minus 1. The index is automatically assigned during the build
process.
The alias specifies a more intuitive name for the task. Refer to the DAQ raster
name parameter of the task.
21
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
The value/unit pair represents the measurement raster. The value can be:
§ The sample time of the task, if the DAQ raster is located in a periodic task.
§ 0.0, if the DAQ raster is located in an asynchronous task
Note
Example In a TRC file generated by ConfigurationDesk, the entry for the sampling period
for a DAQ raster may look like this:
sampling_period[0]
{
value: 0.001
alias: "Periodic Task 1"
unit: "s"
}
sampling_period[1]
{
value: 0.01
alias: "Periodic Task 2"
unit: "s"
}
struct
22
ConfigurationDesk Syntax of the TRC File May 2024
Keywords
Note
If you manually create a User TRC file, you must set the values for offs and
array‑incr to ‑1. During the TRC file generation, these values are replaced
according to the variable addresses.
endstruct.................................................................................................................................. 19
typedef
Description The keyword is followed by the new datatype name, the datatype being used
and, enclosed in brackets, the number of elements being created. The keyword is
case sensitive. The following example creates a 5 x 5 matrix.
23
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
Note
Variables using datatypes that are not allowed are removed while the MAP
file is parsed. For example, on DSP base hardware, the data types Int8 and
Int16 are not supported and therefore not allowed.
Defining C code structures by means of this keyword is not possible.
24
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
Variable and group properties For information on the naming of variables and groups, refer to Variable Names
on page 11.
Note
Example
Scalexio_PWM_PFM_In_1_MinimumFrequency
{
type: flt(64,IEEE)
alias: "Minimum frequency"
flags: PARAM
range: <0.003424; 3676470.0>
value: 1.0
desc: "For further information refer to online help..."
}
Several property blocks For each signal, several property blocks can be defined. Make sure that the
alias names used for these blocks are unambiguous. Defining several property
blocks is useful whenever a signal should be observed with different data types.
Example The following example shows how the signal myUnion can be made
accessible both as an integer value and as a float value for experiment software.
myUnion
{
alias: "Output as int"
type: int
…
}
myUnion
{
alias: "Output as float"
type: float
…
}
25
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
addr........................................................................................................ 27
To specify the memory address of a variable that is not accessible via the
MAP file.
alias......................................................................................................... 28
To define a more intuitive name for a variable.
array-incr................................................................................................. 29
To specify the memory size in bytes of the related structure.
bitmask................................................................................................... 30
To mask bits of the signal value.
block....................................................................................................... 30
To describe the blocktype of a Simulink block.
default.................................................................................................... 30
To specify the default value for a signal.
desc........................................................................................................ 31
To describe a signal or a group.
flags........................................................................................................ 31
To describe special properties of a signal.
increment................................................................................................ 32
To specify the unit increment for a task.
offs......................................................................................................... 32
To specify the offset of a field definition in a structure in bytes.
origin...................................................................................................... 33
To specify the entire path of signals, parameters and blocks.
range...................................................................................................... 33
To define the valid range for the signal value variation.
refelem.................................................................................................... 33
To specify a field in a structure or an element in an array that is used as
reference.
refgroup.................................................................................................. 35
To specify the group name of a variable reference.
refvar...................................................................................................... 36
To specify the variable name of a reference.
scale........................................................................................................ 36
To convert the signal value.
scaleback................................................................................................. 37
To reverse the scale function.
26
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
unit......................................................................................................... 41
To set the physical unit for a signal value.
value....................................................................................................... 41
To specify the current value for a signal.
addr
Purpose To specify the memory address of a variable that is not accessible via the MAP
file.
Description If a variable is allocated to an absolute address outside the scope of the linker
(for example, in dual‑port memory) this variable does not appear in the MAP
file. However, it can be made accessible, for example, for ControlDesk, if the
base address of this variable is known. Therefore, this address in the real‑time
processor's memory has to be entered.
Note
Note
Arbitrary array subranges can be referenced in TRC files as shown below. Each
array element is treated, for example, by ControlDesk, as a separate variable.
27
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
Array indices in TRC files as well as in C programs always start at zero. The
variable rtB[3] is equal to the fourth element of that array.
Although only the base address has to be given, the offset of the variable’s
address will be calculated automatically. For example:
rtB[3]
{
type: flt
alias: "Element with index 3"
addr: 0x00000010
}
The following type of declaration must be used to access arrays that were
allocated during run time by function calls to malloc() or calloc(). For
example:
x_dot[0..3]
{
type: float *
alias: "Array access"
}
Note
alias
Description This property can be used to set the alias name of a variable (array element
or scalar variable) that has already been defined in order to provide the variable
with a more intuitive name. A string begins and ends with quotation marks (").
Example X[0]
{
alias: "rpm"
addr: 0x805000
…
}
28
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
If two successive slashes occur in a name (//), they are transformed into a single
one. If quotation marks are used in the string, they must appear twice.
Note
§ The alias name must defined within the braces of the corresponding
variable. The variable cannot be renamed in another property block.
§ Alias names are limited to a maximum of 128 characters.
array-incr
Description In a user TRC file, the array increment is to be specified by ‑1. During the build,
the value is replaced according to the platform‑specific variable addresses. This
property is mandatory and valid only for structure definitions.
29
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
bitmask
Description This property provides bit access to the signal value. The least significant bit is
defined as bit number 0.
block
Description This property can only be assigned to nodes. For example, it stores the type of a
Simulink block that is represented by this node.
default
Description This property specifies the default value for a signal, which can automatically
be displayed, for example, in a ControlDesk instrument. The permissible values
30
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
depend on the type of the signal. String values must be enclosed in quotation
marks (").
desc
flags
Description This field contains flags describing special properties of the signal. Flags can be
combined and also be set to variables or blocks.
Flag Purpose
HIDDEN To hide a node in ControlDesk's Variables controlbar.
OUTPUT To mark block outputs.
PARAM To mark a variable as a parameter.
READONLY To make a variable read‑only. The variable cannot be written.
DEPRECATED To mark an item as deprecated.
31
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
increment
Description The increment value corresponds to the sampling period of the model.
offs
Description In a user TRC file, the offset is to be specified by ‑1. During the build, the value
is replaced according to the platform‑specific variable addresses. This property is
mandatory and valid only for struct elements.
32
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
origin
Description In TRC files generated by ConfigurationDesk, this property is used for signal
labels to indicate the path of the corresponding signal in the Simulink model.
range
Purpose To define the valid range for the signal value variation.
Description Integer, floating point and exponential numbers are possible for min and max.
Use the keyword inf to define an infinite limiting value.
refelem
Description If the refvar property references a structure or an array, the refelem property
specifies the concrete element to be used as a reference.
33
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
A nested structure is described with dots as path delimiters. The path must then
also start with a dot.
For an array element, only the index of the element is given in square brackets.
The name of the array is specified in the related refvar property.
pointStructVar
{
type: struct pointStruct
alias: "MyPointStructVar"
flags: PARAM
}
ref2FieldVar
{
alias: "MyFieldVar"
refgroup: "."
refvar: "MyPointStructVar"
refelem: ".X"
}
34
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
Example of an array
typedef IntArray int[5]
intArrayVar
{
type: IntArray
alias: "MyIntArray"
flags: PARAM
}
ref2IntArrayElem
{
alias: "MyArrayElem"
refgroup: "."
refvar: "MyIntArray"
refelem: "[2]"
}
refgroup
Description The refgroup property specifies in which group the referenced variable is
declared. The group name is specified as a string and contains either an absolute
or a relative path to the group.
Absolute paths have to begin with a slash (/), relative paths can begin with the
name of a subgroup, with a single dot (.), or with two dots (..).
35
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
refvar
Description The refvar property is used within a reference element and requires at least
a related refgroup property. The variable name is specified as a string. If an
alias is specified, the alias name is used, otherwise the name of the referenced
variable is used.
Example Example of specifying the refvar property with an alias defined for the variable.
typedef IntArray int[5]
intArrayVar
{
type: IntArray
alias: "MyIntArray"
flags: PARAM
}
ref2IntArrayElem
{
refgroup: "."
refvar: "MyIntArray"
refelem: "[2]"
}
scale
Description When you read the signal from a data source, the signal value is converted by
using the scale function. The value conversion is an option and not performed
automatically.
36
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
Example § scale: [2 0 3] / [2 4]
§ scale: [2, 0, 3] / [2, 4]
§ scale: [2, 1.345, 2^-11]
scaleback
Description When you write the value to a data source, the value is converted to the signal
value by using the scaleback function. The value conversion is an option and not
performed automatically.
Example § scaleback: [2 4] / [2 0 3]
§ scaleback: [2, 4] / [2, 0, 3]
§ scaleback: [2, 1.345, 2^-11]
Purpose To specify the type, format and size of a variable and to define look‑up tables.
Description § The size has to be set according to the real‑time hardware. The following table
displays the permissible data types and sizes:
37
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
§ The format for floating-point values can only be IEEE standard. If you specify a
variable of integer type, you do not need to define the format.
§ You can additionally specify a variable of array, enumeration or struct type:
§ Arrays on page 38
§ Enumerations on page 39
§ Structs on page 40
Note
The type property used in structure elements does not support pointer
types.
Arrays
Description
§ If you defined a 6x7 matrix, you can refer to specific elements of this
two‑dimensional array, for example:
my2DArr[2..4][3..5] float (32,IEEE)
This line refers to the following nine elements of my2DArr: my2DArr[20]
… my2DArr[22], my2DArr[26] … my2DArr[28] and my2DArr[32] …
my2DArr[34]
38
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
The following illustration shows the 6x7 matrix my2DArr. The selected matrix
elements my2DArr[2..4][3..5] are highlighted.
Note
The alias name(s) are also added with index information in order to be
unambiguous. Always start with zero when you count the elements of an
array.
§ You can also create an n‑dimensional look‑up table. Insert lookup between
the typename and the type within a typedef statement.
Syntax
enum <enumName>
{
type: <Integer-DataType>
enums
{
<enumNumber>: <enumString>
...
}
}
39
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
The definition of the LEDState variable using the enum data type:
LEDState
{
type: enum LEDState
alias: "LEDState"
value: 2
unit: "-"
}
The definition of a type definition using an enum:
typedef LEDStateArray enum LEDState[2]
Syntax
struct <structname>
{
desc: <String>
array-incr: <Integer-DataType>
}
<StructElement>
{
type: <String-DataType>
offs: <Integer-DataType>
}
...
endstruct
40
ConfigurationDesk Syntax of the TRC File May 2024
Variable and Group Properties
unit
Description This property gives information about the physical unit of the signal value. This
text can automatically be displayed, for example, in the caption of an instrument.
value
Description In ControlDesk, this property is mainly used by the data set management. The
specified value is used when initial data sets are generated. For details on data
sets in ControlDesk, refer to Data Sets and their Relation to Memory Pages
(ControlDesk Calibration and Data Set Management ).
41
May 2024 ConfigurationDesk Syntax of the TRC File
Syntax of the TRC File
42
ConfigurationDesk Syntax of the TRC File May 2024
Index
L U
Index
Symbols Local Program Data folder 6 unit 41
_author 15
_description 15 O V
_floating_point_type 16
offs 32 value 41
_gendate 16
origin 33 variable and group properties 25
_genname 17
variable names 11
_genversion 17
_integer_type 18 P
_model 18 properties
addr 27
A alias 28
array-incr 29
addr 27
bitmask 30
alias 28
block 30
array-incr 29
default 30
desc 31
B flags 31
bitmask 30 offs 32
block 30 origin 33
range 33
refelem 33
C
refgroup 35
comments 11 refvar 36
Common Program Data folder 6 scale 36
scaleback 37
D type 37
unit 41
default 30
value 41
desc 31
Documents folder 6
R
E range 33
refelem 33
endstruct 19
refgroup 35
enum 20
refvar 36
error file 12
reserved words 14
F
S
flags 31
sampling_period[daq_raster_index] 21
scale 36
G scaleback 37
group 20 struct 22
grouping 9
T
K TRC file
keyword comments 11
_author 15 endgroup keyword 18
_description 15 endstruct keyword 19
_gendate 16 error file 12
_genname 17 group keyword 20
_genversion 17 grouping 9
_integer_type 18 keywords 14
_model 18 principles 9
endgroup 18 struct keyword 22
endstruct 19 syntax 7
enum 20 variable names 11
floating_point_type 16 type 37
group 20 typedef 23
struct 22
typedef 23
keywords 14
43
May 2024 ConfigurationDesk Syntax of the TRC File
Index
44
ConfigurationDesk Syntax of the TRC File May 2024