1 / 14

CS320n –Visual Programming

CS320n –Visual Programming. Introduction to LabVIEW. What We Will Do Today. Look at the LabVIEW programming environment Tests handed back next time and go over in class Assignment 7 on web today. What is LabVIEW. A product of National Instruments

demi
Download Presentation

CS320n –Visual Programming

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CS320n –Visual Programming Introduction to LabVIEW

  2. What We Will Do Today • Look at the LabVIEW programming environment • Tests handed back next time and go over in class • Assignment 7 on web today Introduction to LabVIEW

  3. What is LabVIEW • A product of National Instruments • Designed to provide a programming tool for scientists and engineers to write programs to analyze data gathered by instrumentation • Like Alice it is a graphical programming language • Unlike Alice it can be used to build a much greater variety of programs Introduction to LabVIEW

  4. What is LabVIEW • LabVIEW = Laboratory Virtual Instrument Engineering Workbench • Loaded on the Painter Hall lab computers • Can be downloaded from engineering department web page Introduction to LabVIEW

  5. Creating a LabVIEW program • start LabVIEW • Select the arrow on “New” • On the menu that pops up select “Blank VI” Introduction to LabVIEW

  6. Virtual Instruments • LabVIEW programs are called “VIs” which stands for Virtual Instruments • They consist of two parts • a front panel • a block diagram • The front panel is a graphical user interface • this is how a the user of a program will interact with it • The block diagram is the implementation of the program, the code Introduction to LabVIEW

  7. Working with a Program • I find it best to set up the front panel and block diagram side by side • Select this choosing “Window” and “Tile Left and Right” or by pressing the control key and T at the same time Introduction to LabVIEW

  8. Front Panel and Block Diagram Introduction to LabVIEW

  9. Working with the Front Panel and Block Diagram • In LabVIEW the programmer can add things to either the front panel or the block diagram • right click in either window to select the programming elements (commands, primitives) available Introduction to LabVIEW

  10. Controls and Functions • When you right click in the front panel a pop up menu appears • These are the controls for the front panel • click on the pin to make the pop up menu permanent • the menu on the block diagram contains functions Introduction to LabVIEW

  11. Quick Demonstration of LabVIEW • Write a program in LabVIEW to convert kilometers to miles. • The Milan - San Remo bicycle race was 294 kilometers this year • Add controls and indicators to front panel • Connect controls and indicators in block diagram Introduction to LabVIEW

  12. More Complicated Program • LabVIEW comes with a large number of example programs • Open an existing LabVIEW program by selecting “File” -> “Open” or by pressing the control key and O • Get to National Instruments Folder (probably under Program Files) • LabVIEW 7.0 • examples • express • Moonlanding.vi Introduction to LabVIEW

  13. Moon Landing Simulator – Front Panel Introduction to LabVIEW

  14. Moon Landing Simulator – Block Diagram Introduction to LabVIEW

More Related