| Contents | Index |
This table summarizes what's new in V7.2 (R2008b):
| New Features and Changes | Version Compatibility Considerations | Fixed Bugs and Known Problems |
|---|---|---|
| Yes Details below | Yes—Details labeled as Compatibility Considerations, below. See also Summary. | Bug
Reports Includes fixes |
New features and changes introduced in this version are organized by these topics:
Simulink now has the capability to run parallel simulations in Rapid Accelerator mode using parfor on prebuilt Simulink models.
You can now run parallel simulations in Rapid Accelerator mode with different external inputs and tunable parameters. The sim command can be called from a parfor loop if the model does not require a rebuild.
For more information, see Running a Simulation Programmatically.
Simulink now has enhanced tuning of the solver and logging parameters in Rapid Accelerator mode without requiring a rebuild.
An improved rebuild mechanism ensures that the model does not rebuild when you change block diagram parameters (e.g., stop time, solver tolerances, etc.). This enhancement significantly decreases the time for simulation in Rapid Accelerator mode.
In previous releases, accelerated simulation was not supported for models that use integer or fixed-point data types greater than 32 bits in length. In this release, the acceleration limit on integer and fixed-point data type size has increased to 128 bits, the same as the limit for normal-mode, i.e., unaccelerated simulation.
For releases prior to 2008b, at the simulation start time, Simulink initializes all blocks unconditionally and subsystems cannot reset the states. Release 2008b introduces behavior that mirrors the behavior of Real-Time Workshop. For normal simulation mode, the Simulink block initialization method (mdlInitializeConditions) can be called more than once at the start time if:
The block is contained within a Conditional, Action, or Iterator subsystem.
The subsystem is configured to reset states when enabled (or triggered); and the subsystem is enabled (or triggered) at the start time.
This new initialization behavior has the following effect on S-functions:
If you need to ensure that the initialization code in the mdlInitializeConditions function runs only once, then move this initialization code into the mdlStart method. MathWorks recommends this code change as a best practice.
The change to the block initialization method, as described above, exposed a bug in the S-function macro ssIsFirstInitCond for applications involving an S-function within a Conditional, Action or Iterator subsystem. This bug has been fixed in R2008b.
To determine if you consequently need to update your Simulink S-functions for compatibility, compare the simulation results from R2007b or an earlier release with those of R2008b. If they differ at the start time, ssIsFirstInitCond is running more than once and you must regenerate and recompile the appropriate Simulink S-functions.
For Real-Time Workshop, you must regenerate and recompile all S-function targets and any Real-Time Workshop target for which the absolute time is turned on. (If a third-party vendor developed your S-functions, have the vendor regenerate and recompile them for you. The vendor can use the SLDiagnostics feature to identify all S-functions in a model.)
In R2008b, Simulink has a new Model block simulation mode for processor-in-the-loop (PIL) verification of generated code. This feature requires Real-Time Workshop Embedded Coder software. The feature lets you test the automatically generated and cross-compiled object code on your embedded processor by easily switching between Normal, Accelerator, and PIL simulation modes in your original model. You can reuse test suites, resulting in faster iteration between model development and generated code verification. For more information, see Referenced Model Simulation Modes.
R2008b of Simulink includes enhanced handling of initial conditions for conditionally executed subsystems, Merge blocks, and Discrete-Time Integrator blocks, improving consistency of simulation results.
This feature allows you to select simplified initialization mode for conditionally executed subsystems, Merge blocks, subsystem elapsed time, and Discrete-Time Integrator blocks. The simplified initialization improves the consistency of simulation results, especially for models that do not specify initial conditions for conditional subsystem output ports, and for models that have conditionally executed subsystem output ports connected to S-functions.
Activating This Feature for New Models. For new models, you can activate this feature as follows:
In the model window, select Simulation > Configuration Parameters.
The Configuration Parameters dialog box opens.
Select Diagnostics > Data Validity.
The Data Validity Diagnostics pane opens.
In the Model Initialization section, set Underspecified initialization detection to Simplified.
Select Diagnostics > Connectivity.
The Connectivity Diagnostics pane opens.
Set Mux blocks used to create bus signals to error.
Set Bus signal treated as vector to error.
Click OK.
For more information, see Underspecified initialization detection.
Migrating Existing Models. For existing models, MathWorks recommends using the Model Advisor to migrate your model to the new simplified initialization mode settings.
To migrate an existing model:
In the model window, select Simulation > Configuration Parameters.
The Configuration Parameters dialog box opens.
Select Diagnostics > Data Validity.
The Data Validity Diagnostics pane opens.
In the Merge Block section, set Detect multiple driving blocks executing at the same time step to error.
Click OK.
Simulate the model and ensure that it runs without errors.
Select Tools > Model Advisor.
The Model Advisor opens.
In the Model Advisor Task Manager, select By Product > Simulink.
Run Check for proper bus usage in the Model Advisor.
Run Check consistency of initialization parameters for Outport and Merge blocks in the Model Advisor.
After you have resolved any errors identified by this check, click Proceed to migrate your model to simplified initialization mode.
For information on using the Model Advisor, see Consulting the Model Advisor in the Simulink User's Guide.
For information on the Model Advisor checks, see Check consistency of initialization parameters for Outport and Merge blocks in the Simulink Reference.
Compatibility Considerations. Activating this feature can cause differences in simulation results, when compared to previous versions. Since you must opt-in to this feature before any changes are made, there are no issues for existing models. However, MathWorks recommends that you backup existing models before you migrate them, in case you want to return to the original behavior.
Model block inputs can now be local and reusable. This capability reduces global data usage and data copying when interfacing with code from a referenced model, which can reduce memory usage during simulation and increase the efficiency of generated code. This enhancement is always relevant, so no configuration parameter is necessary or provided to control it.
In previous releases, the ModelReferenceSimTargetVerbose parameter controlled verbosity when a referenced model was built for execution in Accelerator mode, as specified by the Model block's Simulation mode parameter. The ModelReferenceSimTargetVerbose had no GUI equivalent. See Referenced Model Simulation Modes and the Model block documentation for more information.
A different parameter, AccelVerboseBuild, controls the verbosity when a model is built in Simulink Accelerator mode or Rapid Accelerator mode, as specified in the Simulation menu. See Accelerating Models for more information. The GUI equivalent of the AccelVerboseBuild parameter is Configuration Parameters > Optimization > Verbose accelerator builds. See Verbose accelerator builds for more information.
All types of accelerated simulation entail code generation (though the code is not visible to the user) and the two verbosity parameters control whether a detailed account of the code generation process appears in the MATLAB Command Window. However, providing separate verbosity parameters for the two cases was unnecessary.
In R2008b, the ModelReferenceSimTargetVerbose parameter is deprecated and has no effect. The AccelVerboseBuild parameter (Configuration Parameters > Optimization > Verbose accelerator builds) now controls the verbosity for Simulink Accelerator mode, referenced model Accelerator mode, and Rapid Accelerator mode.
Another parameter, RTWVerbose (Configuration Parameters > Real-Time Workshop > Debug > Verbose build) controls the verbosity of Real-Time Workshop code generation. This parameter is unaffected by the changes to ModelReferenceSimTargetVerbose and AccelVerboseBuild.
Compatibility Considerations. In R2008b, trying to set ModelReferenceSimTargetVerbose generates a warning message and has no effect on verbosity. The warning says to use AccelVerboseBuild instead. The default for AccelVerboseBuild is 'off'.
A model saved in R2008b will not include the ModelReferenceSimTargetVerbose parameter. An R2008b model saved to an earlier Simulink version that supports ModelReferenceSimTargetVerbose will include that parameter, giving it the same value that AccelVerboseBuild has in the R2008b version.
The effect of loading a model from an earlier Simulink version into R2008b depends on the source version:
Prior to R14: Neither parameter exists, so no compatibility consideration arises.
R14 – R2006b: Only ModelReferenceSimTargetVerbose exists. Copy its value to AccelVerboseBuild.
R2007a: Both parameters exist but neither has a GUI equivalent. Ignore the value of ModelReferenceSimTargetVerbose and post no warning.
R2007b – R2008a: Both parameters exist and AccelVerboseBuild and has a GUI equivalent. If ModelReferenceSimTargetVerbose is 'on', post a warning to use AccelVerboseBuild instead.
Embedded MATLAB Function blocks now support up to 128 bits of fixed-point precision. This increase in maximum precision from 32 to 128 bits supports generating efficient code for targets with non-standard word sizes and allows Embedded MATLAB Function blocks to work with large fixed-point signals.
You can now specify embeddable code generation options from the Embedded MATLAB Editor using a new menu item: Tools > Open RTW Target. Simulation options continue to be available from Tools > Open Simulation Target.
In addition, simulation and embeddable code generation options now appear in a single dialog box. For details, see Unified Simulation and Embeddable Code Generation Options.
When you enable data type override for Embedded MATLAB Function blocks, outputs with explicit and inherited types are converted to the override type. For example, if you set data type override to true singles, the Embedded MATLAB Function block converts all outputs to single type and propagates the override type to downstream blocks.
In previous releases, Embedded MATLAB Function blocks did not apply data type override to outputs with inherited types. Instead, the inherited type was preserved even if it did not match the override type, sometimes causing errors during simulation.
Compatibility Consideration. Applying data type override rules to outputs with inherited types may introduce the following compatibility issues:
Downstream Embedded MATLAB Function blocks must be able to accept the propagated override type. Therefore, you must allow data type override for downstream blocks for which you set output type explicitly. Otherwise, you may not be able to simulate your model.
You might get unexpected simulation results if the propagated type uses less precision than the original type.
When evaluating relational operators, Embedded MATLAB Function blocks compute a common type that encompasses both input operands. In previous releases, if the common type required more than 32 bits, Embedded MATLAB Function blocks may have given different answers from MATLAB. Now, Embedded MATLAB Function blocks give the same answers as MATLAB.
Compatibility Consideration. Some relational operators generate multi-word code even if one of the fixed-point operands is not a multi-word value. To work around this issue, cast both operands to the same fixed-point type (using the same scaling method and properties).
Simulink models now support enumerated data types. For details, see:
Enumerations and Modeling in the Simulink User's Guide
Using Enumerated Data in Stateflow Charts in the Stateflow User's Guide
Enumerations in the Real-Time Workshop User's Guide
The Simulink Bus Editor can now filter displayed bus objects by either name or relationship. See Filtering Displayed Bus Objects for details.
You can now fully customize the export and import capabilities of the Simulink Bus Editor. See Customizing Bus Object Import and Export for details.
A new Model Advisor check posts advice and warnings about the proper use of Data Store Memory, Data Store Read, and Data Store Write blocks. See Check Data Store Memory blocks for multitasking, strong typing, and shadowing issues for details.
Enhanced file dependency analysis can now:
Find system target files
Analyze STF_make_rtw_hook functions
Analyze all configuration sets, not just the active set.
See Scope of Dependency Analysis in the Simulink User's Guide.
R2008b provides an enhanced Trigonometric Function block to:
Support sincos
Provide greater floating-point consistency
In Simulink 2008b, an enhanced Math Function block provides greater floating-point consistency.
R2008b provides enhanced handling of initial conditions for the Merge block and thus improves the consistency of simulation results.
For more information, see Conditionally Executed Subsystem Initial Conditions.
R2008b provides an enhanced handling of initial conditions for the Discrete-Time Integrator block and thereby improves the consistency of simulation results.
For more information, see Conditionally Executed Subsystem Initial Conditions.
In this release, Simulink software can signal an error if a block callback function, e.g., CopyFcn, modifies a link to a library block. For example, an error occurs if you attempt to copy a library link to a self-modifying masked subsystem whose CopyFcn deletes a block contained by the subsystem. This change means that you cannot use block callback functions to create self-modifying library blocks. Mask initialization code for a library block is the only code allowed to modify the block.
Compatibility Consideration. Previous releases allowed use of block callback functions to create self-modifying library blocks. Opening, editing, or running models that contain links to such blocks can cause illegal modification errors in the current release. As a temporary work around, you can break any links in your model to a library block that uses callback functions to modify itself. The best long-term solution is to move the self-modification code to the block's mask initialization section.
In the dialog box for the Random Number block, the field Initial Seed has been renamed Seed. The command-line parameter remains the same.
The Signal Generator block now supports multidimensional signals. For a list of blocks that support multidimensional signals, see Signal Dimensions in the Simulink User's Guide.
The accumulator of the Sum block now applies for all input signals of any data type (for example, double, single, integer, and fixed-point). In previous releases, the accumulator of this block was limited to inputs and outputs of only integer or fixed-point data types.
The Switch block now supports the immediate back propagation of a known output data type to the first and third input ports. This occurs when you set the Output data type parameter to Inherit: Inherit via internal rule and select the Require all data port inputs to have the same data type check box. In previous releases, this back propagation did not occur immediately.
In the dialog box for the Uniform Random Number block, the field Initial Seed has been renamed Seed. The command-line parameter remains the same.
The display of sample time information has been expanded to include:
Signal lines labeling with new color-independent Annotations
A new Sample Time Legend maps the sample time Colors and Annotations to sample times.
A distinct color for indicating that a block and signal are asynchronous.
The section "Modeling and Simulation of Discrete Systems" has been renamed "Working with Sample Times" and has been significantly expanded to provide a comprehensive review of sample times and a discussion on the new Sample Time Legend and Sample Time Display features. For more information, see Working with Sample Times.
In R2008b, the Model Advisor is enhanced with:
A model and data restore point that provides you with the ability to revert changes made in response to advice from the Model Advisor
Context-sensitive help available for Model Advisor checks
Tristate check boxes that visually indicate selected and cleared checks in folders
A system selector for choosing the system level that the Model Advisor checks
See Consulting the Model Advisor in the Simulink User's Guide.
R2008b introduces context-sensitive help for parameters that appear in the following commonly used blocks in Simulink:
| Bus Creator |
| Bus Selector |
| Constant |
| Data Type Conversion |
| Demux |
| Discrete-Time Integrator |
| Gain |
| Inport |
| Integrator |
| Logical Operator |
| Mux |
| Outport |
| Product |
| Relational Operator |
| Saturation |
| Subsystem |
| Sum |
| Switch |
| Terminator |
| Unit Delay |
This feature provides quick access to a detailed description of the parameters, saving you the time it would take to find the information in the Help browser.
To use the "What's This?" help, do the following:
Place your cursor over the label of a parameter.
Right-click. A What's This? context menu appears.
For example, the following figure shows the What's This? context menu appearing after right-clicking the Multiplication parameter for the Gain block.

