Jump to content

LabVIEW: Difference between revisions

From LabVIEW Wiki
Added text from: National Instruments, "LabVIEW," Connexions, August 12, 2004, http://cnx.org/content/m12192/1.2/.
 
(16 intermediate revisions by 4 users not shown)
Line 1: Line 1:
[[Image:LabVIEW_Logo_Vertical_4c.jpg|right|thumb|200px]]
[[Image:LabVIEW_Logo_Vertical_4c.jpg|right|thumb|200px]]
== What is LabVIEW? ==
== What is LabVIEW? ==
LabVIEW is a fully featured programming language produced by [[National Instruments]]. It is a graphical language quite unique in the method by which code is constructed and saved. There is no text based code as such, but a diagrammatic view of how the data flows through the program. Thus LabVIEW is a much loved tool of the scientist and engineer who can often visualise data flow rather than how a text based conventional programming language must be built to achieve a task.
'''LabVIEW''', short for <u>Lab</u>oratory <u>V</u>irtual <u>I</u>nstrument <u>E</u>ngineering <u>W</u>orkbench, is a fully featured [[Integrated Development Environment (IDE)]] produced by [[National Instruments]]. The programming language is officially named "G" for being graphical even though many refer to the language as LabVIEW. The G language unique in the method by which code is constructed and saved. There is no text based code, but is diagrammatic view of how the data flows through the program. Thus LabVIEW is a much loved tool of the scientist and engineer who can often visualize data flow rather than how a text based conventional programming language must be built to achieve a task.


===Language Overview===
Originally released for the Apple Macintosh in 1986, LabVIEW is commonly used for data acquisition, instrument control, and industrial automation on a variety of operating systems (OSs), including Microsoft Windows, various versions of Unix, Linux, and macOS.  Jeff Kodosky, (a.k.a. the "Father of LabVIEW"), during his keynote address during NIWeek 2017, attempted to create a one line description of LabVIEW, in which he stated:
LabVIEW programs are called virtual instruments, or
VIs, because their appearance and operation imitate
physical instruments, such as oscilloscopes and
multimeters. LabVIEW contains a comprehensive set of tools for
acquiring analyzing, displaying, and storing data, as well as
tools to help you troubleshoot your code.


LabVIEW VIs contain three components-the front
'''''<div style="text-align:center"><q>LabVIEW is an engineering environment for building test, measurement, and control systems using a virtual-instrument based graphical programming language...</q></div>'''''
panel, the block diagram, and the
icon and connector pane.


In LabVIEW, you build a user interface, or front panel, with controls
After feeling this lacked the emotion users felt while using LabVIEW, he went on to add the line:
and indicators. Controls are knobs, push buttons, dials, and
other input devices. Indicators are graphs, LEDs, and other
displays. After you build the user interface, you add code using
VIs and structures to control the front panel objects. The block
diagram contains this code. In some ways, the block diagram
resembles a flowchart.


You can use LabVIEW to communicate with hardware such as data
'''''<div style="text-align:center"><q>...that inspires users to strive for and achieve more than they expected.</q></div>'''''
acquisition, vision, and motion control devices, and GPIB, PXI,
<br>
VXI, RS-232, and RS-484 devices. LabVIEW also has built-in
{{TOCnestright}}
features for connecting your application to the Web using the
LabVIEW Web Server and software standards such as TCP/IP
networking and ActiveX.


Using LabVIEW, you can create test and measurement, data
==Language Overview==
acquisitions, instrument control, datalogging, measurement
===Virtual Instruments (VIs)===
analysis, and report generation applications. You also can
LabVIEW programs are called virtual instruments, or VIs, because their appearance and operation imitate physical instruments, such as oscilloscopes and multimeters. LabVIEW contains a comprehensive set of tools for acquiring, analyzing, displaying, and storing data, as well as tools to help you troubleshoot your code.
create stand-alone executables and shared libraries, like DLLs,
 
because LabVIEW is a true 32-bit compiler.
LabVIEW VIs contain three components:
*the [[Front Panel]]
*the [[Block Diagram]]
*the [[Connector Pane]] (including the VI's Icon):
 
====[[Front Panel]]====
In LabVIEW, you build a user interface on the '''[[Front Panel]]''' with controls and indicators. Controls are knobs, push buttons, dials, and other input devices. Indicators are graphs, LEDs, and other displays. After you build the user interface, you add code using VIs and structures to control the front panel objects.
 
====[[Block Diagram]]====
The '''[[Block Diagram]]''' contains this code. In some ways, the [[Block Diagram|block diagram]] resembles a flowchart showing the dataflow from one [[Programming Elements|element]], or "[[node]]", to the next. 
 
In text based code, the code inside of a programming structure is enclosed by brackets making it difficult to differentiate what is in the structure and what is out.  In LabVIEW this is not the case.  Structures, like: [[While Loop|While Loops]], [[For Loop|For Loops]], and [[Case Structure|Case Structures]] graphically surrounds and encompasses the code that operates within it.
 
====[[Connector Pane]]====
The '''[[Connector Pane]]''' defines the inputs and outputs of the VI by connecting Controls and Indicators from the [[Front Panel|front panel]] to terminals on the Icon.  When the VI is dropped into the [[Block Diagram|block diagram]] of another VI (becoming a SubVI) these terminals are then available to attach wires for inputs and outputs.
 
===Hardware Connectivity===
 
You can use LabVIEW to communicate with hardware such as data acquisition, vision, and motion control devices, and GPIB, PXI, VXI, RS-232, and RS-484 devices. LabVIEW also has built-in features for connecting your application to the Web using the LabVIEW Web Server and software standards such as TCP/IP networking and ActiveX.


==Purchasing==
==Purchasing==
Line 40: Line 41:


== Versions ==
== Versions ==
There are many versions of LabVIEW still in use, although the earlier versions are constrained to hard core dedicated enthusiasts. We have heard whispered mention of the use of Version 3 and there are many active Version 4's in circulation. More recent additions to the legacy software bin are versions 5.0, 5.1, 6.0i and 6.1, while the current version as of December 2007 is 8.5. In addition there are demo versions available from [[National Instruments]], as well as a student versions of 5.0, 6.0 and 7.0 available from Prentice-Hall.
There are many versions of LabVIEW still in use, although the earlier versions are constrained to hard core dedicated enthusiasts. We have heard whispered mention of the use of [[LabVIEW 3.0|Version 3]] and there are many active [[LabVIEW 4.0|Version 4's]] in circulation. More recent additions to the legacy software bin are versions [[LabVIEW 5.0|5.0]], 5.1, [[LabVIEW 6i]] and [[LabVIEW 6i|6.1]], while the current version as of May 2018 is [[LabVIEW 2018]]. In addition there are demo versions available from [[National Instruments]]. Starting in 2017 [[National Instruments]] announced the creation of the next generation of LabVIEW, called LabVIEW NXG. Currently, LabVIEW NXG has had two releases in 2017 and 2018 which comprises [[LabVIEW NXG 1.0]] and [[LabVIEW NXG 2.0|2.0]], respectively.


From version 6.0 onwards NI released the product formerly known as BridgeVIEW as a LabVIEW plugin module called the Data Supervisory and Control module (DSC) and with the advent of [[real time]] boards and the release of the [[Fieldpoint]] real-time network module, there is also a module that allows writing of code for [[Portal:embedded|embedded]] processors referred to as the [[real time|Real Time]] module (RT). Lastly, there are two new additions to the LabVEW world in the [[PDA]] module (for writing code for PocketPC and PalmOS) and the [[FPGA]] module for writing code for Field Programmable Gate Arrays (LabVIEW on a chip!). These modules now keep track with the current LabVIEW version.
From version 6.0 onwards NI released the product formerly known as BridgeVIEW as a LabVIEW plugin module called the Data Supervisory and Control module (DSC) and with the advent of [[real time]] boards and the release of the [[Fieldpoint]] real-time network module, there is also a module that allows writing of code for [[Portal:embedded|embedded]] processors referred to as the [[real time|Real Time]] module (RT). Lastly, there are version available for  [[PDA]] module (for writing code for PocketPC and PalmOS) and the [[FPGA]] module for writing code for Field Programmable Gate Arrays (LabVIEW on a chip!). These modules now keep track with the current LabVIEW version.
 
See more on all of the [[LabVIEW Versions]].


== OS Support ==
== OS Support ==
LabVIEW source code and development is supported by Windows 9x/2000/NT/XP, [[Apple|Apple Macintosh]] (including X), PowerMax OS, Solaris, HP-Unix, Sun, [[Linux]], the Pharlap RTOS, and VxWorks RTOS (Real-Time Operating Systems, found on [[National Instruments]] embedded controllers). Executables can be compiled under their respective development systems to run on these platforms. Code developed under one platform can be ported to any of the others, recompiled and run.
LabVIEW is supported and G source code development can be accomplished on Windows 9x/2000/NT/XP/Vista/7/8/10, [[Apple|Apple Macintosh]] (including X), PowerMax OS, Solaris, HP-Unix, Sun, [[Linux]], the Pharlap RTOS, and VxWorks RTOS (Real-Time Operating Systems, found on [[National Instruments]] embedded controllers). Executables can be compiled under their respective development systems to run on these platforms. Code developed under one platform can be ported to any of the others, recompiled and run<nowiki>*</nowiki>. [[PDA|LabVIEW PDA]] can run on handheld devices, such as Microsoft Windows Mobile for Pocket PC devices.
 
[[PDA|LabVIEW PDA]] can run on handheld devices, such as Microsoft Windows Mobile for Pocket PC devices.


There are of course exceptions to every rule. In this case platform specific sections of the LabVIEW development system will not be transferable. For example, Active X which is Windows 9x/NT specific. Furthermore, certain third party device drivers or LabVIEW toolkits installed under one system may not necessarily run or be recompiled on a different operating system.
<nowiki>*</nowiki>There are of course exceptions to every rule. In this case platform specific sections of the LabVIEW development system will not be transferable. For example, ActiveX or .NET integration which is Windows specific. Furthermore, certain third party device drivers or LabVIEW toolkits installed under one system may not necessarily be available, run, or be recompiled on a different operating system.


== The Future of your LabVIEW Code ==
==Compiling/Creating Executables==
LabVIEW has become widely used in so many applications it is hard to think about it going away. It would only disappear if it stopped being used so widely.


From a message posted to Info-LabVIEW in Feb '97:
Since [[LabVIEW 2.0]], G can compiled directly into executables.  You can also create stand-alone [[DLL/shared library|shared libraries (DLLs)]], [[Packed Project Library|Packed Project Libraries (PPLs)]], and installers.
LabVIEW has both 32-bit and 64-bit versions with applicable compiler for each.  As stated above, except for the listed exceptions, executables can be compiled under their respective development systems to run on the various platforms and "bitnesses".


[quote]> > In buying CINs (or LV code) for that matter one must check the reliability
[[Category:LabVIEW]]
> > of the company and if it will be in business later.  Some responsible
> > companies put their source code in escrow to be given out if the company
> > goes belly up.  Some don't.  What would we all do if NI stopped supporting
> > LV on our favorite platform?  We bought it to run on a given platform and
> > it does but we have a big investment in code now and unlike C I can't go
> > out an buy a "different" compiler!  I guess this begs the question to some
> > one from NI out there.... "Is the source code for LV in escrow or could we
> > be in deep yogurt if NI goes out of business (not that I am suggesting that
> > this is likely!)?"[/quote]


Greg McKaskle writes in response:
== The Future of your LabVIEW Code ==
[quote]
LabVIEW is in active developmentAs of [https://forums.ni.com/t5/LabVIEW/Our-Commitment-to-LabVIEW-as-we-Expand-our-Software-Portfolio/td-p/4101878?profile.language=en November 2020], NI has ceased development of LabVIEW NXG past 2022.
>NI's quarterly report was posted last week, symbol is NATI, and I think
>that you will agree that NI is still growing strongNever-the-less, the
>LV source code is escrowed, and if someone wants details they can
>contact the NI legal department. NI manufacturing is ISO certified and
>all hardware drawings as well as software source code is kept under
>revision control.[/quote]
 
The fact that LV is escrowed and is ISO certified means that it can exist beyond the existence of NI. If this is of interest to you or your company you might want to contact the NI legal department for a letter explaining the exact circumstances that would release the escrow.


== See Also ==
== See Also ==
*[[LabVIEW Bug Reporting]]
*[[LabVIEW Bug Reporting]]
*[[LabVIEW tutorial|LabVIEW Tutorial]]
*[[LabVIEW tutorial|LabVIEW Tutorial]]
*[https://www.ni.com/en-us/support/downloads/software-products.html Download LabVIEW (NI.com/downloads)]


[[category:LabVIEW fundamentals]]
[[Category:LabVIEW fundamentals]]

Latest revision as of 16:46, 9 July 2022

What is LabVIEW?

LabVIEW, short for Laboratory Virtual Instrument Engineering Workbench, is a fully featured Integrated Development Environment (IDE) produced by National Instruments. The programming language is officially named "G" for being graphical even though many refer to the language as LabVIEW. The G language unique in the method by which code is constructed and saved. There is no text based code, but is diagrammatic view of how the data flows through the program. Thus LabVIEW is a much loved tool of the scientist and engineer who can often visualize data flow rather than how a text based conventional programming language must be built to achieve a task.

Originally released for the Apple Macintosh in 1986, LabVIEW is commonly used for data acquisition, instrument control, and industrial automation on a variety of operating systems (OSs), including Microsoft Windows, various versions of Unix, Linux, and macOS. Jeff Kodosky, (a.k.a. the "Father of LabVIEW"), during his keynote address during NIWeek 2017, attempted to create a one line description of LabVIEW, in which he stated:

LabVIEW is an engineering environment for building test, measurement, and control systems using a virtual-instrument based graphical programming language...

After feeling this lacked the emotion users felt while using LabVIEW, he went on to add the line:

...that inspires users to strive for and achieve more than they expected.


Language Overview

Virtual Instruments (VIs)

LabVIEW programs are called virtual instruments, or VIs, because their appearance and operation imitate physical instruments, such as oscilloscopes and multimeters. LabVIEW contains a comprehensive set of tools for acquiring, analyzing, displaying, and storing data, as well as tools to help you troubleshoot your code.

LabVIEW VIs contain three components:

Front Panel

In LabVIEW, you build a user interface on the Front Panel with controls and indicators. Controls are knobs, push buttons, dials, and other input devices. Indicators are graphs, LEDs, and other displays. After you build the user interface, you add code using VIs and structures to control the front panel objects.

Block Diagram

The Block Diagram contains this code. In some ways, the block diagram resembles a flowchart showing the dataflow from one element, or "node", to the next.

In text based code, the code inside of a programming structure is enclosed by brackets making it difficult to differentiate what is in the structure and what is out. In LabVIEW this is not the case. Structures, like: While Loops, For Loops, and Case Structures graphically surrounds and encompasses the code that operates within it.

Connector Pane

The Connector Pane defines the inputs and outputs of the VI by connecting Controls and Indicators from the front panel to terminals on the Icon. When the VI is dropped into the block diagram of another VI (becoming a SubVI) these terminals are then available to attach wires for inputs and outputs.

Hardware Connectivity

You can use LabVIEW to communicate with hardware such as data acquisition, vision, and motion control devices, and GPIB, PXI, VXI, RS-232, and RS-484 devices. LabVIEW also has built-in features for connecting your application to the Web using the LabVIEW Web Server and software standards such as TCP/IP networking and ActiveX.

Purchasing

LabVIEW is developed and sold by National Instruments. This is an American company with distribution via international offices and National Instruments Alliance members. For more details check out the National Instruments Web site

Versions

There are many versions of LabVIEW still in use, although the earlier versions are constrained to hard core dedicated enthusiasts. We have heard whispered mention of the use of Version 3 and there are many active Version 4's in circulation. More recent additions to the legacy software bin are versions 5.0, 5.1, LabVIEW 6i and 6.1, while the current version as of May 2018 is LabVIEW 2018. In addition there are demo versions available from National Instruments. Starting in 2017 National Instruments announced the creation of the next generation of LabVIEW, called LabVIEW NXG. Currently, LabVIEW NXG has had two releases in 2017 and 2018 which comprises LabVIEW NXG 1.0 and 2.0, respectively.

From version 6.0 onwards NI released the product formerly known as BridgeVIEW as a LabVIEW plugin module called the Data Supervisory and Control module (DSC) and with the advent of real time boards and the release of the Fieldpoint real-time network module, there is also a module that allows writing of code for embedded processors referred to as the Real Time module (RT). Lastly, there are version available for PDA module (for writing code for PocketPC and PalmOS) and the FPGA module for writing code for Field Programmable Gate Arrays (LabVIEW on a chip!). These modules now keep track with the current LabVIEW version.

See more on all of the LabVIEW Versions.

OS Support

LabVIEW is supported and G source code development can be accomplished on Windows 9x/2000/NT/XP/Vista/7/8/10, Apple Macintosh (including X), PowerMax OS, Solaris, HP-Unix, Sun, Linux, the Pharlap RTOS, and VxWorks RTOS (Real-Time Operating Systems, found on National Instruments embedded controllers). Executables can be compiled under their respective development systems to run on these platforms. Code developed under one platform can be ported to any of the others, recompiled and run*. LabVIEW PDA can run on handheld devices, such as Microsoft Windows Mobile for Pocket PC devices.

*There are of course exceptions to every rule. In this case platform specific sections of the LabVIEW development system will not be transferable. For example, ActiveX or .NET integration which is Windows specific. Furthermore, certain third party device drivers or LabVIEW toolkits installed under one system may not necessarily be available, run, or be recompiled on a different operating system.

Compiling/Creating Executables

Since LabVIEW 2.0, G can compiled directly into executables. You can also create stand-alone shared libraries (DLLs), Packed Project Libraries (PPLs), and installers. LabVIEW has both 32-bit and 64-bit versions with applicable compiler for each. As stated above, except for the listed exceptions, executables can be compiled under their respective development systems to run on the various platforms and "bitnesses".

The Future of your LabVIEW Code

LabVIEW is in active development. As of November 2020, NI has ceased development of LabVIEW NXG past 2022.

See Also