| Contents | Index |
This table summarizes what's new in V8.0 (R2011a):
| 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
Code Optimizations for Discrete State-Space Block, Product Block, and MinMax Block
ASAP2 File Generation Supports Standard Axis Format for Lookup Tables
Lookup Table Block Option to Remove Input Range Checks in Generated Code
Reentrant Code Generation for Stateflow Charts That Use Events
Redundant Check Code Removed for Stateflow Charts That Use Temporal Operators
Support for Multiple Asynchronous Function Calls Into a Model Block
Updates to Target Language Compiler (TLC) Semantics and Diagnostic Information
Change to Terminate Function for a Target Language Compiler (TLC) Block Implementation
In R2011a, the Simulink Coder product combines and replaces the Real-Time Workshop® and Stateflow® Coder™ products. Additionally,
The Real-Time Workshop facility for converting MATLAB code to C/C++ code, formerly referred to as Embedded MATLAB® Coder, has migrated to the new MATLAB Coder product.
The previously existing products Embedded IDE Link™ and Target Support Package™ have been integrated into the new Simulink Coder and Embedded Coder products.
The following figure shows the R2011a transitions for C/C++ code generation related products, from the R2010b products to the new MATLAB Coder, Simulink Coder, and Embedded Coder products.

The following sections address topics related to the product restructuring.
If you are upgrading to Simulink Coder from Real-Time Workshop or Stateflow Coder, review information about compatibility and upgrade issues at the following locations:
Compatibility Summary for Simulink Coder Software (latest release)
In the Archived documentation on the MathWorks web site, select R2010b, and view the following tables, which are provided in the release notes for Real-Time Workshop and Stateflow Coder:
Compatibility Summary for Real-Time Workshop Software
Compatibility Summary for Stateflow and Stateflow Coder Software
These tables provide compatibility information for releases up through R2010b.
If you use the Embedded IDE Link or Target Support Package capabilities that now are integrated into Simulink Coder and Embedded Coder, go to the Archived documentation and view the corresponding tables for Embedded IDE Link or Target Support Package:
Compatibility Summary for Embedded IDE Link (R2010b)
Compatibility Summary for Target Support Package (R2010b)
You can also refer to the rest of the archived documentation, including release notes, for the Real-Time Workshop, Stateflow Coder, Embedded IDE Link, and Target Support Package products.
In R2011a, the MATLAB Coder function codegen replaces the Real-Time Workshop function emlc. The emlc function still works in R2011a but generates a warning, and will be removed in a future release. For more information, see Migrating from Real-Time Workshop emlc Function in the MATLAB Coder release notes.
In R2011a, the capabilities formerly provided by the Embedded IDE Link and Target Support Package products have been integrated into Simulink Coder and Embedded Coder. The follow table summarizes the transition of the Embedded IDE Link and Target Support Package hardware and software support into coder products.
| Former Product | Supported Hardware and Software | Simulink Coder | Embedded Coder |
|---|---|---|---|
| Embedded IDE Link | Altium® TASKING | x | |
| Analog Devices™ VisualDSP++® | x | ||
| Eclipse IDE | x | x | |
| Green Hills® MULTI® | x | ||
| Texas Instruments™ Code Composer Studio™ | x | ||
| Target Support Package | Analog Devices Blackfin® | x | |
| ARM® | x | ||
| Freescale™ MPC5xx | x | ||
| Infineon® C166® | x | ||
| Texas InstrumentsC2000™ | x | ||
| Texas InstrumentsC5000™ | x | ||
| Texas InstrumentsC6000™ | x | ||
| Linux OS | x | x | |
| Windows OS | x | ||
| VxWorks® RTOS | x |
Some user interface changes were made as part of merging the Real-Time Workshop and Stateflow Coder products into Simulink Coder. They include:
Changes to code generation related elements in the Simulink Configuration Parameters dialog box
Changes to code generation related elements in Simulink menus
Changes to code generation related elements in Simulink blocks, including block parameters and dialog boxes, and block libraries
References to Real-Time Workshop and Stateflow Coder and related terms in error messages, tool tips, demos, and product documentation replaced with references to the latest software
| Where... | Previously... | Now... |
|---|---|---|
| Configuration Parameters dialog box | Real-Time Workshop pane | Code Generation pane |
| Model diagram window | Tools > Real-Time Workshop | Tools > Code Generation |
| Subsystem context menu | Real-Time Workshop | Code Generation |
| Subsystem Parameters dialog box | Following parameters on main pane:
| On new Code Generation pane and renamed:
|
The Simulink Coder software provides the following features as implemented in the former Target Support Package and Embedded IDE Link products:
Automation Interface
External Mode
Multicore Deployment with Rate Based Multithreading
Makefile Generation (XMakefile)
Note You can only use these features in the 32-bit version of your MathWorks products. To use these features on 64-bit hardware, install and run the 32-bit versions of your MathWorks products. |
Blocks from the former Target Support Package product and Embedded IDE Link product are now located in Simulink Coder under Desktop Targets.