Click What's This? A context-sensitive help window appears showing a description of the parameter.
This release introduces a compact icon option that maximizes the number of blocks and libraries visible in the Library Browser's Library pane without scrolling (see Library Pane).
In previous releases, a signal could be logged only if it was also a test point. Therefore, selecting Log signal data in the Signal Properties dialog box automatically selected Test point, and disabled it so that it could not be cleared. However, a signal can be a test point without being logged, so clearing Log signal data did not automatically clear Test point. The same asymmetric behavior occurred programmatically with the underlying DataLogging and TestPoint parameters.
In R2008b, no connection exists between enabling logging for a signal and making the signal a test point. Either, both, or neither capability can be enabled for any signal. Selecting and clearing Log signal data therefore has no effect on the setting of Test point, and similarly for the underlying parameters. See Exporting Signal Data Using Signal Logging and Working with Test Points for more information.
To reflect the independence of logging and test points, the command Test Point Indicators in the Simulink Format > Port/Signal Displays menu has been renamed Testpoint/Logging Indicators. The effect of the command, the graphical indicators displayed, and the meaning of the underlying parameter ShowTestPointIcons, are all unchanged.
Compatibility Considerations. Scripts and practices that relied on Log signal data to automatically set a test point must be changed to set the test point explicitly. The relevant set_param commands are:
set_param(PortHandle(n),'DataLogging','on') set_param(PortHandle(n),'TestPoint','on')
To disable either capability, set the relevant parameter to 'off'. See Enabling Logging for a Signal for an example.
A virtual signal is a signal that graphically represents other signals or parts of other signals. Virtual signals are purely graphical entities; they have no functional or mathematical significance. The nonvirtual components of a virtual signal are called regions. For example, if Mux block (which is a virtual block) inputs two nonvirtual signals, the block outputs a virtual signal that has two regions. See Virtual Signals and Mux Signals for more information.
In previous releases, when a virtual signal contains duplicate regions, signal logging excluded all but one of the duplicates in some contexts, but included all of the duplicates in other contexts, giving inconsistent results. For example, if the same nonvirtual signal is connected to two input ports of a Mux block, that one signal is the source of two regions in the Mux block output. Previously, if that output was being logged in Normal mode simulation, the log object would contain data for only one of the regions, because the other was eliminated as a duplicate.
In R2008a, Simulink no longer eliminates duplicate regions when logging the output of virtual blocks like Mux or Selector blocks. Simulink now logs all regions, which appear in a Simulink.TsArray object. The duplicate regions have unique names as follows:
<signal_name>_reg<#counter>
This change affects signal logs and all capabilities that depend on signal logging, such as scopes and signal viewers.
Compatibility Considerations. In cases where signal logging previously omitted duplicate regions, signal logs will now be larger, and scopes and signal viewers will now show more data. This change could give the impression that the results of simulation have changed, but actually only the logging of those results has changed. No action is needed unless:
A dependency exists on the exact size of a log or the details of its contents.
The size and details have changed due to the inclusion of previously omitted signals.
In such a case, make changes as needed to accept the changed logging behavior. See Exporting Signal Data Using Signal Logging for more information.
In R2008b, the following Simulink configuration parameters are updated:
| Location | Previous Parameter | New Parameter |
|---|---|---|
| Solver | States shape preservation / ShapePreserveControl | Shape preservation / ShapePreserveControl |
| Solver | Consecutive min step size violations / MaxConsecutiveMinStep | Number of consecutive min steps / MaxConsecutiveMinStep |
| Solver | Consecutive zero crossings relative tolerance / ConsecutiveZCsStepRelTol | Time tolerance / ConsecutiveZCsStepRelTol |
| Solver | Zero crossing location algorithm / ZeroCrosAlgorithm | Algorithm / ZeroCrosAlgorithm |
| Solver | Zero crossing location threshold / ZCThreshold | Signal threshold/ ZCThreshold |
| Solver | Number of consecutive zero crossings allowed / MaxConsecutiveZCs | Number of consecutive zero crossings / MaxConsecutiveZCs |
| Optimization | Eliminate superfluous temporary variables (Expression folding) / ExpressionFolding | Eliminate superfluous local variables (Expression folding) / ExpressionFolding |
| Optimization | Remove internal state zero initialization / ZeroInternalMemoryAtStartup | Remove internal data zero initialization / ZeroInternalMemoryAtStartup |
In R2008b, the following Simulink configuration parameters have moved:
| Parameter | Old Location | New Location |
|---|---|---|
| Check undefined subsystem initial output | Diagnostics > Compatibility | Diagnostics > Data Validity |
| Check preactivation output of execution context | Diagnostics > Compatibility | Diagnostics > Data Validity |
| Check runtime output of execution context | Diagnostics > Compatibility | Diagnostics > Data Validity |
In R2008b, the Optimization > Minimize array reads using temporary variables parameter has been obsoleted.
The Simulink model Help menu now includes links to block support tables for the following products, if they are installed.
Simulink
Communications Blockset™
Signal Processing Blockset
Video and Image Processing Blockset™
To obtain the block support tables for all of these products that are installed, select Help > Block Support Table > All Tables.
In previous releases, Help > Block Support Table provided such tables only for the main Simulink library.
You can now specify both simulation and embeddable code generation options in the Configuration Parameters dialog box. The simulation options apply only to Embedded MATLAB Function blocks, Stateflow charts, and Truth Table blocks.
The following table summarizes changes that apply for Embedded MATLAB Function blocks:
| Type of Model | Simulation Options | Embeddable Code Generation Options |
|---|---|---|
| Nonlibrary | Migrated from the Simulation Target dialog box to the Configuration Parameters dialog box. See: | New menu item in the Embedded MATLAB Editor for specifying code generation options for nonlibrary models: Tools > Open RTW Target New options in the Real-Time Workshop pane of the Configuration Parameters dialog box. See: |
| Library | Migrated from the Simulation Target dialog box to the Configuration Parameters dialog box. See: | New menu item in Embedded MATLAB Editor for specifying custom code generation options for library models: Tools > Open RTW Target For a description of these options, see Library Models: Support for Specifying Custom Code Options in the Real-Time Workshop Pane of the Configuration Parameters Dialog Box. |
For details about the new options, see Configuration Parameters Dialog Box in the Simulink Graphical User Interface documentation. For compatibility information, see Compatibility Considerations.
For changes specific to Stateflow, see Unified Simulation and Embeddable Code Generation Options for Stateflow Charts and Truth Table Blocks in the Stateflow and Stateflow Coder release notes.
Nonlibrary Models: Changes for the General Pane of the Simulation Target Dialog Box. The following sections describe changes in the panes of the Simulation Target dialog box for nonlibrary models.
| Release | Appearance |
|---|---|
| Previous | General pane of the Simulation Target dialog box
|
| New | Simulation Target pane of the Configuration Parameters dialog box
|
For details, see Nonlibrary Models: Mapping of GUI Options from the Simulation Target Dialog Box to the Configuration Parameters Dialog Box.
Nonlibrary Models: Changes for the Custom Code Pane of the Simulation Target Dialog Box.
| Release | Appearance |
|---|---|
| Previous | Custom Code pane of the Simulation Target dialog box
|
| New | Simulation Target > Symbols pane of the Configuration Parameters dialog box
|
| New | Simulation Target > Custom Code pane of the Configuration Parameters dialog box
|
For details, see Nonlibrary Models: Mapping of GUI Options from the Simulation Target Dialog Box to the Configuration Parameters Dialog Box.
Nonlibrary Models: Changes for the Description Pane of the Simulation Target Dialog Box. In previous releases, the Description pane of the Simulation Target dialog box appeared as follows.

