How do I stream my signals at a high rate, while maintaining good SDI performance using SLRT?

19 views (last 30 days)
I am using Simulink Data Inspector (SDI) to view 15 signals at 10kHz from my Speedgoat target computer using Simulink Real-Time (SLRT).
SDI works without issue for 100-200s after which it starts to have a 2-3s buffer. I see noticeable gaps in the data in the SDI or see that some timesteps are lost when I export data from the SDI.
Additionally, I may see:
Live Stream overload
warnings in the Speedgoat system log.
Is there any way that I can improve the performance of SDI without reducing my sample rate?

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 5 May 2022 at 4:00
Edited: MathWorks Support Team on 5 May 2022 at 9:58
The first recommendation would be to upgrade to the latest MATLAB release and/or install the latest MATLAB Update for your release. We are continuously working on improving the performance of SDI so that using the newest MATLAB can be beneficial. In particular, the release R2021b came with a noticeable SDI performance improvement.
Secondly, it is possible to work around this by decreasing the data rate for live streaming data. To do this, you could increase the sample rate, instrument fewer signals, or increase the decimation of instrumented signals. For example, you can change the "Logging Sample Time" of the signal to 0.1 so that you will see a lower rate signal in SDI, allowing SDI to run more smoothly during simulation. To edit the "Logging Sample Time", right-click the logging badge (wi-fi symbol) for the signal, and select "Properties".
Lastly, consider file logging instead of live streaming. At the same time when streaming the signal at a lower rate in SDI, you can log the signals via a File Log block which will preserve the original sample time of the signal. File logging is capable of logging higher data rates without dropping data. More information on File Logs can be found at:https://www.mathworks.com/help/slrealtime/io_ref/filelog.html
In some rare cases, you may see live stream overload warnings although no data is being streamed to the development computer. This can be caused by hardware/network issues, for example, a faulty USB-Ethernet adaptor.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!