| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Real-Time Workshop |
| Contents | Index |
| Learn more about Real-Time Workshop |
The Simulink Signal Properties dialog box lets you interface selected signals to externally written code. In this way, your hand-written code has access to such signals for monitoring or other purposes. To interface a signal to external code, use the Real-Time Workshop tab of the Signal Properties dialog box to assign one of the following storage classes to the signal:
ExportedGlobal
ImportedExtern
ImportedExternPointer
Set the storage class as follows:
In your Simulink block diagram, select the line that carries the signal. Then select Signal Properties from the Edit menu of your model. This opens the Signal Properties dialog box. Alternatively, right-click the line that carries the signal, and select Signal properties from the menu.
Select the Real-Time Workshop tab of the Signal Properties dialog box.
Select the desired storage class (Auto, ExportedGlobal, ImportedExtern, or ImportedExternPointer) from the Storage class menu. The next figure shows ExportedGlobal selected.

Optional: For storage classes other than Auto, you can enter a storage type qualifier such as const or volatile in the Storage type qualifier field. The Real-Time Workshop product does not check this string for errors; whatever you enter is included in the variable declaration.
Note You can also interface test points and other signals that are stored as members of model_B to your code. To do this, your code must know the address of the model_B structure where the data is stored, and other information. This information is not automatically exported. The Real-Time Workshop product provides C/C++ and Target Language Compiler APIs that give your code access to model_B and other data structures. See Interacting with Target Application Signals and Parameters Using the C API for more information. |
![]() | Signals with Test Points | Symbolic Naming Conventions for Signals in Generated Code | ![]() |

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