Why does it take so long to stop my Speedgoat real-time application?
19 views (last 30 days)
MathWorks Support Team on 30 Nov 2022
Edited: MathWorks Support Team on 30 Nov 2022
Depending on the contents of your model and the features that you use, there may be several reasons why it is taking longer for your real-time application to stop:
(1) Try disabling 'AutoImportFileLog'. This is relevant if you use file logs in your model. By default, these file logs are automatically downloaded into Simulation Data Inspector (SDI) after the simulation stops.
See the following answer for different ways of disabling this feature:https://www.mathworks.com/matlabcentral/answers/1648830-how-can-i-turn-off-the-automatic-import-of-file-logs-in-r2020b-and-beyond
(2) Try disabling 'ExportToBaseWorkspace'. This is relevant if you monitor many signals in SDI while running the real-time simulation. By default, all streamed signals will be exported from SDI to a 'logsout' variable in the MATLAB base workspace after the simulation stops.
>> tg = slrealtime;
If you experience general performance issues with SDI while running a real-time simulation, see the following answer for tips:
(3) Try disabling 'updateAutoSaveParameterSetOnStop'. This is relevant if your model contains a large number of tunable parameters. By default, a parameter set containing the latest values will be stored on the Speedgoat target upon stop.
See the following answer for details about disabling this feature:https://www.mathworks.com/matlabcentral/answers/1813580-why-does-my-speedgoat-real-time-target-take-so-long-to-stop-an-application-occasionally-causing-a-t