Contents
  1. Variables
  2. Shift Registers

LabVIEW Study Notes: LabVIEW Study Notes (I): Basic Introduction LabVIEW Study Notes (II): Filter Experiment LabVIEW Study Notes (III): Basic Controls LabVIEW Study Notes (IV): Dynamic Data Types LabVIEW Study Notes (V): Comprehensive Data Type Experiment LabVIEW Study Notes (VI): While Loops and For Loops LabVIEW Study Notes (VII): Variables and Shift Registers LabVIEW Study Notes (VIII): Property Nodes LabVIEW Study Notes (IX): Arrays and Clusters LabVIEW Study Notes (X): Case Structures Other Experiment Records


Variables

  1. Purpose of variables: transfer data between parallel loops
  2. Variable types
TypePurpose
Local variableStores data in front panel controls and indicators
Global variableStores data in a special database accessible by multiple VIs
Functional global variableStores data in a While Loop shift register
Shared variableTransfers data between distributed tasks connected over a network
  1. Local variables for Boolean controls
  • Boolean controls with associated local variables must use switch mechanical actions
  • Boolean latch actions are incompatible with local variables

Shift Registers

  1. Application: Shift registers can transfer data generated by the previous iteration to the next iteration
  2. How to add one: Right-click the loop border to add a shift register
  3. The shift register on the right stores the data at the end of each iteration, while the shift register on the left provides the stored data to the next iteration
  4. Shift register initialization
InitializationProgram execution result
Initialized shift registerThe result is the same no matter how many times the program runs
Uninitialized shift registerThe input is the result of the previous program run, so the output changes with each run