Write data to data store
Simulink / Signal Routing
The Data Store Write block copies the value at its input to the named data store. Each write operation performed by a Data Store Write block writes over the data store, replacing the previous contents.
The data store to which this block writes is determined by the location of the Data Store Memory block or signal object that defines the data store. For more information, see Data Stores and Data Store Memory. The size of the data store is set by the signal object or the Data Store Memory block that defines and initializes the data store. Each Data Store Write block that writes to that data store must write the same amount of data.
More than one Data Store Write block can write to the same data store. However, if two Data Store Write blocks attempt to write to the same data store during the same simulation step, results are unpredictable.
Obtaining correct results from data stores requires ensuring that data store reads and writes occur in the expected order. For details, see Order Data Store Access and Data Store Diagnostics.
You can log the values of a local or global data store data variable for all the steps in a simulation. For details, see Log Data Stores.
Data Types |
|
Direct Feedthrough |
|
Multidimensional Signals |
|
Variable-Size Signals |
|
Zero-Crossing Detection |
|