How can I improve the live streaming performance of Simulation Data Inspector (SDI) or Dashboard blocks when using Simulink Real-Time and Speedgoat?

32 views (last 30 days)
I use Simulink Real-Time (SLRT) to run simulations on a Speedgoat target computer and want to view live signal data in the Simulation Data Inspector (SDI) or Dashboard blocks. To stream signals to SDI, I use signal logging badges in my model or instruments as shown here.
However, I noticed that the MATLAB process causes very high RAM or CPU load on my host PC, making the MATLAB GUI slow and laggy, which may lead to crashes. Sometimes, I see noticeable gaps in the SDI data or lost timesteps when inspecting the 'logsout' variable or exporting data from the SDI. Additionally, I may see the following warning in the Speedgoat system log:
Live Stream overload
Is there a way to improve the performance of SDI and my Dashboard blocks without reducing my model sample rate?

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 27 Aug 2025
Edited: MathWorks Support Team on 29 Aug 2025
Here are some recommended steps to improve live streaming performance with Simulink Real-Time (SLRT) and Speedgoat hardware:
1. Upgrade to the latest MATLAB release:
We continuously work on improving SDI performance so using the latest MATLAB is recommended. In particular, if you use External Mode ("Run on Target" button) and your model contains many graphical elements (Dashboard blocks, Scopes, Displays), an upgrade to at least R2024b is recommended due to significant enhancements in the underlying framework. Also, make sure to use the latest update level for your release.
2. Decrease the data rate for live streaming:
To decrease the data rate for live streaming, you could:
  • Reduce the model sample rate,
  • Stream fewer signals,
  • Change the signal data type (e.g. 'single' instead of 'double'),
  • Adjust the logging sample time for badged signals,
  • Increase the decimation for badged signals or instrumented signals (R2021b+), or
  • Limit the data points for badged signals (R2021b+).
To decimate or limit data points, or change the logging sample time, right-click the logging badge (blue WiFi symbol) for the signal and open the Instrumentation Properties:
For more information on reducing the data points for live streaming, as well as limitations, see: How do I decimate or limit data points when live-streaming signals from Speedgoat hardware to SDI?
3. Consider file logging instead of (or in addition to) live streaming:
While streaming signals at a lower rate in SDI, you can log the same signals on the Speedgoat's local SSD via File Logs block to preserve the original sample time. File logging can handle much higher data rates without dropping data. More information can be found at File Logging Basics.
Note that live streaming from a real-time application does not guarantee that all data appears in SDI. Live stream instrumentation runs at a lower priority than the real-time application, so data sent by live streaming could be dropped if the host-target connection cannot keep up. This behavior is explained in this MATLAB answer. In addition, data loss can occur in case of an unexpected MATLAB or host computer shutdown, which is avoided by using File Logs. 
4. Change the SDI record mode to "View during simulation only":
You can significantly improve SDI performance by turning recording off. You can configure this in the SDI Preferences > Storage panel, as shown in the screenshot:
When you select "View during simulation only", SDI does not log any data to disk or RAM. The data can be plotted only during the simulation and is discarded once it completes. In this mode, SDI functions more like an oscilloscope -- providing a live, transient view of signals without retaining them for later analysis.
NOTE: The Record mode resets to the default View and record data when MATLAB restarts. To set it automatically for every MATLAB session, add the following command to a startup file:
Simulink.sdi.setRecordData(false);
5. Use a custom app, SLRT Explorer, or MATLAB commands instead of external mode
When working with large Simulink models, interacting with the real-time simulation via the model interface (ie. external mode via "Run on Target" button) may cause too much overhead. You can instead create a more lightweight custom SLRT App with App Designer, use the more abstract SLRT Explorer (>> slrtExplorer), or use basic MATLAB commands and scripts.
6. Remove DMR files and monitor the host PC disk space
Another useful step is to close all open MATLAB sessions and delete any SDI artifacts files with .dmr extension that you find in your Windows temp folder: 
>> winopen(tempdir)
Normally, MATLAB automatically removes these DMR files upon closing. However, in cases of abnormal exits, these files (which can grow to many GBs) may persist on the C drive and cause SDI to become slower.
If turning off recording to DMR files (see #4) is no option, you can leverage various options to control the size of DMR files, such as setting Max Disk Usage or an Archive Size limit. See: How to manage and reduce the size of DMR files that MATLAB generates in the temp directory?
7. Increase RAM on Your Host PC
If you observe that the MATLAB process fills up RAM, consider increasing the RAM on your PC (use at least 16GB, better 32GB or 64GB). More RAM can help handle larger datasets and reduce the likelihood of performance bottlenecks caused by insufficient memory.
8. Check Your Network Setup and Hardware
In rare cases, "Live stream overload" warnings may occur due to hardware/network issues, such as a faulty USB-Ethernet adapter. See Troubleshooting connection issues with Speedgoat target computers for more information.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!