Desktop Targets includes the following types of blocks:
Host Communication
Operating Systems
Linux
Windows
Demos from the former Target Support Package product and Embedded IDE Link product now reside under Simulink Coder product help. Click the expandable links, as shown.

You can deploy rate-based multithreading applications to multicore processors running Windows and Linux. This feature improves performance by taking advantage of multicore hardware resources.
Also see the Running Target Applications on Multicore Processors user's guide topic.
The Simulink Coder build process uses a new technique to provide more efficient code for the following blocks:
Product (element-wise matrix operations)
Benefits include:
Reuse of variables
Dead code elimination
Constant folding
Expression folding
For example, in previous releases, temporary buffers were created to carry concatenated signals for these blocks. In R2011a, the build process eliminates unnecessary temporary buffers and writes the concatenated signal to the downstream global buffer directly. This enhancement reduces the stack size and improves code execution speed.
The build process also provides more efficient code for the MinMax block. In R2011a, expression folding is enhanced with several local optimizations that enable more aggressive folding. This enhancement improves code efficiency for foldable matrix operations.
In previous releases, user-defined data types that were shared among multiple models generated duplicate type definitions in the model_types.h file for each model. R2011a provides the ability to generate user-defined data type definitions into a header file that can be shared across multiple models, removing the need for duplicate copies of the data type definitions. User-defined data types that you can set up in a shared header file include:
Simulink data type objects that you instantiate from the classes Simulink.AliasType, Simulink.Bus, Simulink.NumericType, and Simulink.StructType
Enumeration types that you define in MATLAB code
For more information, see Share User-Defined Data Types Across Models in the Simulink Coder documentation.
The C API now provides programmatic access to root-level inputs and outputs. This allows you to log and monitor the root-level inputs and outputs of a model while you run the code generated for the model. To generate C API code for accessing root-level inputs and outputs at run time, select the model option Generate C API for: root-level I/O.
Macros for accessing C API generated structures are located in matlabroot/rtw/c/src/rtw_capi.h and matlabroot/rtw/c/src/rtw_modelmap.h, where matlabroot represents your MATLAB installation root.
For more information, see Generate C API for: root-level I/O and Data Interchange Using the C API in the Simulink Coder documentation.
In previous releases, ASAP2 file generation for lookup table blocks supported the Fix Axis and Common Axis formats, but not the Standard Axis format, a format in which axis points are global in code but not shared among tables. R2011a adds support for Standard Axis format.
For more information, see Define ASAP2 Information for Lookup Tables in the Simulink Coder documentation.
In generated ASAP2 files, computation methods translate the electronic control unit (ECU) internal representation of measurement and calibration quantities into a physical model oriented representation. R2011a adds the MATLAB function getCompuMethodName, which you can use to customize the names of computation methods. You can provide names that are more intuitive, enhancing ASAP2 file readability, or names that meet organizational requirements. For more information, see Customize Computation Method Names in the Simulink Coder documentation.
Versions 1.51 and later of the ASAP2 specification state that for certain cases of lookup table axis descriptions (integer data type and no doc units), a computation method is not required and the Conversion Method parameter must be set to the value NO_COMPU_METHOD. Beginning in R2011a, you can control whether or not computation methods are suppressed when not required, using the Target Language Compiler (TLC) option ASAP2GenNoCompuMethod. For more information, see Suppress Computation Methods for FIX_AXIS in the Simulink Coder documentation.
When the breakpoint input to a Prelookup, 1-D Lookup Table, 2-D Lookup Table, or n-D Lookup Table block always falls within the range of valid breakpoint values, you can disable range checking in the generated code. By selecting Remove protection against out-of-range input in generated code on the block dialog box, your code can be more efficient.

When you generate code for Stateflow charts that use events, the code does not use a global variable to keep track of the currently active event. Elimination of this global variable enables the code to be reentrant, which allows you to:
Deploy your code in multithreading environments
Share the same algorithm with different persistent data
Compile code that uses function variables that are too large to fit on the stack
In previous releases, reentrant code generation was not possible for charts that used events.
When you generate code for Stateflow charts that use temporal operators, the code excludes redundant checks for tick events and input events that are always true. This enhancement enables the code to be more efficient and applies to all temporal operators: after, before, at, every, and temporalCount.
In previous releases, the code generated for a temporal logic expression such as after(x,tick) would check for two conditions:
(event == tick) && (counter > x)
In R2011a, the code generated for after(x,tick) checks only for when the temporal counter exceeds x:
(counter > x)
This enhancement does not apply when a chart with multiple input events has super-step semantics enabled.
Simulink and Simulink Coder software now support multiple asynchronous function calls into a Model block. This capability relies in part on the new Asynchronous Task Specification block.
The Asynchronous Task Specification block, in combination with a root-level Inport block, allows you to specify an asynchronous function-call input to a Model block. After placing this block at the output port of each root-level Inport block that outputs a function-call signal, select Output function call on the Signal Attributes pane of the Inport block. The Inport block then accepts function-call signals. You can use Asynchronous Task Specification blocks to specify parameters for the asynchronous task associated with the respective Inport blocks.
Note Use the new function call API, LibBlockExecuteFcnCall, to make function calls from an asynchronous source block to reference model destination blocks. |
Note The demo model rtwdemo_async_mdlreftop shows how you can simulate and generate code for asynchronous events on a real-time multitasking system, using asynchronous function calls as Model block inputs. |
The following changes have been made to ver function arguments related to code generation products:
The new argument 'simulinkcoder' returns information about the installed version of the Simulink Coder product.
The argument 'rtw' works but now returns information about Simulink Coder instead of Real-Time Workshop. The software also displays the following message:
Warning: Support for ver('rtw') will be removed in a future release.
Use ver('simulinkcoder') instead.The argument 'coder', which previously returned information about the installed version of the Stateflow Coder product, no longer works. The software displays a "not found" warning.
For more information about using the function, see the ver documentation.
If a script calls the ver function with the'rtw' argument or the'coder' argument, update the script appropriately. For example, you can update the ver call to use the 'simulinkcoder' argument, or remove the ver call.
Updates to TLC simplifies semantics and produces diagnostic information when using the scope resolution operator (::) and built-in function EXISTS(::).
If var can not be resolved in global scope, ::var errors out
If var can only be resolved in local scope, EXISTS(::var) returns false
Diagnostic information highlights problematic TLC coding
For more information, see Introducing the Target Language Compiler.
Previously, the code generator attempted to execute the Terminate function from the TLC implementation of a block, even if the function did not exist. Now, the code generator only attempts to execute a Terminate function if it is defined in the TLC implementation of a block. In the case where the TLC implementation of a block includes a secondary TLC file, which includes a Terminate function, that Terminate function no longer executes.
The following demos have been added in R2011a:
| Demo... | Shows How You Can... |
|---|---|
| rtwdemo_async_mdlreftop | Simulate and generate code for asynchronous events on a real-time multitasking system, using asynchronous function calls as Model block inputs. |
The following demos have been enhanced in R2011a:
| Demo... | Now... |
|---|---|
| vipstabilize_fixpt_beagleboard videostabilization_host_templ | Use the new Video Capture block to simulate or capture a video input signal in the Video Stabilization demo. |
![]() | Version 8.1 (R2011b) Simulink Coder Software | Compatibility Summary for Simulink Coder 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 |