【正文】
:P67258 14LABVIEW Function Manual. USA : National Instruments 15 徐云峰 ,張世慶 .基于聲卡的數(shù)據(jù)采集系統(tǒng)設(shè)計 .機械設(shè)計與制造 .2020:46— 47 31 附錄 附錄 A 英文 原文 July 2020 Edition, Part Number 370178A01 Wele to the LabVIEW Tutorial. This interactive help file introduces you to basic LabVIEW concepts and guides you through several activities to familiarize you with graphical programming. What is LabVIEW? LabVIEW (Laboratory Virtual Instrument Engineering Workbench) is a development environment based on graphical programming. LabVIEW uses terminology, icons, and ideas familiar to technicians, scientists, and engineers, and relies on graphical symbols rather than textual language to describe programming actions. LabVIEW is integrated fully for munication with hardware such as GPIB, VXI, RS232, RS485, and plugin data acquisition boards. LabVIEW also has builtin libraries for using software standards such as TCP/IP Networking and ActiveX. Virtual Instruments: The LabVIEW applications you create. The basic files you create with LabVIEW are called Virtual Instruments, or VIs. Each VI consists of two main parts— he front panel and the block diagram— and a third part— he icon and connector. Tools Palette Use the Tools palette to modify the contents of the front panel and block diagram. Each icon on the Tools palette changes the behavior of the cursor in LabVIEW so you can perform positioning, operating, and editing tasks on your VIs. (1) Front Panel: The user interface to your virtual instrument. The front panel contains the user interface of your VI. The following image 32 is an example of a front panel window. (2) Block Diagram: The graphical code of your virtual instrument. The block diagram contains the graphical code for your VI. The following image is an example of a block diagram window. In this block diagram, the values passed from the front panel knob controls are added every 500 milliseconds. The results are displayed on the waveform graph when the user presses the Boolean button on the front panel to stop the VI. Figure 1 Figure 2 (3) Icon and Connector: The key to modular design. 33 The icon and connector of a VI are located in the upperright corner of the front panel and block diagram window. The icon is what you see on the block diagram when you use a VI as a subVI. Use the connector to set up the input and output terminals of the VI so you can use it as a subVI in another VI. 3 、 The LabVIEW Environment: A brief overview of the LabVIEW programming model. The basic LabVIEW environment elements are the menus at the top of the front panel and block diagram windows, the toolbar, and the freefloating palettes, which you can place anywhere on the screen. Controls Palette You build a front panel by placing controls and indicators from the Controls palette. Each palette icon represents a subpalette, which contains controls you place on the front control is a front panel object that the user manipulates to interact with the VI. Simple examples of controls are buttons, slides, dials, and text boxes. An indicator is a front panel object that displays data to the user. Examples of indicators are graphs, thermometers, and gauges. When you place a control or indicator on the front panel, a corresponding terminal is placed on the block diagram. Functions Palette You build the block diagram using the terminals from the front panel controls and indicators and the VIs, functions, and structures from the Functions palette. Each palette icon represents a subpalette, which contains VIs and functions you place on the block diagram. The structures, functions, and VIscollectively known as nodeson the Functions palette provide the functionality of your VI. As you add nodes to the block diagram, you wire them to each other and to the terminals from the front panel objects using the Wiring tool, found on the Tools palette. A plete block diagram appears similar to a flowchart. Dataflow: The Basic Concept Behind LabVIEW: An overview of 34 LabVIEW39。s graphical programming model, data flow. Traditional textbased programming relies on topdown design, where you must write lines of code that execute line by line. LabVIEW is based on graphical programming. You do not need an extensive knowledge of programming languages or programming techniques to create virtual instruments. Instead of topdown execution, LabVIEW operates on the concept of data flow. Learning LabVIEW with Activities: A collection of exercises to help you learn LabVIEW concepts. Open and Run a VI Familiarize yourself with the LabVIEW environment. Front Panel This VI simulates a temperature acquisition and analysis application. The VI pares the temperature value to a high and low value and displays the value on the chart, and plots a histogram of the data on another chart. (1) Run the VI by clicking the Run button. The button changes appearance to indicate that the VI is running. (2) Select Window show Tools Palette to display the Tools palette. (3) Use the Operating tool to change the value of the slider in the System Controls section. Notice the speed of the simulated acquisition changes as you change the value. You operate LabVIEW controls just as you would similar real controls. Other ways to operate knob controls using the Operating tool include: .Clicking the slider and dragging it to a new location. .Clicking the black region of the slider to move the slider to the value at the point you clicked. .Clicking the digital display and entering a number. If you use this method, the 35 Enter button appears on the toolbar. LabVIEW does not pass the value to the control until you click this button or press Enter. Block Diagram (1) View the block diagram for the Temperatu