How to access a data store block in a subsystem?

3 visualizaciones (últimos 30 días)
Iman
Iman el 20 de Sept. de 2016
Respondida: Akshat Dalal el 2 de Mzo. de 2025
Hi, I have a model with multiple subsystems. Different subsystems change the value of a specific data in the main subsystem (which will be sent by USB port). Using GOTO block is not possible because multiple GOTOs to a FROM block is not allowed.
Using Data Store block is not very straightforward. Because it is not possible to a write or read a Data Store Block variable from other subsystems. Actually the subsystems do not "see" the Data Store block which resides in another subsystem.
I would like to place all subsystems in a Library, so using Simulink.Signals in Model properties is not possible.
Has anyone any solution for this problem?
Thanks in Advance.

Respuestas (1)

Akshat Dalal
Akshat Dalal el 2 de Mzo. de 2025
Hi Iman,
You could potentially model it as an global DSM with the Simulink.Signal defined in the base workspace. Please refer the following documentation for more information: https://www.mathworks.com/help/simulink/ug/model-global-data-using-data-stores.html
Since MATLAB R2023b, reference DSMs have been introduced which serve the exact purpose you're looking for. You could upgrade to R2023b or later releases if feasible. Please have a look at the following documenation for more information: https://www.mathworks.com/help/simulink/slref/datastorememory.html

Categorías

Más información sobre Large-Scale Modeling en Help Center y File Exchange.

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by