Table of Contents
Memory
The Memory block holds and delays its input by one major timestep. This version supports variable-size signals and discrete sample times.
Library
MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
qc_open_library('quarc_library/Discrete')Description
The Memory block holds and delays its input by one major timestep. The QUARC version of the block acts like both the
MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
qc_open_matlab_help('memory');MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
doc('UnitDelay');To set the initial conditions for a bus signal, either use a scalar for the Initial condition parameter, which will initialize all the bus elements to the same value, or use a MATLAB structure which mirrors the bus signal in the order of the fields, the names of the fields, and the data types of the fields.
Helpful Hints
Variable-size signals
When using the Memory block with variable-size signals in subsystems, make sure any
MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
doc ActionPort;MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
doc EnableMATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
doc TriggerInput Ports
The input signal to be delayed.
Output Ports
The output is the delayed signal.
Data Type Support
This block accepts the built-in Simulink data types, as well as bus signals and variable-size signals. See Using Bus Objects with QUARC for more information on bus signals. See Variable-Size Signals for more information on variable-size signals.
Parameters and Dialog Box
Initial Condition
Specifies the initial value of the output.
Sample Time
The sample time of the block. A sample time of 0 indicates that the block will be treated as a continuous time block. A positive sample time indicates that the block is a discrete time block with the given sample time.
A sample time of -1 indicates that the block inherits its sample time. The default sample time is set to -1 to inherit the sample time.
To use the fundamental sampling time of the model, set the sample time to qc_get_step_size, which is a QUARC function that returns the fundamental sampling time of the model.
Targets
Target Name |
Compatible* |
Model Referencing |
Comments |
---|---|---|---|
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
Last fully supported in QUARC 2018. |
|
Rapid Simulation (RSIM) Target |
Yes |
Yes |
|
S-Function Target |
No |
N/A |
Old technology. Use model referencing instead. |
Normal simulation |
Yes |
Yes |
Copyright ©2024 Quanser Inc. This page was generated 2024-10-17. Submit feedback to Quanser about this page.
Link to this page.