Application and Driver Scripts
These examples show the features of Simulink® Real-Time™. Use these scripts as a starting point for writing your scripts for creating and testing real-time applications.
These examples include general applications examples and driver examples. You can access the general application and driver examples through MATLAB® Help. In the help window, click Real-Time Simulation and Testing > Simulink Real-Time > Examples.
The general application examples include models and scripts.
Real-time parameter tuning and data logging
Log signal data with the Simulation Data Inspector to a file on the development computer
Create a custom client application to interface with the target computer
Concurrent execution of a model by using the Simulink Real-Time profiling tool
These driver examples include models and scripts showing the use of driver blocks in a Simulink Real-Time environment. To run some of these examples, you must install specific hardware.
Analog and digital I/O
CAN (CAN_MESSAGE data types)
Counters, timers, pulse width modulators (PWM)
Digital signal processing
Precision Time Protocol (PTP)
To locate and edit an example such as Apply Simulink Real-Time Model Template to Create Real-Time Application:
Open the example scripts folder. In the MATLAB Command Window, type:
Use the descriptive names of the example scripts (similar to the example title) to find the script.
Open the script. In the MATLAB Command Window, type: