Using Simulink Logic Analyzer with multiple instances of referenced subsystem

5 次查看(过去 30 天)
Hello everyone,
I am trying to use the Logic Analyzer in my Simulink model. The model includes multiple instances of a referenced subsystem. Inside this subsystem I have selected signals for logging. After running the simulation all the selected signals have been logged for all subsystems and appear in the 'logsout' variable and in the Data Inspector. However in the Logic Analyzer only the signals of one subsystem show up and there does not seem to be a way to get the signal of all subsystems.
I have tried to use dsp.LogicAnalyzer to manually display all signals from the logsout variable but dsp.LogicAnalyzer does not seem to support variable sample times. Interpolating all the signals to the smallest sample time is not an option since this would require an enormous amount of ram.
Is there a way to display the signals of all referenced subsystems in the Logic Analyzer?
  1 个评论
Aman
Aman 2023-8-9
Hi Jan,
I understand that you are having a Simulink model which includes multiple instances of a referenced subsystem and you are looking for a way to get signals on Logic Analyzer from all instances of referenced subsystem.
However, currently, Logic Analyzer can stream only a single instance of a multi-instance model block. In this case, you can switch between instances to visualize the logged signals on Logic Analyzer.
To do so, you can follow the below steps:
1. From the Simulink Editor menu, open the "Prepare" gallery on the Simulation tab.
2. Select "Normal Mode Visibility".
3. Select the model instance you want to visualize and then click "OK".
4. Click on "Run" in Logic Analyzer app.
I hope this helps.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Subsystems 的更多信息

产品


版本

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by