Define data store
Simulink / Signal Routing
The Data Store Memory block defines and initializes a named shared data store, which is a memory region usable by Data Store Read and Data Store Write blocks that specify the same data store name.
The location of the Data Store Memory block that defines a data store determines which Data Store Read and Data Store Write blocks can access the data store:
If the Data Store Memory block is in the top-level system, Data Store Read and Data Store Write blocks anywhere in the model can access the data store.
If the Data Store Memory block is in a subsystem, Data Store Read and Data Store Write blocks in the same subsystem or in any subsystem below it in the model hierarchy can access the data store.
Data Store Read or Data Store Write blocks cannot access a Data Store Memory block that is either in a model that contains a Model block or in a referenced model.
Do not include a Data Store Memory block in a For Each subsystem.
Obtaining correct results from data stores requires ensuring that data store reads and writes occur in the expected order. For details, see:
You can use Simulink.Signal
objects in addition
to, or instead of, Data Store Memory blocks to define data stores. A data
store defined in the base workspace with a signal object is a
global data store. Global data stores are accessible to every
model, including all referenced models. See Data Stores for more
information.
You can select a Data Store Read, Data Store Write, or Data Store Memory block to highlight blocks related to it.
Data Types |
|
Direct Feedthrough |
|
Multidimensional Signals |
|
Variable-Size Signals |
|
Zero-Crossing Detection |
|
Data Store Read | Data Store Write