Introduction To LabVIEW 8 in 6 Hours
Introduction To LabVIEW 8 in 6 Hours
Introduction To LabVIEW 8 in 6 Hours
6-Hour Hands-On
Simulation and Prototyping Design And more Control Automatic Controls and Dynamic Systems Mechatronics and Robotics And more Measurements Circuits and Electronics Measurements and Instrumentation And more
Prototype
Deploy
Desktop PC
Laptop PC
PDA
High-Speed High-Resolution Multifunction Dynamic Instrument Digitizers and DMMs Data Acquisition Signal Acquisition Control Digitizers
Digital I/O
Counter/ Timers
Machine Vision
Motion Control
B. LabVIEW Environment
Front Panel / Block Diagram Toolbar /Tools Palette
D. Additional Help
Finding Functions Tips for Working in LabVIEW
Track B
Sound Card
Track C
Instruments*
20kS/s2 GS/s 1224 bit some
AI Channels
AO Channels AC or DC Triggering Calibrated
2
2 AC
816
12 AC/DC x x
1680
24 AC/DC x x
2
0 AC/DC x x
* The above table may not be representative of all device variations that exist in each category
What is MAX?
MAX stands for Measurement & Automation Explorer. MAX configures and organizes all your National Instruments DAQ, PCI/PXI instruments, GPIB, IMAQ, IVI, Motion, VISA, and VXI devices. Used for configuring and testing devices.
Icon Found on Windows Desktop
Track A
Track B
Track C
Un-Mute Microphone
Startup Screen:
Start from a Blank VI:
NewBlank VI
or
Start from an Example:
ExamplesFind Examples
Controls Palette (Place items on the Front Panel Window) (Controls & Indicators)
Control: Numeric Customize Palette View
Status Toolbar
Run Button Continuous Run Button Abort Execution
Demonstration 1: Creating a VI
Front Panel Window
Graph Indicator
Block Diagram Window
Output Terminal
Boolean Control
Input Terminals
Dataflow Programming
Block diagram execution
Dependent on the flow of data Block diagram does NOT execute left to right
Node executes when data is available to ALL input terminals Nodes supply data to all output terminals when done
Debugging Techniques
Finding Errors
Click on broken Run button. Window showing error appears.
Execution Highlighting
Click on Execution Highlighting button; data flow is animated using bubbles. Values are displayed on wires.
Probes
Right-click on wire to display probe and it shows data as it flows through wire segment. You can also select Probe tool from Tools palette and click on wire.
Track A&B
Track C
Loops
While Loops
i terminal counts iteration Always runs at least once Runs until stop condition is met
While Loop
For Loops
i terminal counts iterations Run according to input N of count terminal
For Loop
Drawing a Loop
2. Enclose code to be repeated
Standard VIs: modularized VIs customized by wiring (customizable) Functions: fundamental operating elements of LabVIEW; no front panel or block diagram (yellow)
Signal and Data Simulation Acquire and Generate Real Signals with DAQ Instrument I/O Assistant (Serial & GPIB) ActiveX for communication with other programs
Signal Processing Statistics Advanced Math and Formulas Continuous Time Solver
Analysis
Storage
File I/O
Track A,B,&C
Track A&B
Track C
(a)
(b)
2. Select
(c)
File I/O
File I/O Allows recording or reading data in a file. LabVIEW creates or uses the following file formats: Binary: underlying file format of all other file formats ASCII: regular text files LVM: LabVIEW measurement data file TDM: created for National Instruments products
Track A,B,C
Spreadsheet Formatting
Spreadsheet files are ASCII files with a certain formatting
Usually tabs between columns and end of line constants between rows LabVIEW includes VIs that perform this formatting or a string can be concatenated
B. Signal Processing
MathScript Arrays Clusters Waveforms
Boolean Data
Buttons and LEDs
Decorations
Tab Control Arrows
Other
Strings and text boxes Picture/Image Display ActiveX Controls
1D Array 012345
Auto-Indexing Disabled
Wire remains the same size
2. Timed Loops
Configure special timed While loop for desired dt.
Time Delay
Timed Loop
Properties Include:
Size Color Plot Style Plot color
Features include:
Cursors Scaling
Track A,B,&C
(FunctionsProgramming StructuresMathScript)
Variable Workspace
View/Modify Variable Contents
User Commands
m-file Script
(LabVIEWToolsMathScript Window)
Track A,B,&C
Use the MathScript Node and Interactive Window to process the acquired signal (logarithmic decay) in the MathScript and save the script.
Track A,B,&C
Introduction to Clusters
Data structure that groups data together Data may be of different types Analogous to struct in C Elements must be either all controls or all indicators
Creating a Cluster
1. Select a Cluster shell.
Cluster Functions
In the Cluster & Variant subpalette of the Programming palette Can also be accessed by right-clicking the cluster terminal
Bundle By Name
Initial Value
Value 3
First Iteration
Second Iteration
Last Iteration
Create SubVI
Enclose area to be converted into a subVI. Select EditCreate SubVI from the Edit Menu.
State Machines
While Loop Case Structure Shift Register
Local Variables
Local Variables allow data to be passed between parallel loops. A single control or indicator can be read or written to from more than one location in the program Local Variables break the dataflow paradigm and should be used sparingly
Shows the current region of view compared to entire Front Panel or Block Diagram Great for large programs
LabVIEW Project
Group and organize VIs Hardware and I/O management Manage VIs for multiple targets Build libraries and executables Manage large LabVIEW applications Enable version tracking and management
(LabVIEWProjectNew)
Shared Variables
Shared Variables are used to send data between VIs. Variable Types: Single Process: share the data among VIs on the local computer. Network-published: communicate between VIs, remote computers, and hardware through the Shared Variable Engine. Shared Variable must exist within a project library. Shared Variable must be deployed to be available to other projects and remote computers.
GPIB
General Purpose Interface Bus (GPIB) GPIB is usually used in stand alone bench top instruments to control measurements and communicate data Digital 8-bit parallel communication interface IEEE 488.1 and 488.2 define standards for GPIB
Serial
Serial communication transmits one bit at a time over a transmission line Usually does not require external hardware Four parameters: baud rate, data bits, parity bit, stop bits
VISA
Virtual Instrumentation Software Architecture (VISA) High-level API that calls low-level drivers Can control VXI, GPIB, serial, or computer-based instruments Makes appropriate driver calls depending on the instrument used.
Instrument Drivers
Plug and Play drivers are a set of VIs that control a programmable instrument VIs correspond to instrument operation: configuring, triggering, and reading measurements Help getting started since programming protocol for each instrument is already known
IDNET
Instrument Driver Network (IDNET) Instrument Driver Finder within LabVIEW
Tools Instrumentation Find Instrument Drivers Help Find Instrument Drivers
Additional Resources
NI Academic Web & Student Corner
http://www.ni.com/academic
LabVIEW Certification
LabVIEW Fundamentals Exam (free on www.ni.com/academic) Certified LabVIEW Associate Developer Exam (industry recognized certification )
Developer
Advanced LabVIEW knowledge and application development experience Project management skills Certified LabVIEW Developer
Associate Developer
Proficiency in navigating LabVIEW environment Some application development experience
Fundamentals Exam
Pre-Certification Skills Test
4. PCB Layout
5. Test
6. Compare