MATLAB REAL-TIME WORKSHOP 7 - TARGET LANGUAGE COMPILER Service Manual Page 25

  • Download
  • Add to my manuals
  • Print
  • Page
    / 282
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 24
The model.rtw File
2-5
This example shows several records and corresponding subrecords by use of
arrows.
Parameter (Scope 4) is a subrecord of Block (Scope 3), which is a
subrecord of
System (Scope 2), which in turn is a subrecord of CompiledModel
(Scope 1).
The
model.rtw file uses curly braces { and } to open and close scopes. Using
scopes, you can access any value within the
model.rtw file. The scope in this
example begins with
CompiledModel. You use periods (.) to access values
within particular scopes. For example, to access
Name within CompiledModel,
you would use
CompiledModel.Name
To access Identifier within System within CompiledModel, you would use
CompiledModel.System.Identifier
To access Name within the second Parameter record within Block within System
within
CompiledModel, you would use
CompiledModel.System.Block.Parameter[2].Name
This process can be simplified by using the %with directive. See the “Scoping”
section later in this chapter for more information.
The identifier and record name become TLC variables when the Target
Language Compiler loads the
model.rtw file.
The Target Language Compiler lets you traverse the hierarchy defined by
model.rtw so that you can customize the output to suit your particular needs.
To be able to do this, you must understand the structure of the
model.rtw file.
Appendix A contains a complete description of the
model.rtw file.
Page view 24
1 2 ... 20 21 22 23 24 25 26 27 28 29 30 ... 281 282

Comments to this Manuals

No comments