Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Memory Function

LabVIEW 2011 Control Design and Simulation Module Help

Edition Date: June 2011

Part Number: 371894F-01

»View Product Info

Owning Palette: Utilities Functions

Requires: Control Design and Simulation Module

Stores the value of the Input signal from the previous iteration of the simulation. Use this polymorphic function to transfer values from one iteration of the Control & Simulation Loop to the next. The data type you wire to the Initial Value input determines the polymorphic instance to use.

Details  Example

Dialog Box Options
Block Diagram Inputs
Block Diagram Outputs

Dialog Box Options

ParameterDescription
ParametersLists all the parameters associated with this function. Select a parameter from this list to configure the parameter. When you select a parameter, the parameter and its associated Parameter source control appear in the Parameter Information section of the configuration dialog box.
PreviewDisplays a graphical preview, if available, of the function output or configuration.
Parameter InformationContains the parameters you can configure for this function. You must select a parameter from the Parameters list to make that parameter and its associated Parameter source control visible in the Parameter Information section of the configuration dialog box.
Parameter sourceSpecifies whether you configure this parameter using the Configuration Dialog Box or a Terminal on the simulation diagram. The default value is Configuration Dialog Box. If you select Terminal, LabVIEW displays an input for that parameter on the simulation diagram, and you can wire values to that input to configure this function programmatically. If you select Configuration Dialog Box, LabVIEW removes that input from the simulation diagram. You then must set the value for this parameter inside the configuration dialog box.
execution typeSpecifies when this function updates. You can choose from the following options:
  • Continuous
  • Continuous(include minor time steps)
  • Discrete
sample period (sec)Specifies the length of the discrete time step, in seconds, of this function. If you enter a value of –1, this function inherits the discrete time step you specify for the simulation diagram. Otherwise, the value of sample period (sec) must be a multiple of the discrete time step you specify for the simulation diagram. The default value of sample period (sec) is 1.
sample skew (sec)Specifies the length of time by which you want to delay the execution of this function. The default value is 0. The value of this parameter must satisfy the following relationship:

0 ≤ sample skew (sec)sample period (sec)

Block Diagram Inputs

ParameterDescription
execution typeSpecifies when this function updates. You can choose from the following options:
  • Continuous
  • Continuous(include minor time steps)
  • Discrete
sample period (sec)Specifies the length of the discrete time step, in seconds, of this function. If you enter a value of –1, this function inherits the discrete time step you specify for the simulation diagram. Otherwise, the value of sample period (sec) must be a multiple of the discrete time step you specify for the simulation diagram. The default value of sample period (sec) is 1.
sample skew (sec)Specifies the length of time by which you want to delay the execution of this function. The default value is 0. The value of this parameter must satisfy the following relationship:

0 ≤ sample skew (sec)sample period (sec)
inputSpecifies the signal to which you want to apply the function.
initial valueSpecifies the value at the first iteration of the Control & Simulation Loop.

Block Diagram Outputs

ParameterDescription
outputReturns the value of the input signal from the previous iteration of the Control & Simulation Loop. On the first iteration of the Control & Simulation Loop, output returns the value of the initial value parameter.

Memory Details

Feedthrough Behavior

For this function, the input input has indirect feedthrough to the output output. All other input/output pairs have direct feedthrough behavior.

Example

Refer to the SimEx memory VI in the labview\examples\Control and Simulation\Simulation\Utilities directory for an example of using the Memory VI.


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit