1、安徽理工大学毕业设计外文翻译 共 25 页第 1 页 National Instruments LabVIEW: A Programming Environment for Laboratory Automation and Measurement . National Instruments LabVIEW is a graphical programming language that has its roots in automation control and data acquisition. Its graphical representation, similar to a pr
2、ocess flow diagram, was created to provide an intuitive programming environment for scientists and engineers. The language has matured over the last 20 years to become a general purpose programming environment. LabVIEW has several key features which make it a good choice in an automation environment
3、. These include simple network communication, turnkey implementation of common communication protocols (RS232, GPIB, etc.), powerful toolsets for process control and data fitting, fast and easy user interface construction, and an efficient code execution environment. We discuss the merits of the lan
4、guage and provide an example application suite written in-house which is used in integrating and controlling automation platforms. Keywords: NI LabVIEW ; graphical programming ;system integration ; instrument control ; component based architecture ; robotics ; automation ; static scheduling ; dynami
5、c scheduling ; database. Introduction Cytokinetics is a biopharmaceutical company focused on the discovery of small molecule therapeutics that target the cytoskeleton. Since inception we have developed a robust technology infrastructure to support our drug discovery efforts. The infrastructure provi
6、des capacity to screen millions of compounds per year in tests ranging from multiprotein biochemical assays that mimic biological function to 安徽理工大学毕业设计外文翻译 共 25 页第 2 页 automated image-based cellular assays with phenotypic readouts. The requirements for processing these numbers and diversity of assa
7、ys have mandated deployment of multiple integrated automation systems. For example, we have several platforms for biochemical screening, systems for live cell processing, automated microscopy systems, and an automated compound storage and retrieval system. Each in-house integrated system is designed
8、 around a robotic arm and contains an optimal set of plate-processing peripherals (such as pipetting devices, plate readers, and carousels) depending on its intended range of use. To create the most flexible, high performance, and cost-effective systems, we have taken the approach of building our ow
9、n systems in-house. This has given us the ability to integrate the most appropriate hardware and software solutions regardless of whether they are purchased from a vendor or engineered de novo, and hence we can rapidly modify systems as assay requirements change. To maximize platform consistency and
10、 modularity, each of our 10 automated platforms is controlled by a common, distributed application suite that we developed using National Instruments (NI) LabVIEW. This application suite described in detail below, enables our end users to create and manage their own process models (assay scripts) in
11、 a common modeling environment, to use these process models on any automation system with the required devices, and allows easy and rapid device reconfiguration. The platform is supported by a central Oracle database and can run either statically or dynamically scheduled processes. NI LabVIEW Backgr
12、ound LabVIEW, which stands for Laboratory Virtual Instrumentation Engineering Workbench is a graphical programming language first released in 1986 by National Instruments (Austin, TX). LabVIEW implements a dataflow paradigm in which the 安徽理工大学毕业设计外文翻译 共 25 页第 3 页 code is not written, but rather draw
13、n or represented graphically similar to a flowchart diagram Program execution follows connector wires linking processing nodes together. Each function or routine is stored as a virtual instrument (VI) having three main components: the front panel which is essentially a form containing inputs and con
14、trols and can be displayed at run time, a block diagram where the code is edited and represented graphically, and a connector pane which serves as an interface to the VI when it is imbedded as a sub-VI. Figure 1. Example NI LabVIEW VI. 安徽理工大学毕业设计外文翻译 共 25 页第 4 页 The top panel (A) shows the front pan
15、el of the VI. Input data are passed through “Controls” which are shown to the left. Included here are number inputs, a file path box, and a general error propagation cluster. When the VI runs, the “Indicator” outputs on the right of the panel are populated with output data. In this example, data inc
16、lude numbers (both as scalar and array), a graph, and the output of the error cluster. In the bottom panel (B) the block diagram for the VI is shown. The outer case structure executes in the “No Error” case (VIs can make internal errors or if called as a sub-VI the caller may propagate an error thro
17、ugh the connector pane).Unlike most programming languages, LabVIEW compiles code as it is created thereby providing immediate syntactic and semantic feedback and reducing the time required for development and testing. 2Writing code is as simple as dragging and dropping functions or VIs from a functi
18、ons palette onto the block diagram within process structures (such as For Loops, or Case Structures) and wiring terminals (passing input values, or references). Unit testing is simplified because each function is separately encapsulated; input values can be set directly on the front panel without ha
19、ving to test the containing module or create a separate test harness. The functions that generate data take care of managing the storage for the data. NI LabVIEW supports multithreaded application design and executes code in an inherently parallel rather than sequential manner; as soon as a function
20、 or sub-VI receives all of its required inputs, it can begin execution. In Figure 1b, all the sub-VIs receive the array input simultaneously as soon as the For Loop is complete, and thus they execute in parallel. This is unique from a typical text-based environment where the control flows line by li
21、ne within a function. When sequential execution is required, control flow can be enforced by use of structures such as Sequences, Events, or by chaining sub-VIs where output data from one VI is passed to the input of the next VI. 安徽理工大学毕业设计外文翻译 共 25 页第 5 页 Similar to most programming languages, LabV
22、IEW supports all common data types such as integers, floats, strings, and clusters (structures) and can readily interface with external libraries, ActiveX components, and .NET framework. As shown in Figure 1b, each data type is graphically represented by wires of different colors and thickness. LabV
23、IEW also supports common configuration management applications such as Visual SourceSafe making multideveloper projects reasonable to manage.Applications may be compiled as executables or as Dynamic Link Libraries (DLLs) that execute using a run-time engine similar to the Java Runtime Environment. T
24、he development environment provides a variety of debugging tools such as break-points, trace (trace), and single-step. Applications can be developed using a variety of design patterns such as Client-Server, Consumer-Producer, and State-Machine. There are also UML (Unified Modeling Language) modeling
25、 tools that allow automated generation of code from UML diagrams and state diagrams. Over the years, LabVIEW has matured into a general purpose programming language with a wider user base. NI LabVIEW as a Platform for Automation and Instrumentation Our experience creating benchtop instrumentation an
26、d integrated automation systems has validated our choice of LabVIEW as an appropriate tool. LabVIEW enables rapid development of functionally rich applications appropriate for both benchtop applications and larger integrated systems. On many occasions we have found that project requirements are init
27、ially ill defined or change as new measurements or new assays are developed. There are several key features of the language that make it particularly useful in an automation environment for creating applications to control and integrate instrumentation, manage process flow, and enable data acquisiti
28、on. 安徽理工大学毕业设计外文翻译 共 25 页第 6 页 Turnkey Measurement and Control Function LabVIEW was originally developed for scientists and engineers .The language includes a rich set of process control and data analysis functions as well as COM, .NET, and shared DLL support. Out of the box, it provides turnkey sol
29、utions to a variety of communication protocols including RS232, GPIB, and TCP/IP. Control structures such as timed While Loops allow synchronized and timed data acquisition from a variety of hardware interfaces such as PCI, USB, and PXI. DataSocket and VI Server Deployment of an integrated system wi
30、th multiple control computers requires the automation control application to communicate remotely with instrument drivers existing on remote computers. LabVIEW supports a distributed architecture by virtue of enabling seamless network communication through technologies such as VI Server and DSTP (da
31、ta sockets transfer protocol). DSTP is an application layer protocol similar to http based on Transmission Control Protocol/Internet Protocol (TCP/IP). Data sockets allow easy transfer of data between remote computers with basic read and write functions. Through VI server technology, function calls
32、can be made to VIs residing on remote computers as though they are residing on the local computer. Both Datasockets and VI server can be configured to control accesses privileges. Simple User Interface (UI) Implementation In addition to common interface controls such as text boxes, menu rings, and c
33、heck-boxes, LabVIEW provides a rich set of UI controls (switches, LEDs, gauges, array controls, etc.) that are pertinent to laboratory equipment. These have their origins in LabVIEWs laboratory roots and help in development of interfaces which 安徽理工大学毕业设计外文翻译 共 25 页第 7 页 give scientists a clear under
34、standing of a systems state. LabVIEW supports UI concepts including subpanels (similar to the Multiple Document Interface), splitter bars, and XControls (analogous to OCX controls). Multithreaded Programming Environment The inherent parallel environment of LabVIEW is extremely useful in the control
35、of laboratory equipment. Functions can have multiple continuous While Loops where one loop is acquiring data rapidly and the other loop processes the data at a much slower rate. Implementing such a paradigm in other languages requires triggering an independent function thread for each process and de
36、veloping logic to manage synchronization. Through timed While Loops, multiple independent While Loops can be easily synchronized to process at a desired period and phase relative to one another. LabVIEW allows invoking multiple instances of the same function with each maintaining its own data space.
37、 For instance, we could drag many instances of the Mean sub-VI onto the block diagram in Figure 1b and they would all run in parallel, independent of one another. To synchronize or enforce control flow within the dataflow environment, LabVIEW also provides functions such as queues, semaphores, and n
38、otification functions. NI LabVIEW Application Example: The Open System Control Architecture (OSCAR) OSCAR is a LabVIEW-based (v7.1) automation integration framework and task execution engine designed and implemented at Cytokinetics to support application development for systems requiring robotic tas
39、k management. OSCAR is organized around a centralized Oracle database which stores all instrumentation configuration information used to logically group devices together to create integrated systems 安徽理工大学毕业设计外文翻译 共 25 页第 8 页 (Fig. 2). The database also maintains Process Model information from which
40、 tasks and parameters required to run a particular process on a system can be generated and stored to the database. When a job is started, task order and parameter data are polled by the Execution Engine which marshals tasks to each device and updates task status in the database in real time. Mainta
41、ining and persisting task information for each system has two clear benefits. It allows easy job recovery in the event of a system error, and it also provides a process audit trail that can be useful for quality management and for troubleshooting process errors or problems. Figure 2. OSCAR component
42、 diagram. 安徽理工大学毕业设计外文翻译 共 25 页第 9 页 Each OSCAR component is distributed across the company intranet and communicates with a central database. Collections of physical devices controlled through OSCAR Instrument packages (OIP) make up systems. Users interact with systems through one of the several ap
43、plications built on OSCAR. Each application calls the RTM which marshals tasks from the database to each OIP. OSCAR has sets of tools for managing system configurations, creating Process Models, monitoring running processes, recovering error-state systems, and managing plate inventory in storage dev
44、ices.OSCAR uses a loosely coupled distributed component architecture, enabled in large part by LabVIEWs DSTP and remote VI technologies that allow system control to be extended beyond the confines of the traditional central control CPU model. Any networked computer or device can be integrated and co
45、ntrolled in an OSCAR system regardless of its physical location. This removes the proximity constraints of traditional integrated systems and allows for the utilization of remote data crunchers, devices, or even systems. The messaging paradigm used shares many similarities with current Service Orien
46、ted Architectures or Enterprise Service Bus implementations without a lot of required programming overhead or middleware; a centralized server is not required to direct the XML packets across the network. An additional benefit to this loosely coupled architecture is the flexibility in front-end appl
47、ication design. OSCAR encapsulates and manages all functionality related to task execution and device control, which frees the developer to focus on the unique requirements of a given application. For example, an application being created for the purpose of compound storage and retrieval can be limi
48、ted in scope to requirements such as inventory management and LIMS integration rather than device control, resource allocation, and task synchronization. 安徽理工大学毕业设计外文翻译 共 25 页第 10 页 The OSCAR integration framework consists of multiple components that enable device and system configuration, process m
49、odeling, process execution, and process monitoring. Below are descriptions of key components of the framework. Integration Platform The Oscar Instrument Package (OIP) is the low level control component responsible for communicating with individual devices. It can support any number of devices on a system (including multiple independent instances of the same type of device) and communicates to the Run