Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Document Type: Tutorial
NI Supported: Yes
Publish Date: Aug 21, 2009


Feedback


Yes No

Related Categories

Related Links - Developer Zone

Related Links - Products and Services

Introduction to the LabWindows/CVI Run-Time Module for Linux®

9 ratings | 4.00 out of 5
Print

Overview

The LabWindows/CVI Run-Time Module for Linux extends the LabWindows/CVI development environment by allowing developers to create high-performance, stable applications on a Windows system and later compile and run these applications on a Linux® target.

Rapid Development
Quickly create multiplatform applications from the familiar NI LabWindows/CVI integrated development environment and continue to take advantage of a comprehensive ANSI development workspace that incorporates test and measurement-specific libraries, including hardware libraries, comprehensive analysis, and communication and threading utilities.


Tight I/O Integration
Use full-featured hardware drivers to integrate diverse I/O such as analog, digital, dynamic signal acquisition, benchtop instruments, and high-accuracy modular instruments with your Linux® applications.


Platform Versatility
Optimize data acquisition, analysis, and presentation components of test and measurement applications, while creating code that will run on multiple platforms due to the built-in LabWindows/CVI library support and National Instruments driver support for Linux®.

Software Requirements

The LabWindows/CVI Run-Time Module for Linux requires that you first install LabWindows/CVI 5.5 or higher.  If you develop your application in LabWindows/CVI 8.1 or higher, you must use features which are available in version 8.0.1.  LabWindows/CVI 8.0 and LabWindows/CVI 8.0.1 offer the following features:

Learn more about what's new in LabWindows/CVI.

Minimum Hardware Requirements

The LabWindows/CVI Run-Time Module for Linux requires that you have at least 100 MB of free disk space.  In addition, the graphics libraries depend on the following resources: libX11.so.6 and libXext.so.6.

Supported Linux® Distributions


The LabWindows/CVI Run-Time Module for Linux has been validated on the following distributions:

  • Red Hat Enterprise Linux WS 4
  • Red Hat Enterprise Linux WS 3
  • SUSE Linux 10.1
  • SUSE Linux 10.0
  • Mandrakelinux 10.1 Official
  • Mandriva Linux 2006

This support is provided for 32-bit, x86 platforms only.

Visit ni.com/linux to review the distributions supported by National Instruments.

Supported Software Libraries

The ANSI C, User Interface, Advanced Analysis, Formatting and I/O, Utility, GPIB, VXI, RS-232, TCP Support, and Internet libraries are generally supported on Linux.

The ActiveX, DDE Support, DataSocket, DIAdem Connectivity, .NET, and Easy I/O for DAQ (Traditional DAQ driver) libraries are not supported on Linux.

Library Support
Windows
Linux
User Interface Library
X
X*
Advanced Analysis Library
X
X
Formatting and I/O Library
X
X
Utility Library
X
X*
ANSI C Library
X
X*
NI-DAQmx Library
X
X
VXI Library
X
X
GPIB 488.2 Library
·X
X
RS-232 Library
X
x*
VISA Library
X
X
TCP Support Library
X
X
Internet Library
X
X
DDE Support Library
X
ActiveX Library
X
DIAdem Connectivity Library
X
.NET Library
X
Datasocket Library
X
Programmer’s Toolbox
X
X


X - Fully supported
X* - Generally supported (some functions are not supported or exhibit different behavior)

After installing the Linux Run-Time Module, refer to the Differences in LabWindows/CVI between Windows and Linux LabWindows/CVI Help topic for a full list of supported libraries and functions.

 

Hardware Support for Linux®

National Instruments offers more than 200 measurement and control devices for LabWindows/CVI applications running on the Linux platform.

 



Specifically, National Instruments offers driver software for developing applications with both PXI- and PCI-based modular instruments in Linux. In addition, we provide support for our popular VXI controllers and NI GPIB bus controllers, and three levels of driver software for developing applications with more than 200 plug-in data acquisition products.

See Also:
NI Test and Measurement Products for Linux

Frequently Asked Questions

Q: What are the key features of the LabWindows/CVI 8.0 Run-Time Module for Linux?
The LabWindows/CVI Run-Time Module for Linux provides LabWindows/CVI libraries for Linux. This allows you to compile and run LabWindows/CVI applications on Linux. The Module does not provide a LabWindows/CVI interactive development environment (IDE) for Linux.

 


Q: Can I port any existing LabWindows/CVI application to Linux?
You can port existing LabWindows/CVI applications to Linux as long as the application does not use any of the unsupported library functions. In general, following a few simple guidelines assures the portability of a LabWindows/CVI application:

  • Write code in strict ANSI C
  • Observe and repair all LabWindows/CVI compile, link, and run-time diagnostics
  • Avoid using system-dependent calls when possible
  • Avoid using non-portable image formats and fonts in your user interface.

After installing the Linux Run-Time Module, refer to the Building Multiplatform Applications LabWindows/CVI Help topic for tips and guidelines on how to write platform independant LabWindows/CVI applications.

 


Q: How do I install the module?
You can install the Linux Run-Time Module by running the INSTALL script that is provided. The INSTALL script ensures that all software requirements are met. LabWindows/CVI by default will be installed under the following locations:

  • \usr\local\natinst\cvi80
  • \usr\local\lib

 


