【正文】
applications, and have options for how to use your data. 3. Organizing and Managing Your Data with DataFinder Technology With many applications, the amount of data being collected can quickly bee overwhelming. Typically, at that point, you might turn to a database to begin storing your data for faster search and trending. National Instruments makes it easy to interact with a database using the LabVIEW Database Connectivity Toolkit by abstracting the lowlevel structured query language (SQL) queries. However, moving your existing data to a database, maintaining the database, and creating applications for accessing 4 data can bee extremely costly and timeconsuming. In response to this challenge, NI developed NI DataFinder technology, included in the LabVIEW DataFinder Toolkit and DIAdem, for managing test files without the headache and expense of setting up and maintaining a large database. With NI DataFinder, you can perform Interlike searches across all your data files, regardless of format and location within your pany intra. Simply point NI DataFinder to the location of your data files, and within seconds you can search for your files just as you would search for information on the Inter. NI DataFinder automatically builds and maintains an index of all files that meet the file type and location criteria in the NI DataFinder configuration. You can use properties automatically stored in the NI DataFinder index in query conditions. When a valid data file is created, deleted, or edited, NI DataFinder automatically notices and reindexes the hierarchy and properties of the file. When you save properties not yet in NI DataFinder in a newly created file, these properties are automatically added to the index. NI DataFinder dynamically manages its own data tables and updates them based on file events and the contents of each file. Therefore, unlike many expensive database solutions, you can change and add information as your needs change without redesigning your data management solution. Using the NI DataFinder, you can quickly find trends and correlations in the large amounts of data you have saved during your tests. Programming Approaches in NI LabVIEW NI LabVIEW is a graphical dataflow programming environment. When using dataflow in LabVIEW, you define an execution flow in code by creating diagrams that show how data moves between functions (known as virtual instruments, or VIs). However, with LabVIEW, you can bine multiple programming approaches besides graphical data flow (G) in a single application. Use this flexibility to select your tool of choice for creating algorithms and solving an infinite variety of engineering problems. (1)Defining Programming Approaches The phrase ?programming approaches? enpasses different languages for programming, models of putation, levels of abstraction, methods for interacting with existing code, and ways for representing algorithms. Over the years, National Instruments has added interfaces and methods for munication in LabVIEW to extend the number of approaches that are can write and import multiple 5 approaches into the same block diagram as the familiar G dataflow language. LabVIEW piles all of these approaches for the appropriate hardware target, which can span desktop puters, realtime OSs, fieldprogrammable gate arrays (FPGAs), mobile devices, and embedded processors such as (2)Programming in G Data flow, the fundamental LabVIEW programming method, was the original, and only, programming approach when NI introduced LabVIEW in 1986. Unlike sequentialstyle programming, the flow of data in a dataflow program dictates when, and in what order, operations are executed. In sequential languages such as C and C++, the order of the mands in the source code (as opposed to the availability of data) determines the order in which execution will occur. G follows a dataflow model for running functions and primitives, or VIs. A block diagram function or node executes when all its inputs are available. When a node pletes execution, it supplies data to its output terminals and passes the output data to the next node in the dataflow path. Figure 3. A and B are added, and the result is multiplied by C and displayed. The graphical code in Figure 2 shows how a mathematical equation can be represented in G. This diagram consists of two nodes (an add node and a multiply node), and has three numerical inputs (A, B, and C). First, A and B are added. The multiplication node does not execute until both inputs are provided, so it depends on the addition node to plete and provide the result of A + B, at which point it putes the result – (A+B)*C. Although it is possible to explicitly define variables in G, one of the most obvious differences between G code and other languages is that the functional equivalent of a traditional variable is a wire. Instead of passing variables between functions, wires define the functions to which a value is passed. Other familiar programming concepts such as While Loops, For Loops, conditional code, callback functions, and digital logic are all part of the G dataflow programming language 6 (3)Using ConfigurationBased Programming In 2021, National Instruments released NI LabVIEW 7 Express, which featured Express VIs – a new technology designed to further simplify mon programming tasks and algorithm creation. Unlike traditional VIs, Express VIs abstracted tasks by offering a configurationbased approach to programming. LabVIEW distinguishes Express VIs with large blue icons. When you place an Express VI on the block diagram, a dialog appears so you can configure how the function executes. After pleting the configuration, the LabVIEW development environment writes the necessary code (represented by the Express VI) for you. You can view and modify this