In R2008b, these options are no longer available. For older models where the Description pane contained information, the text is now accessible only in the Model Explorer. When you select Simulink Root > Configuration Preferences in the Model Hierarchy pane, the text appears in the Description field for that model.
Nonlibrary Models: Mapping of GUI Options from the Simulation Target Dialog Box to the Configuration Parameters Dialog Box. For nonlibrary models, the following table maps each GUI option in the Simulation Target dialog box to the equivalent in the Configuration Parameters dialog box. The options are listed in order of appearance in the Simulation Target dialog box.
| Old Option in the Simulation Target Dialog Box | New Option in the Configuration Parameters Dialog Box | Default Value of New Option |
|---|---|---|
| General > Enable debugging / animation | Simulation Target > Enable debugging / animation | on |
| General > Enable overflow detection (with debugging) | Simulation Target > Enable overflow detection (with debugging) | on |
| General > Echo expressions without semicolons | Simulation Target > Echo expressions without semicolons | on |
| General > Build Actions | Simulation Target > Simulation target build mode | Incremental build |
| None | Simulation Target > Custom Code > Source file | '' |
| Custom Code > Include Code | Simulation Target > Custom Code > Header file | '' |
| Custom Code > Include Paths | Simulation Target > Custom Code > Include directories | '' |
| Custom Code > Source Files | Simulation Target > Custom Code > Source files | '' |
| Custom Code > Libraries | Simulation Target > Custom Code > Libraries | '' |
| Custom Code > Initialization Code | Simulation Target > Custom Code > Initialize function | '' |
| Custom Code > Termination Code | Simulation Target > Custom Code > Terminate function | '' |
| Custom Code > Reserved Names | Simulation Target > Symbols > Reserved names | {} |
| Custom Code > Use these custom code settings for all libraries | None | Not applicable |
| Description > Description | None | Not applicable |
| Description > Document Link | None | Not applicable |
Note For nonlibrary models, Simulation Target options in the Configuration Parameters dialog box are also available in the Model Explorer. When you select Simulink Root > Configuration Preferences in the Model Hierarchy pane, you can select Simulation Target in the Contents pane to access the options. |
Library Models: Changes for the General Pane of the Simulation Target Dialog Box. In previous releases, the General pane of the Simulation Target dialog box for library models appeared as follows.