Q: How do I build and run my LabWindows/CVI project?
Once you have developed and sufficiently tested your application on Windows, you must copy your project, including source files, to a Linux machine. You then re-compile your files on Linux. Use the cvicc command to build a LabWindows/CVI project or compile a source file.

The following commands are available:

Command Action
cvicc Shows the command syntax. Adding -help and -? also displays the command syntax.
cvicc project.prj Builds the release target of project.prj.
cvicc project.prj project2.prj Builds the release targets of project.prj and project2.prj.
cvicc file.c Compiles file.c with default build options.
cvicc file.c file2.c Compiles file.c and file2.c with default build options.
cvicc file.c project.prj Compiles file.c with build options you set for project.prj. file.c does not need to be included in project.prj. project.prj is not built.
cvicc file.c file2.c project.prj Compiles file.c and file2.c with build options you set for project.prj. The source files do not need be included in project.prj. project.prj is not built.

You can pass any number of source files to be compiled at one time. You can pass any number of projects to be built at one time. If you specify any number of source files, you can specify only one project file.

The compiler returns 0 if all targets are created successfully. If there is any error creating the target or the build could not start, the compiler returns -1.

The following additional arguments are available:

 

Command Action
-debug Creates the debuggable version of the target. This argument applies only for building projects.
-rebuild Forces LabWindows/CVI to recompile all source files you specify and all source files in projects you specify.
-log logfile Copies all build output to the logfile you specify.
/DDEFINE Adds additional compiler defines to any compiler defines that are set in the project. You can specify multiple defines.

For more information about the cvicc command, refer to the Building a Linux Application help topic.

 


Q: How do I debug my LabWindows/CVI application once I have compiled and built it on Linux?
The LabWindows/CVI Run-Time Module for Linux does not include an IDE for Linux. Instead, you should compile your LabWindows/CVI application with cvicc using the debug switch. You can then use any of the debugging tools that are available on Linux like ddd or gdb to debug your application.

 


Q: Where is the documentation installed on Linux?
The readme.txt is installed under <installdir>/natinst/cvi80. The readme provides installation instructions as well as information about building LabWindows/CVI projects and known issues. Use a web browser to view the LabWindows/CVI Run-Time Module for Linux Help at <InstallDir>/natinst/cvi80/help/index.htm. The documentation includes a reference for supported functions on Linux.

 


Q: Where can I purchase the LabWindows/CVI Run-Time Module for Linux?
Visit the LabWindows/CVI Run-Time Module for Linux product page.

 


Q: Do I need to purchase run-time licenses for every LabWindow/CVI Linux application I deploy?
You do not need additional deployment licenses for distributing applications that were created using the LabWindows/CVI Run-Time Module for Linux.

LabWindows/CVI Resource Page

Conclusion

LabWindows/CVI continues a history of innovation with the new Run-Time Module for Linux that allows ANSI C programmers to create stable test and measurement applications that run on Windows and Linux targets using a variety of commercial-of-the-shelf (COTS) hardware.

Linux® is the registered trademark of Linus Torvalds in the U.S. and other countries.

Related Links:
See the latest pricing information - LabWindows/CVI Run-Time Module for Linux
NI Test and Measurement Products for Linux
LabWindows/CVI Resource Page
KnowledgeBase 3XAAMQV4: What Linux Distributions Do National Instruments Drivers and Software Support?

Downloads

linuxhelpfiles.zip

9 ratings | 4.00 out of 5
Print

Reader Comments | Submit a comment »

WindowsCVI on Ubuntu Linux
I'd like to see WindowsCVI full development capability running on Linux from Red Hat, Ubuntu, etc. But again, the product name clearly spells Windows, so maybe this will never happen?
- juswanto wardojo, google. anon9397414 - Jul 15, 2009

Eval still needed
Evaluation version would be great to see if this is what is needed.
- Feb 26, 2008

Why not an eval version for Linux
Why not an eval version for Linux? I cannot see now if it's what I need.
- May 3, 2007

CVIcc versus gcc
Nice, although a bit late. I had rather seen support of the gcc compiler and not some cvi specific c compiler. Just the graphics libraries and hardware drivers together with gcc, because this could make cvi immediately interface with realtime operating systems like rtai.
- Mar 30, 2007

Evaluation version desparately needed...
It would be highly recommended to have an evaluation version to play with, even if it is a limited-capability version. Without it, there may not be enough CVI developers out there who could make a strong argument to their superiors to make a purchase. I assume that even if a general download is not provided, that an evaluation version could be made available from a local NI app-engineer. I've asked twice, and was disappointed both times.
- Dec 6, 2006

Tell more on hardware requirements
CVI on Linux is for sure something a lot of people have waited for. As Linux is often used on small machines or even embedded systems it would be very nice to get the minimum hardware requirements for CVI on Linux. What graphics library does CVI for Linux use? What minimum CPU power/memory´/disk space is needed? Thank You !
- Lutz H, Thorlabs GmbH. lhoerl@thorlabs.com - Nov 16, 2006

CVI on Linux
its great you haven taken the path to Linux. I am looking forward to see the entire CVI product running on Linux, including the complete IDE. In future I would like to get rid of all Microsoft OS. Best regards Andy
- Andreas Wittmann, Willtek. andreas.wittmann@willtek.com - Nov 14, 2006

 

Legal
This tutorial (this "tutorial") was developed by National Instruments ("NI"). Although technical support of this tutorial may be made available by National Instruments, the content in this tutorial may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this content with each new revision of related products and drivers. THIS TUTORIAL IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).