| Insert custom code near the top of the generated model.c or model.cpp file,
outside of any function | Source file and enter the custom code
to insert. |
| Insert custom code near the top of the generated model.h file | Header file and enter the custom code
to insert. |
| Insert custom code inside the model's initialize function in
the model.c or model.cpp file | Initialize function |
| Insert custom code inside the model's terminate function in
the model.c or model.cpp file. | Terminate function and enter the custom
code to insert. Also select the Terminate function required parameter
on the Interface pane. |
| Add include directories, which contain header files, to the
build process | Include directories and enter the absolute
or relative paths to the directories. If you specify relative paths,
the paths must be relative to the directory containing your model
files, not relative to the build directory. The order in which you
specify the directories is the order in which they are searched for
header, source, and library files. |
| Add source files to be compiled and linked | Source files and enter the full paths
or just the file names for the files. A file name is sufficient if
the file is in the current MATLAB directory or in one of the
include directories. For each additional source that you specify,
the Real-Time Workshop build process expands a generic rule in
the template makefile for the directory in which the source file is
found. For example, if a source file is found in directory inc,
the Real-Time Workshop build process adds a rule similar to the
following: %.obj: buildir\inc\%.c
$(CC) -c -Fo$(@F) $(CFLAGS) $< The Real-Time Workshop build
process adds the rules in the order you list the source files. |
| Add libraries to be linked | Libraries and enter the full paths or
just the file names for the libraries. A file name is sufficient if
the library is located in the current MATLAB directory or in
one of the include directories. |
| Use the same custom code settings as those specified for simulation
of Embedded MATLAB Function blocks, Stateflow charts, and
Truth Table blocks | Use the same custom code settings as Simulation TargetNote
This option refers to the Simulation Target pane
in the Configuration Parameters dialog box. |
|
| Enable a library model to use custom code settings unique from
the parent model to which the library is linked | Use local custom code settings (do not inherit from
main model)Note
This option is available only for library models that contain Embedded MATLAB Function
blocks, Stateflow charts, or Truth Table blocks. Select Tools > Open RTW Target in the Embedded MATLAB Editor or Stateflow Editor
for your library model. |
|