In R2008b, these options are no longer available. All library models inherit these option settings from the main model to which the libraries are linked.
Library Models: Changes for the Custom Code Pane of the Simulation Target Dialog Box.
| Release | Appearance |
|---|---|
| Previous | Custom Code pane of the Simulation Target dialog box
|
| New | Simulation Target pane of the Configuration Parameters dialog box
|
For details, see Library Models: Mapping of GUI Options from the Simulation Target Dialog Box to the Configuration Parameters Dialog Box.
Library Models: Changes for the Description Pane of the Simulation Target Dialog Box. In previous releases, the Description pane of the Simulation Target dialog box appeared as follows.

In R2008b, these options are no longer available. For older models where the Description pane contained information, the text is discarded.
Library Models: Mapping of GUI Options from the Simulation Target Dialog Box to the Configuration Parameters Dialog Box. For library models, the following table maps each GUI option in the Simulation Target dialog box to the equivalent in the Configuration Parameters dialog box. The options are listed in order of appearance in the Simulation Target dialog box.
| Old Option in the Simulation Target Dialog Box | New Option in the Configuration Parameters Dialog Box | Default Value of New Option |
|---|---|---|
| General > Enable debugging / animation | None | Not applicable |
| General > Enable overflow detection (with debugging) | None | Not applicable |
| General > Echo expressions without semicolons | None | Not applicable |
| General > Build Actions | None | Not applicable |
| None | Simulation Target > Source file | '' |
| Custom Code > Include Code | Simulation Target > Header file | '' |
| Custom Code > Include Paths | Simulation Target > Include directories | '' |
| Custom Code > Source Files | Simulation Target > Source files | '' |
| Custom Code > Libraries | Simulation Target > Libraries | '' |
| Custom Code > Initialization Code | Simulation Target > Initialize function | '' |
| Custom Code > Termination Code | Simulation Target > Terminate function | '' |
| Custom Code > Reserved Names | None | Not applicable |
| Custom Code > Use local custom code settings (do not inherit from main model) | Simulation Target > Use local custom code settings (do not inherit from main model) | off |
| Description > Description | None | Not applicable |
| Description > Document Link | None | Not applicable |
Note For library models, Simulation Target options in the Configuration Parameters dialog box are not available in the Model Explorer. |
Nonlibrary Models: Enhancement for the Real-Time Workshop: Symbols Pane of the Configuration Parameters Dialog Box. In previous releases, the Real-Time Workshop > Symbols pane of the Configuration Parameters dialog box appeared as follows.

In R2008b, a new option is available in this pane: Reserved names. You can use this option to specify a set of keywords that the Real-Time Workshop build process should not use. This action prevents naming conflicts between functions and variables from external environments and identifiers in the generated code.
You can also choose to use the reserved names specified in the Simulation Target > Symbols pane to avoid entering the same information twice for the nonlibrary model. Select the option Use the same reserved names as Simulation Target.
Nonlibrary Models: Enhancement for the Real-Time Workshop: Custom Code Pane of the Configuration Parameters Dialog Box. In previous releases, the Real-Time Workshop > Custom Code pane of the Configuration Parameters dialog box appeared as follows.

In R2008b, a new option is available in this pane: Use the same custom code settings as Simulation Target. You can use this option to copy the custom code settings from the Simulation Target > Custom Code pane to avoid entering the same information twice for the nonlibrary model.
Library Models: Support for Specifying Custom Code Options in the Real-Time Workshop Pane of the Configuration Parameters Dialog Box. In R2008b, you can specify custom code options in the Configuration Parameters dialog box, as shown:

For more information, see Code Generation Pane: Custom Code in the Real-Time Workshop Reference documentation.
Previously, you could programmatically set options for simulation and embeddable code generation of models containing Embedded MATLAB Function blocks, Stateflow charts, or Truth Table blocks by accessing the API properties of Target objects sfun and rtw, respectively. In R2008b, the API properties of Target objects sfun and rtw are replaced by parameters that you configure using the commands get_param and set_param.
For compatibility details, see Compatibility Considerations.
Mapping of Object Properties to Simulation Parameters for Nonlibrary Models. The following table maps API properties of the Target object sfun for nonlibrary models to the equivalent parameters in R2008b. Object properties are listed in alphabetical order; those not listed in the table do not have equivalent parameters in R2008b.
| Old sfun Object Property | Old Option in the Simulation Target Dialog Box | New Configuration Parameter | New Option in the Configuration Parameters Dialog Box |
|---|---|---|---|
CodeFlagsInfo | General > Enable debugging / animation | SFSimEnableDebug string - off, on | Simulation Target > Enable debugging / animation |
CodeFlagsInfo | General > Enable overflow detection (with debugging) | SFSimOverflowDetection string - off, on | Simulation Target > Enable overflow detection (with debugging) |
CodeFlagsInfo | General > Echo expressions without semicolons | SFSimEcho string - off, on | Simulation Target > Echo expressions without semicolons |
| CustomCode | Custom Code > Include Code | SimCustomHeaderCode string - '' | Simulation Target > Custom Code > Header file |
| CustomInitializer | Custom Code > Initialization Code | SimCustomInitializer string - '' | Simulation Target > Custom Code > Initialize function |
| CustomTerminator | Custom Code > Termination Code | SimCustomTerminator string - '' | Simulation Target > Custom Code > Terminate function |
ReservedNames | Custom Code > Reserved Names | SimReservedNameArray string array - {} | Simulation Target > Symbols > Reserved names |
| UserIncludeDirs | Custom Code > Include Paths | SimUserIncludeDirs string - '' | Simulation Target > Custom Code > Include directories |
| UserLibraries | Custom Code > Libraries | SimUserLibraries string - '' | Simulation Target > Custom Code > Libraries |
| UserSources | Custom Code > Source Files | SimUserSources string - '' | Simulation Target > Custom Code > Source files |
Mapping of Object Properties to Simulation Parameters for Library Models. The following table maps API properties of the Target object sfun for library models to the equivalent parameters in R2008b. Object properties are listed in alphabetical order; those not listed in the table do not have equivalent parameters in R2008b.
| Old sfun Object Property | Old Option in the Simulation Target Dialog Box | New Configuration Parameter | New Option in the Configuration Parameters Dialog Box |
|---|---|---|---|
| CustomCode | Custom Code > Include Code | SimCustomHeaderCode string - '' | Simulation Target > Header file |
| CustomInitializer | Custom Code > Initialization Code | SimCustomInitializer string - '' | Simulation Target > Initialize function |
| CustomTerminator | Custom Code > Termination Code | SimCustomTerminator string - '' | Simulation Target > Terminate function |
UseLocalCustomCodeSettings | Custom Code > Use local custom code settings (do not inherit from main model) | SimUseLocalCustomCode string - off, on | Simulation Target > Use local custom code settings (do not inherit from main model) |
| UserIncludeDirs | Custom Code > Include Paths | SimUserIncludeDirs string - '' | Simulation Target > Include directories |
| UserLibraries | Custom Code > Libraries | SimUserLibraries string - '' | Simulation Target > Libraries |
| UserSources | Custom Code > Source Files | SimUserSources string - '' | Simulation Target > Source files |
Mapping of Object Properties to Code Generation Parameters for Library Models. The following table maps API properties of the Target object rtw for library models to the equivalent parameters in R2008b. Object properties are listed in alphabetical order; those not listed in the table do not have equivalent parameters in R2008b.
| Old rtw Object Property | Old Option in the RTW Target Dialog Box | New Configuration Parameter | New Option in the Configuration Parameters Dialog Box |
|---|---|---|---|
| CustomCode | Custom Code > Include Code | CustomHeaderCode string - '' | Real-Time Workshop > Header file |
| CustomInitializer | Custom Code > Initialization Code | CustomInitializer string - '' | Real-Time Workshop > Initialize function |
| CustomTerminator | Custom Code > Termination Code | CustomTerminator string - '' | Real-Time Workshop > Terminate function |
| UseLocalCustomCodeSettings | Custom Code > Use local custom code settings (do not inherit from main model) | RTWUseLocalCustomCode string - off, on | Real-Time Workshop > Use local custom code settings (do not inherit from main model) |
| UserIncludeDirs | Custom Code > Include Paths | CustomInclude string - '' | Real-Time Workshop > Include directories |
| UserLibraries | Custom Code > Libraries | CustomLibrary string - '' | Real-Time Workshop > Libraries |
| UserSources | Custom Code > Source Files | CustomSource string - '' | Real-Time Workshop > Source files |
Compatibility Considerations. When you load and save older models in R2008b, not all target property settings are preserved.
What Happens When You Load an Older Model in R2008b
What Happens When You Save an Older Model in R2008b
In R2008b, new parameters are added to the Configuration Parameters dialog box for simulation and embeddable code generation of models that contain Embedded MATLAB Function blocks, Stateflow charts, or Truth Table blocks.
New Simulation Parameters for Nonlibrary Models. The following table lists the new simulation parameters that apply to nonlibrary models.
| New Configuration Parameter | New Option in the Configuration Parameters Dialog Box | Description |
|---|---|---|
SimBuildMode string – sf_incremental_build, sf_nonincremental_build, sf_make, sf_make_clean, sf_make_clean_objects | Simulation Target > Simulation target build mode | Specifies how you build the simulation target for a model. |
SimCustomSourceCode string - '' | Simulation Target > Custom Code > Source file | Enter code lines to appear near the top of a generated source code file. |
New Simulation Parameter for Library Models. The following table lists the new simulation parameter that applies to library models.
| New Configuration Parameter | New Option in the Configuration Parameters Dialog Box | Description |
|---|---|---|
SimCustomSourceCode string - '' | Simulation Target > Source file | Enter code lines to appear near the top of a generated source code file. |
New Code Generation Parameters for Nonlibrary Models. The following table lists the new code generation parameters that apply to nonlibrary models.
| New Configuration Parameter | New Option in the Configuration Parameters Dialog Box | Description |
|---|---|---|
ReservedNameArray string array - {} | Real-Time Workshop > Symbols > Reserved names | Enter the names of variables or functions in the generated code that match the names of variables or functions specified in custom code. |
RTWUseSimCustomCode string – off, on | Real-Time Workshop > Custom Code > Use the same custom code settings as Simulation Target | Specify whether to use the same custom code settings as those specified for simulation. |
UseSimReservedNames string – off, on | Real-Time Workshop > Symbols > Use the same reserved names as Simulation Target | Specify whether to use the same reserved names as those specified for simulation. |
New Code Generation Parameters for Library Models. The following table lists the new code generation parameters that apply to library models.
| New Configuration Parameter | New Option in the Configuration Parameters Dialog Box | Description |
|---|---|---|
CustomSourceCode string – '' | Real-Time Workshop > Source file | Enter code lines to appear near the top of a generated source code file. |
RTWUseSimCustomCode string – off, on | Real-Time Workshop > Use the same custom code settings as Simulation Target | Specify whether to use the same custom code settings as those specified for simulation. |
In future releases, Simulink will not have a built-in Ada S-function capability. As a mitigation strategy, call Ada code from Simulink using standard Ada 95 language features and the Simulink C-MEX S-function API. For details of this process, please contact Technical Support at MathWorks.
The Legacy Code Tool data structure has been enhanced with a new S-function options field, singleCPPMexFile, which when set to true
Requires you to generate and manage an inlined S-function as only one file (.cpp) instead of two (.c and .tlc)
Maintains model code style—level of parentheses usage and preservation of operand order in expressions and condition expressions in if statements—as specified by model configuration parameters.
When you choose not to use this option, code generated by the Legacy Code Tool does not reflect code style configuration settings and requires you to manage C-MEX and TLC files.
For more information, see:
Integrating Existing C Functions into Simulink Models with the Legacy Code Tool in the Writing S-Functions documentation
Integrate External Code Using Legacy Code Tool in the Real-Time Workshop documentation
legacy_code function reference page
If you upgrade from an earlier release, you can continue to use S-functions generated from the Legacy Code Tool available in earlier releases. You can continue to compile the S-function source code and you can continue to use the compiled output from an earlier release without recompiling the code.
If you set the new singleCPPMexFile options field to true, when creating an S-function, you cannot use that S-function, in source or compiled form, with versions of Simulink earlier than Version 7.2 (R2008b).
The matlab command line arguments -memmgr and -check_malloc are deprecated and will be removed in a future release.
For more information, see Changes to matlab Memory Manager Startup Options in the MATLAB Release Notes.
If you start MATLAB using the command matlab -nojvm (which disables Java), you will receive warnings when using many graphical tools, for example, when you create figures, print Simulink models, or view Simulink scopes.
For more information, see Changes to -nojvm Startup Option in the Desktop Tools and Development Environment release notes.
![]() | Version 7.3 (R2009a) Simulink Software | Version 7.1 (R2008a) Simulink Software | ![]() |

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |