National Instruments Measurement Studio User Manual

Measurement Studio
User Manual
Subtitle

Measurement Studio User Manual

TM
April 2008 373392C-01

Support

ni.com

National Instruments Corporate Headquarters

11500 North Mopac Expressway Austin, Texas 78759-3504 USA Tel: 512 683 0100

Worldwide Offices

Australia 1800 300 800, Austria 43 662 457990-0, Belgium 32 (0) 2 757 0020, Brazil 55 11 3262 3599, Canada 800 433 3488, China 86 21 5050 9800, Czech Republic 420 224 235 774, Denmark 45 45 76 26 00, Finland 358 (0) 9 725 72511, France 01 57 66 24 24, Germany 49 89 7413130, India 91 80 41190000, Israel 972 3 6393737, Italy 39 02 41309277, Japan 0120-527196, Korea 82 02 3451 3400, Lebanon 961 (0) 1 33 28 28, Malaysia 1800 887710, Mexico 01 800 010 0793, Netherlands 31 (0) 348 433 466, New Zealand 0800 553 322, Norway 47 (0) 66 90 76 60, Poland 48 22 3390150, Portugal 351 210 311 210, Russia 7 495 783 6851, Singapore 1800 226 5886, Slovenia 386 3 425 42 00, South Africa 27 0 11 805 8197, Spain 34 91 640 0085, Sweden 46 (0) 8 587 895 00, Switzerland 41 56 2005151, Taiwan 886 02 2377 2222, Thailand 662 278 6777, Turkey 90 212 279 3031, United Kingdom 44 (0) 1635 523545
For further support information, refer to the Technical Support and Professional Services appendix. To comment on National Instruments documentation, refer to the National Instruments Web site at the info code
feedback.
ni.com/info and enter
© 2004–2008 National Instruments Corporation. All rights reserved.

Important Information

Warranty

The media on which you receive National Instruments software are warranted not to fail to execute programming instructions, due to defects in materials and workmanship, for a period of 90 days from date of shipment, as evidenced by receipts or other documentation. National Instruments will, at its option, repair or replace software media that do not execute programming instructions if National Instruments receives notice of such defects during the warranty period. National Instruments does not warrant that the operation of the software shall be uninterrupted or error free.
A Return Material Authorization (RMA) number must be obtained from the factory and clearly marked on the outside of the package before any equipment will be accepted for warranty work. National Instruments will pay the shipping costs of returning to the owner parts which are covered by warranty.
National Instruments believes that the information in this document is accurate. The document has been carefully reviewed for technical accuracy. In the event that technical or typographical errors exist, National Instruments reserves the right to make changes to subsequent editions of this document without prior notice to holders of this edition. The reader should consult National Instruments if errors are suspected. In no event shall National Instruments be liable for any damages arising out of or related to this document or the information contained in it.
XCEPT AS SPECIFIED HEREIN, NATIONAL INSTRUMENTS MAKES NO WARRANTIES, EXPRESS OR IMPLIED, AND SPECIFICALLY DISCLAIMS ANY WARRANTY OF
E
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. CUSTOMERS RIGHT TO RECOVER DAMAGES CAUSED BY FAULT OR NEGLIGENCE ON THE PART OF NATIONAL
I
NSTRUMENTS SHALL BE LIMITED TO THE AMOUNT THERETOFORE PAID BY THE CUSTOMER. NATIONAL INSTRUMENTS WILL NOT BE LIABLE FOR DAMAGES RESULTING
FROM LOSS OF DATA, PROFITS, USE OF PRODUCTS, OR INCIDENTAL OR CONSEQUENTIAL DAMAGES, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. This limitation of
the liability of National Instruments will apply regardless of the form of action, whether in contract or tort, including negligence. Any action against National Instruments must be brought within one year after the cause of action accrues. National Instruments shall not be liable for any delay in performance due to causes beyond its reasonable control. The warranty provided herein does not cover damages, defects, malfunctions, or service failures caused by owner’s failure to follow the National Instruments installation, operation, or maintenance instructions; owner’s modification of the product; owner’s abuse, misuse, or negligent acts; and power failure or surges, fire, flood, accident, actions of third parties, or other events outside reasonable control.

Copyright

Under the copyright laws, this publication may not be reproduced or transmitted in any form, electronic or mechanical, including photocopying, recording, storing in an information retrieval system, or translating, in whole or in part, without the prior written consent of National Instruments Corporation.
National Instruments respects the intellectual property of others, and we ask our users to do the same. NI software is protected by copyright and other intellectual property laws. Where NI software may be used to reproduce software or other materials belonging to others, you may use NI software only to reproduce materials that you may reproduce in accordance with the terms of any applicable license or other legal restriction.

Trademarks

National Instruments, NI, ni.com, and LabVIEW are trademarks of National Instruments Corporation. Refer to the Terms of Use section on ni.com/legal for more information about National Instruments trademarks.
®
FireWire
is the registered trademark of Apple Computer, Inc. Other product and company names mentioned herein are trademarks or trade names
of their respective companies.
Members of the National Instruments Alliance Partner Program are business entities independent from National Instruments and have no agency, partnership, or joint-venture relationship with National Instruments.

Patents

For patents covering National Instruments products, refer to the appropriate location: Help»Patents in your software, the patents.txt file on your media, or ni.com/patents.

WARNING REGARDING USE OF NATIONAL INSTRUMENTS PRODUCTS

(1) NATIONAL INSTRUMENTS PRODUCTS ARE NOT DESIGNED WITH COMPONENTS AND TESTING FOR A LEVEL OF RELIABILITY SUITABLE FOR USE IN OR IN CONNECTION WITH SURGICAL IMPLANTS OR AS CRITICAL COMPONENTS IN ANY LIFE SUPPORT SYSTEMS WHOSE FAILURE TO PERFORM CAN REASONABLY BE EXPECTED TO CAUSE SIGNIFICANT INJURY TO A HUMAN.
(2) IN ANY APPLICATION, INCLUDING THE ABOVE, RELIABILITY OF OPERATION OF THE SOFTWARE PRODUCTS CAN BE IMPAIRED BY ADVERSE FACTORS, INCLUDING BUT NOT LIMITED TO FLUCTUATIONS IN ELECTRICAL POWER SUPPLY, COMPUTER HARDWARE MALFUNCTIONS, COMPUTER OPERATING SYSTEM SOFTWARE FITNESS, FITNESS OF COMPILERS AND DEVELOPMENT SOFTWARE USED TO DEVELOP AN APPLICATION, INSTALLATION ERRORS, SOFTWARE AND HARDWARE COMPATIBILITY PROBLEMS, MALFUNCTIONS OR FAILURES OF ELECTRONIC MONITORING OR CONTROL DEVICES, TRANSIENT FAILURES OF ELECTRONIC SYSTEMS (HARDWARE AND/OR SOFTWARE), UNANTICIPATED USES OR MISUSES, OR ERRORS ON THE PART OF THE USER OR APPLICATIONS DESIGNER (ADVERSE FACTORS SUCH AS THESE ARE HEREAFTER COLLECTIVELY TERMED “SYSTEM FAILURES”). ANY APPLICATION WHERE A SYSTEM FAILURE WOULD CREATE A RISK OF HARM TO PROPERTY OR PERSONS (INCLUDING THE RISK OF BODILY INJURY AND DEATH) SHOULD NOT BE RELIANT SOLELY UPON ONE FORM OF ELECTRONIC SYSTEM DUE TO THE RISK OF SYSTEM FAILURE. TO AVOID DAMAGE, INJURY, OR DEATH, THE USER OR APPLICATION DESIGNER MUST TAKE REASONABLY PRUDENT STEPS TO PROTECT AGAINST SYSTEM FAILURES, INCLUDING BUT NOT LIMITED TO BACK-UP OR SHUT DOWN MECHANISMS. BECAUSE EACH END-USER SYSTEM IS CUSTOMIZED AND DIFFERS FROM NATIONAL INSTRUMENTS' TESTING PLATFORMS AND BECAUSE A USER OR APPLICATION DESIGNER MAY USE NATIONAL INSTRUMENTS PRODUCTS IN COMBINATION WITH OTHER PRODUCTS IN A MANNER NOT EVALUATED OR CONTEMPLATED BY NATIONAL INSTRUMENTS, THE USER OR APPLICATION DESIGNER IS ULTIMATELY RESPONSIBLE FOR VERIFYING AND VALIDATING THE SUITABILITY OF NATIONAL INSTRUMENTS PRODUCTS WHENEVER NATIONAL INSTRUMENTS PRODUCTS ARE INCORPORATED IN A SYSTEM OR APPLICATION, INCLUDING, WITHOUT LIMITATION, THE APPROPRIATE DESIGN, PROCESS AND SAFETY LEVEL OF SUCH SYSTEM OR APPLICATION.

Contents

About This Manual
How To Use This Manual..............................................................................................ix
Conventions ...................................................................................................................x
Chapter 1 Introduction to Measurement Studio
Installation Requirements ..............................................................................................1-2
Driver Support.................................................................................................1-3
Deployment Requirements ............................................................................................1-3
Installation Instructions..................................................................................................1-3
Installing Hardware Drivers for Visual Studio 2008 Support .........................1-4
Installing Hardware Drivers for Visual Studio 2005 Support .........................1-5
Installing the Current Version of Measurement Studio over
Previous Versions of Measurement Studio ..................................................1-6
Measurement Studio Package Comparison Chart .........................................................1-6
Learning Measurement Studio.......................................................................................1-9
Chapter 2 Measurement Studio .NET Class Libraries
Measurement Studio Support for Visual Studio .NET Class Library Overview ...........2-1
Analysis .........................................................................................................................2-2
Standard Analysis............................................................................................2-2
Professional Analysis ......................................................................................2-2
Enterprise Analysis..........................................................................................2-3
Common.........................................................................................................................2-13
Data Transfer .................................................................................................................2-14
Network Variable ............................................................................................2-14
DataSocket.......................................................................................................2-15
NI-488.2.........................................................................................................................2-16
NI-DAQmx ....................................................................................................................2-16
NI-SCOPE .....................................................................................................................2-17
NI-VISA.........................................................................................................................2-17
User Interface.................................................................................................................2-18
Windows Forms Controls ..............................................................................................2-19
Waveform Graph and Scatter Graph Controls ................................................2-20
Digital Waveform Graph Control....................................................................2-23
Complex Graph Control ..................................................................................2-25
Legend Control................................................................................................2-27
© National Instruments Corporation v Measurement Studio User Manual
Contents
Numeric Controls............................................................................................ 2-27
Numeric Edit Control...................................................................................... 2-29
Switch and LED Controls ............................................................................... 2-30
Property Editor Control................................................................................... 2-32
Windows Forms Array Controls ................................................................................... 2-33
Switch and LED Array Controls ..................................................................... 2-33
Numeric Edit Array Control ........................................................................... 2-34
InstrumentControlStrip Control ...................................................................... 2-35
ASP.NET Web Forms Controls .................................................................................... 2-37
Waveform Graph and Scatter Graph Controls................................................2-38
Digital Waveform Graph Control ................................................................... 2-40
Complex Graph Control.................................................................................. 2-42
Legend Control ............................................................................................... 2-44
Numeric Controls............................................................................................ 2-44
Numeric Edit Control...................................................................................... 2-47
Switch and LED Controls ............................................................................... 2-48
AutoRefresh Control ....................................................................................... 2-49
AutoRefresh Callback ..................................................................................... 2-49
Chapter 3 Measurement Studio Visual C++ Class Libraries
Measurement Studio Visual C++ Class Library Overview........................................... 3-1
ActiveX Controls in Visual C++ ................................................................................... 3-2
3D Graph Control .......................................................................................................... 3-2
Plot Operations................................................................................................ 3-3
Additional Operations ..................................................................................... 3-3
Analysis ......................................................................................................................... 3-3
Standard Analysis ........................................................................................... 3-4
Professional Analysis...................................................................................... 3-4
Enterprise Analysis ......................................................................................... 3-4
Common ........................................................................................................................ 3-15
DataSocket..................................................................................................................... 3-15
Microsoft Excel Interface .............................................................................................. 3-16
Microsoft Word Interface .............................................................................................. 3-16
NI-488.2......................................................................................................................... 3-17
NI-DAQmx.................................................................................................................... 3-17
NI-Reports ..................................................................................................................... 3-18
NI-VISA ........................................................................................................................ 3-18
User Interface ................................................................................................................ 3-19
Button Control................................................................................................. 3-19
Graph Control ................................................................................................. 3-20
Plot Operations ................................................................................. 3-20
Axis Operations ................................................................................ 3-21
Measurement Studio User Manual vi ni.com
Additional Operations .......................................................................3-21
Knob Control ...................................................................................................3-21
Numeric Edit Control ......................................................................................3-22
Slide Control....................................................................................................3-23
Utility .............................................................................................................................3-24
Chapter 4 Measurement Studio Integrated Tools and Features
Measurement Studio Menu............................................................................................4-1
Creating a Measurement Studio Project ........................................................................4-4
Adding or Removing Measurement Studio .NET Class Libraries ................................4-5
Creating a Measurement Studio NI-DAQmx Application ............................................4-6
Creating an NI-DAQmx User Interface ..........................................................4-8
Creating NI-DAQmx User Code in Visual C++ .............................................4-9
Creating an Instrument Control Application .................................................................4-9
Selecting a Measurement Studio Parameter Value........................................................4-11
Using the Instrument Driver Wizard .............................................................................4-12
Chapter 5 Getting Started with Measurement Studio
Measurement Studio Walkthroughs...............................................................................5-1
Walkthrough: Creating a Measurement Studio Application
with Windows Forms Controls and Analysis ............................................................5-2
Walkthrough: Creating a Measurement Studio Application
with Web Forms Controls and Analysis ....................................................................5-11
Walkthrough: Creating a Measurement Studio Application
with Windows Forms Controls and Network Variable ..............................................5-22
Walkthrough: Creating a Measurement Studio Application
with Web Forms Controls and Network Variable ......................................................5-31
Walkthrough: Creating a Measurement Studio NI-DAQmx Application .....................5-42
Walkthrough: Creating a Measurement Studio Instrument I/O Application ................5-52
Contents
Appendix A Technical Support and Professional Services
Glossary
Index
© National Instruments Corporation vii Measurement Studio User Manual

About This Manual

The Measurement Studio User Manual introduces the concepts associated with the Measurement Studio class libraries and development tools. This manual assumes that you have a general working knowledge of Microsoft Visual Studio and the .NET Framework for .NET application development or MFC for unmanaged C++ application development.

How To Use This Manual

Measurement Studio 8.5 includes two Visual Studio support CDs—one with support for Visual Studio .NET 2003, Visual Studio 2005, and Visual Studio 2008 and one with support for Visual Studio 6.0. This manual documents Measurement Studio for Visual Studio 2005/2008. The Measurement Studio support for Visual Studio .NET 2003, Visual Studio 2005, and Visual Studio 2008 CD includes separate, parallel sets of class libraries, integration features, and support documentation for developing with Visual Studio .NET 2003, Visual Studio 2005, and Visual Studio 2008. For help with Visual Studio 6.0, refer to the Measurement Studio Support for Visual Studio 6.0 Readme located on the Measurement Studio for Visual Studio 6.0 CD.
The Measurement Studio User Manual is organized into five chapters. Chapter 1, Introduction to Measurement Studio, is an overview of Measurement Studio. This chapter includes installation and deployment requirements, installation instructions, and a list of Measurement Studio resources. Chapter 2, Measurement Studio .NET Class Libraries, and Chapter 3, Measurement Studio Visual C++ Class Libraries, include information about the .NET class libraries and the Visual C++ class libraries, respectively. Chapter 4, Measurement Studio Integrated Tools
and Features, includes information on using the Measurement Studio tools
and features integrated into the Visual Studio environment. Chapter 5,
Getting Started with Measurement Studio, includes walkthroughs that
guide you through step-by-step instructions on how to develop with Measurement Studio features.
Note Refer to the Measurement Studio Release Notes for updates or changes to the
Measurement Studio User Manual.
© National Instruments Corporation ix Measurement Studio User Manual
About This Manual
Use this manual as a starting point to learn about Measurement Studio. Refer to the NI Measurement Studio Help within the Visual Studio environment for function reference and detailed information about the Measurement Studio class libraries, wizards, assistants, and other features.

Conventions

The following conventions appear in this manual:
<> Text enclosed in angle brackets represents directory names and parts of
paths that may vary on different computers, such as <
» The » symbol leads you through nested menu items and dialog box options
to a final action. The sequence File»Page Setup»Options directs you to pull down the File menu, select the Page Setup item, and select Options from the last dialog box.
This icon denotes a tip, which alerts you to advisory information.
This icon denotes a note, which alerts you to important information.
bold Bold text denotes items that you must select or click on in the software,
such as menu items and dialog box options. Bold text also denotes class library member names or emphasis.
Windows\System>.
italic Italic text denotes parameters, variables, cross-references, or an
introduction to a key concept. Italic text also denotes text that is a placeholder for a word or value that you must supply.
monospace Text in this font denotes text or characters that you enter from the keyboard,
sections of code, programming examples, and syntax examples. This font also is used for the proper names of disk drives, paths, directories, programs, device names, filenames and extensions, and code excerpts.
Measurement Studio User Manual x ni.com
Introduction to Measurement Studio
Measurement Studio is an integrated suite of tools and class libraries that are designed for developers using Microsoft Visual Basic .NET, Visual C#, ASP.NET, and Visual C++ to develop measurement and automation applications.
Measurement Studio dramatically reduces application development time through object-oriented measurement hardware interfaces, advanced analysis libraries, scientific user interface controls for Windows and Web applications, measurement data networking, wizards, interactive code designers, and highly extensible .NET and Visual C++ classes. You can use Measurement Studio to develop a complete measurement and automation application that includes data acquisition, analysis, and presentation functionalities.
Measurement Studio 8.5 Professional and Enterprise packages include two Visual Studio support CDs—one CD with support for Visual Studio .NET 2003, Visual Studio 2005, and Visual Studio 2008 and one CD with support for Visual Studio 6.0. The Measurement Studio 8.5 Standard package includes one CD with support for Visual Studio .NET 2003, Visual Studio 2005, and Visual Studio 2008. Visual Studio 6.0 support includes ActiveX controls for use in Visual Basic 6.0 and MFC class libraries and ActiveX controls for use in Visual C++ 6.0. Visual Studio .NET 2003 support and Visual Studio 2005 support includes .NET class libraries and controls for use with .NET languages and MFC class libraries and ActiveX controls for use with Visual C++. Visual Studio 2008 support includes only .NET class libraries and controls for use with .NET languages. Measurement Studio 8.5 does not include MFC class libraries or ActiveX controls for use in Visual C++ in Visual Studio 2008.
1
Note Measurement Studio 8.5 support for Visual Studio .NET 2003 includes updates to
the ActiveX controls; however, no new features for Visual Studio .NET 2003 are included in Measurement Studio 8.5.
© National Instruments Corporation 1-1 Measurement Studio User Manual
Chapter 1 Introduction to Measurement Studio
This manual documents Measurement Studio for Visual Studio 2005 and Visual Studio 2008. For help with Visual Studio 6.0 support, refer to the Measurement Studio Support for Visual Studio 6.0 Readme located on the Measurement Studio for Visual Studio 6.0 CD. For help with Visual Studio .NET 2003 support, refer to the Measurement Studio Support for Visual Studio .NET 2003 Readme located on the CD for Measurement Studio for Visual Studio .NET 2003. After installing Visual Studio .NET 2003 support, you can refer to the Measurement Studio User Manual by selecting
Start»All Programs»National Instruments»<Measurement Studio for .NET 2003>»User Manual.
Note Refer to the Measurement Studio Release Notes for updates or changes to the
Measurement Studio User Manual.

Installation Requirements

To use Measurement Studio, your computer must have the following:
Microsoft Windows Vista/XP/2000 for Visual Studio 2005 or Microsoft Windows Vista/XP for Visual Studio 2008
Note If you have Windows Vista installed you must also have both Visual Studio 2005
Service Pack 1 and Visual Studio Service Pack 1 Update for Windows Vista installed on your machine for Measurement Studio to function properly.
Microsoft .NET Framework 2.0 for Visual Studio 2005 or Microsoft .NET Framework 3.5 for Visual Studio 2008 (required only for the Measurement Studio .NET class libraries)
Standard, Professional, or Team System edition of Microsoft Visual Studio 2005 or Standard, Professional, or Team System edition of Microsoft Visual Studio 2008 (required to use the Measurement Studio integrated tools) or Visual C#, Visual Basic .NET, or Visual C++ Express editions of Microsoft Visual Studio 2005 or Microsoft Visual Studio 2008
Intel Pentium III class processor, 1 GHz or higher
Video display—1024 × 768, 256 colors (16-bit color recommended for user interface controls)
Minimum of 256 MB of RAM (512 MB or higher recommended)
Minimum of 385 MB of free hard disk space for Visual Studio 2005 support or minimum of 200 MB of free hard disk space for Visual Studio 2008 support
Measurement Studio User Manual 1-2 ni.com
Microsoft-compatible mouse
Microsoft Internet Explorer 6.0 or later
Optional Installation—In order for links from Measurement Studio help topics to .NET Framework help topics to work, you must install the Microsoft .NET Framework SDK 2.0 or Microsoft .NET Framework SDK 3.5.

Driver Support

To use .NET class libraries that interface to National Instruments device drivers, NI-DAQmx, NI-VISA and NI-488.2, and the MAX (Measurement & Automation Explorer) configuration utility, you must install the underlying device drivers in addition to the .NET class libraries. You can run the underlying device driver installers from the NI Device Drivers CD included with Measurement Studio. Alternatively, refer to NI Drivers and Updates on download the latest version of the NI Device Drivers CD.
ni.com and enter Device Drivers into the search field to

Deployment Requirements

Chapter 1 Introduction to Measurement Studio
To deploy an application built with Measurement Studio .NET class libraries, the target computer must have a Windows Vista/XP/2000 operating system and the .NET Framework version 2.0 for Visual Studio 2005 or the .NET Framework version 3.5 for Visual Studio 2008.
To deploy an application built with Measurement Studio Visual C++ class libraries, the target computer must have a Windows Vista/XP/2000 operating system.

Installation Instructions

Complete the following steps to install Measurement Studio. These steps describe a typical installation. Please carefully review all additional licensing and warning dialog boxes.
National Instruments recommends that you exit all programs before running the Measurement Studio installer. Applications that run in the background, such as virus scanning utilities, might cause the installer to take longer than average to complete.
© National Instruments Corporation 1-3 Measurement Studio User Manual
Chapter 1 Introduction to Measurement Studio
Note There are separate installers for Measurement Studio support for Visual Studio 2005
and Measurement Studio support for Visual Studio 2008. Repeat the installation instructions to install support for both. When installing support for more than one version of Visual Studio, you can reduce installation time by running the Device Drivers CD installer only once. To do this, ensure that the Device Drivers CD feature is enabled only for the last Measurement Studio Visual Studio support installer that you run.
The option to browse for an installation location is valid only if you have not already installed any Measurement Studio features for the version of Visual Studio or the .NET Framework that you are installing. If you have any Measurement Studio features installed, then Measurement Studio installs to the same root directory to which you installed other Measurement Studio features.
Complete the following steps to install Measurement Studio:
1. Log on as an administrator or as a user with administrator privileges.
2. Launch location to which you extracted the downloaded CD image.
3. Select the version of Visual Studio you want to install support for.
4. Follow the instructions that appear on the screen.
Autorun.exe, either from the installation CD or from the
Note If you want to upgrade a Windows XP machine to Windows Vista, National
Instruments recommends first uninstalling all NI software, including both application software and drivers.

Installing Hardware Drivers for Visual Studio 2008 Support

Visual Studio 2008 .NET class library support for National Instruments hardware drivers is included on the Measurement Studio 8.5 CD, under the VS2008 Driver Support feature in the feature tree. To install support for NI-DAQmx, NI-VISA, NI-488.2, or MAX, you must install the appropriate feature from the Measurement Studio 8.5 CD and you must install the underlying device driver from the NI Device Drivers CD or from a product-specific driver installer. Refer to the Driver Support section for information on obtaining device driver installers.
Measurement Studio User Manual 1-4 ni.com
Chapter 1 Introduction to Measurement Studio
To install support for NI-DAQmx:
1. In the NI Measurement Studio 8.5 installer, enable the VS2008 Driver
Support».NET Framework 3.5 Languages Support for NI-DAQmx feature.
2. In the NI Device Drivers installer, enable the Data Acquisition» NI-DAQmx feature.
To install support for NI-VISA:
1. In the NI Measurement Studio 8.5 installer, enable the VS2008 Driver
Support».NET Framework 3.5 Languages Support for NI-VISA
feature. If you want to use the Instrument I/O Assistant inside Visual Studio 2008, enable the VS2008 Driver Support»VS2008 DotNET IIOAssistant Support feature.
2. In the NI Device Drivers installer, enable the Instrument Control» NI-VISA feature.
To install support for NI-488.2:
1. In the NI Measurement Studio 8.5 installer, enable the VS2008 Driver
Support».NET Framework 3.5 Languages Support for NI-488.2
feature.
2. In the NI Device Drivers installer, enable the Instrument Control» NI-488.2 feature.
To install support for MAX:
1. In the NI Measurement Studio 8.5 installer, enable the VS2008 Driver
Support».NET Framework 3.5 Languages Support for NI MAX
feature.
2. In the NI Device Drivers installer, enable the NI Measurement and Automation Explorer feature.

Installing Hardware Drivers for Visual Studio 2005 Support

The .NET and C++ class libraries for Visual Studio 2005 support for National Instruments hardware drivers are included in the Driver CD installer.
© National Instruments Corporation 1-5 Measurement Studio User Manual
Chapter 1 Introduction to Measurement Studio

Installing the Current Version of Measurement Studio over Previous Versions of Measurement Studio

Note You can have only one version of Measurement Studio installed on a system for each
version of Visual Studio or the .NET Framework installed on the system. For example, you can have Measurement Studio 8.1.2 for Visual Studio 2005 installed on the same system as Measurement Studio 8.5 for Visual Studio 2008, but you cannot have Measurement Studio 8.1.2 for Visual Studio 2005 installed on the same system as Measurement Studio 8.5 for Visual Studio 2005.
If you install a newer version of Measurement Studio on a machine that has a prior version of Measurement Studio installed, the newer version installer replaces the prior version functionality, including class libraries. However, the prior version assemblies remain in the global assembly cache (GAC); therefore, applications that reference the prior version continue to use the prior version .NET assemblies.
Note This does not apply to NationalInstruments.Common.dll. NationalInstruments.Common.dll uses a publisher policy file to redirect
applications to always use the newest version of installed on the system, for each version of the .NET Framework.
NationalInstruments.Common.dll is backward-compatible.
NationalInstruments.Common.dll

Measurement Studio Package Comparison Chart

The following table lists the features included in the Standard, Professional, and Enterprise packages of Measurement Studio. Refer to
ni.com/mstudio for more information about the functionality and
features included with each Measurement Studio package, including Visual C++ functionality.
Measurement Studio User Manual 1-6 ni.com
Chapter 1 Introduction to Measurement Studio
Table 1-1. Measurement Studio Package Comparison Chart for Visual C# and Visual Basic .NET
Feature Standard Edition Professional Edition Enterprise Edition
Project Wizards
Windows Forms User Interface Controls
Standard Analysis Libraries
1
NI-488.2 Class Libraries
2
NI-VISA Class Libraries
2
NI-DAQmx Class Libraries
2
.NET Instrument Driver Wizard
User Interface DataSocket Binding
Web Forms User Interface Controls
MFC and ActiveX Controls for Visual C++ 6.0
Professional Analysis Libraries
3
3D Graph ActiveX
Control
User Interface
Network Variable Binding
Network Variable
Class Library
Network Variable
Data Source
© National Instruments Corporation 1-7 Measurement Studio User Manual
Chapter 1 Introduction to Measurement Studio
Table 1-1. Measurement Studio Package Comparison Chart for Visual C# and Visual Basic .NET (Continued)
Feature Standard Edition Professional Edition Enterprise Edition
DataSocket Server
DataSocket Library
Parameter Assistant
Instrument I/O Assistant
DAQ Assistant
2
2
Enterprise Analysis Libraries
4
NI TestStand
Integration
LabWindows™/CVI™
Full Development System (FDS)
1
Refer to the Standard Analysis section of Chapter 2, Measurement Studio .NET Class Libraries, for a list of the
functionality included in the Standard Analysis class library.
2
Included with the Device Drivers CD.
3
Refer to the Professional Analysis section of Chapter 2, Measurement Studio .NET Class Libraries, for a list of the
functionality included in the Professional Analysis class library.
4
Refer to the Enterprise Analysis section of Chapter 2, Measurement Studio .NET Class Libraries, for a list of the
functionality included in the Enterprise Analysis class library.
Measurement Studio User Manual 1-8 ni.com

Learning Measurement Studio

As you work with Measurement Studio, you might need to consult additional resources. For detailed Measurement Studio help, including function reference and in-depth documentation on developing with Measurement Studio, refer to the NI Measurement Studio Help within the Visual Studio environment. The NI Measurement Studio Help is fully integrated with the Visual Studio help. You must have Visual Studio installed to view the online help, and you must have the Microsoft .NET Framework SDK 2.0 for Visual Studio 2005 or the Microsoft .NET Framework SDK 3.5 for Visual Studio 2008 installed in order for links from Measurement Studio help topics to .NET Framework help topics to work. You can launch the NI Measurement Studio Help in the following ways:
From the Windows Start menu, select Start»All Programs»National
Instruments»<Measurement Studio>»Measurement Studio Documentation. The help launches in a stand-alone help viewer.
From Visual Studio, select Help»Contents to view the Visual Studio table of contents. The NI Measurement Studio Help is listed in the table of contents.
From Visual Studio, select Measurement Studio»NI Measurement Studio Help. The help launches within the application.
Chapter 1 Introduction to Measurement Studio
Tip As you work through this manual, you will see italicized references to relevant help
topics. To find these topics, use the table of contents in the NI Measurement Studio Help installed on your machine.
The following resources also are available to provide you with information about Measurement Studio.
Getting Started information—Refer to the Measurement Studio Core
Overview topic and the Getting Started with the Measurement Studio Class Libraries section in the NI Measurement Studio Help for an
introduction to Measurement Studio and for walkthroughs that guide you step-by-step in learning how to develop Measurement Studio applications. For an introduction to Measurement Studio resources, refer to the Using the Measurement Studio Help topic in the NI Measurement Studio Help.
Examples—Measurement Studio installs examples organized by class library, depending on the component, the version of Visual Studio or the .NET Framework that the example supports, the version of Measurement Studio installed on the system, and the operating system.
© National Instruments Corporation 1-9 Measurement Studio User Manual
Chapter 1 Introduction to Measurement Studio
For more information on example locations, refer to Where To Find Examples.
NI Technical Support—Refer to Appendix A, Technical Support and
Professional Services, for more information.
Measurement Studio Web site, Measurement Studio news, support, downloads, white papers, product tutorials, and evaluation software.
NI Developer Zone, example programs, tutorials, technical news, and a Measurement Studio Discussion Forum where you can participate in discussion forums for Visual Basic 6.0, Visual C++, and .NET Languages.
Measurement Studio .NET Class Hierarchy Chart and Measurement Studio Visual C++ Class Hierarchy Chart—Provide overviews of class relationships within class libraries. Charts are included with all Measurement Studio packages and are posted online at
manuals
Review the information from the Microsoft Web site on using Visual Studio.
ni.com/mstudio—Contains
zone.ni.com—Provides access to online
ni.com/
.
Measurement Studio User Manual 1-10 ni.com
2
Measurement Studio .NET Class Libraries
This chapter provides overview information about the .NET class libraries included with Measurement Studio support for Visual Studio 2005 and Visual Studio 2008. Refer to the Using the Measurement Studio .NET Class Libraries section of the NI Measurement Studio Help for detailed information about these libraries. Refer to Chapter 5, Getting Started with
Measurement Studio, for step-by-step instructions on developing
applications with these libraries.

Measurement Studio Support for Visual Studio .NET Class Library Overview

Measurement Studio provides .NET class libraries that you can use to develop complete measurement and automation applications in Visual Basic .NET and Visual C#.
Measurement Studio includes the following .NET class libraries:
Analysis
Common
DataSocket
Network Variable
NI-488.2
•NI-DAQmx
•NI-SCOPE
•NI-VISA
User Interface
Refer to the following sections for information about each Measurement Studio .NET class library.
© National Instruments Corporation 2-1 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries

Analysis

The Measurement Studio Analysis .NET class library is in the
NationalInstruments.Analysis namespace. The Analysis class
library includes a set of classes that provides digital signal processing, signal filtering, signal generation, peak detection, and other general mathematical functionality. Use this library to analyze acquired data or to generate data. Additionally, the documentation for the Analysis class library includes analysis code snippets that you can copy and paste into an application and use immediately.
The functionality included in the Analysis library varies based on the Measurement Studio package you purchase. Refer to the following sections for information about the Standard, Professional, and Enterprise Analysis class libraries.

Standard Analysis

The Standard Analysis class library, which ships with Measurement Studio Standard Edition, includes the sawtooth, sine, square, triangle, and basic function wave generators.

Professional Analysis

The Professional Analysis class library, which ships with Measurement Studio Professional Edition, includes the Standard Analysis functionality as well as the following functionality:
Bessel, Chebyshev, Inverse Chebyshev, Windowed, Kaiser, and Elliptic Low, High, Bandpass, and Bandstop filters
Signal processing functions such as convolution, deconvolution, correlation, decimation, integration, and differentiation
FFT, Inverse FFT, Real FFT, Fast Hartley, Inverse Fast Hartley, Fast Hilbert, Inverse Fast Hilbert, DST, Inverse DST, DCT, and Inverse DCT transformations
Linear algebra functions such as determinant, check positive definiteness, calculate dot product, and other various matrix functions
Scaled and unscaled windowing classes
Common statistical functions such as mean, median, mode, and variance
Exponential, linear, and polynomial curve fitting functions
Signal generation functions
Measurement Studio User Manual 2-2 ni.com

Enterprise Analysis

Chapter 2 Measurement Studio .NET Class Libraries
The Enterprise Analysis class library, which ships with Measurement Studio Enterprise Edition, includes the Standard and Professional Analysis functionality as well as the following advanced functionality:
EquiRipple filters
Linear algebra functions such as forward and back substitution, LU factorization, Cholesky factorization, Schur decomposition, and Hessenberg decomposition
Probability and analysis of variance
Sinc, impulse, pulse, ramp, and chirp patterns
General least square curve fit, power fit, log fit, Gauss fit, cubic spline fit, and interpolation functions
Measurement functions such as transition measurements, pulse measurements, and cycle RMS average functions
Special functions
Refer to Table 2-1 to determine the type of measurements available in the Professional and Enterprise Analysis .NET libraries.
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages
Analysis .NET Library Professional Package Enterprise Package
Measurements
AC and DC Estimator
Amplitude and Phase
Spectrum
Auto Power Spectrum
Cross Power Spectrum
Cycle RMS Average
Harmonic Analyzer
Harmonic Analyzer Using
Signal
Impulse Response Function
Network Functions (avg)
© National Instruments Corporation 2-3 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Power and Frequency Estimate
Pulse Measurements
Scaled Time Domain Window
Single Tone Information
Spectrum Unit Conversion
State Levels
Transfer Function
Transition Measurements
Signal Generation
Arbitrary Wave
Chirp Pattern
Gaussian White Noise
Impulse Pattern
Pulse Pattern
Ramp Pattern
Sawtooth Wave
Sinc Pattern
Sine Pattern
Sine Wave
Square Wave
Triangle Wave
Uniform White Noise
Windowing
Blackman Window
Blackman-Harris Window
Measurement Studio User Manual 2-4 ni.com
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Blackman-Nuttall Window
Cosine Tapered Window
Dolph-Chebyshev Window
Exact Blackman Window
Exponential Window
Flat Top Window
Force Window
Gauss Window
General Cosine Window
Hamming Window
Hanning Window
Kaiser-Bessel Window
Scaled Time Domain Windows
Symmetric Time Domain
Windows
Triangle Window
Filters
Bessel
Butterworth
Cascade
Chebyshev
Elliptic
Equiripple
FIR
FIR Windowed
© National Instruments Corporation 2-5 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
IIR Cascade
IIR
Inverse Chebyshev
Kaiser
Signal Processing
Autocorrelation
Convolution
Cross Power
Cross Correlation
Decimate
Deconvolution
Derivative x(t)
Discrete Cosine Transform
Discrete Sine Transform
Fast Hilbert Transform
Fast Hartley Transform
Integral x(t)
Inverse Real and Complex Fast
Fourier Transform (FFT)
Inverse Fast Hilbert Transform
Inverse Fast Hartley Transform
Peak Detection
Power Spectrum
Pulse Parameters
Real and Complex FFT
Measurement Studio User Manual 2-6 ni.com
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Threshold Peak Detector
Unwrap Phase
Linear Algebra
Back Transform Eigen Vectors
Backward Substitution
Cholesky Factorization
Complex Back Transform
Eigen Vectors
Complex Cholesky
Factorization
Complex Determinant
Complex Dot Product
Complex Eigen Vectors and
Eigen Values
Complex General Eigen AB
Complex Hessenberg
Decomposition
Complex Inverse Matrix
Complex Linear Equations
Complex LU Factorization
Complex Matrix Balance
Complex Matrix Condition
Number
Complex Matrix Norm
Complex Matrix Rank
Complex Outer Product
© National Instruments Corporation 2-7 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Complex Pseudo Inverse
Matrix
Complex QR Factorization
Complex QR Factorization
with Pivot Matrix
Complex QR Factorization
with Pivot Vector
Complex QZ Decomposition
Complex Schur
Decomposition
Complex Solve Linear
Equations (Multiple Right Hand)
Complex Solve Linear
Equations (Single Right Hand)
Complex SVD Factorization
Complex Vector Norm
Determinant
Dot Product
Forward Substitution
General Eigen AB
Hessenberg Decomposition
Inverse Matrix
Linear Equations
LU Factorization
Matrix Balance
Matrix Condition Number
Matrix Multiplication
Measurement Studio User Manual 2-8 ni.com
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Matrix Norm
Matrix Rank
Outer Product
Pseudo Inverse Matrix
QR Factorization
QR Factorization with Pivot
Matrix
QR Factorization with Pivot
Vector
QZ Decomposition
Schur Decomposition
Solve Linear Equations
(Multiple Right Hand)
Solve Linear Equations
(Single Right Hand)
Special Matrix
SVD Factorization
Test Positive Definite Matrix
Trace
Transpose
Array and Numeric Operations
1D and 2D Array Arithmetic
1D and 2D Linear Evaluation
1D and 2D Polynomial
Evaluation
1D Polar to Rectangular
1D Rectangular to Polar
© National Instruments Corporation 2-9 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Complex Number Arithmetic
Find Polynomial Roots
Scale 1D and 2D
Curve Fitting
Cubic Spline Fit
Exponential Fit
Exponential Fit Interval
Gauss Fit
Gauss Fit Interval
General Least Squares
Linear Fit
General Polynomial Fit
Goodness of Fit
Linear Fit
Linear Fit Interval
Logarithm Fit
Logarithm Fit Interval
Nonlinear Fit
Power Fit
Power Fit Interval
Remove Outliers
Statistics
1D, 2D, and 3D ANOVA
Chi-Square Distribution
erf(x) and erfc(x)
Measurement Studio User Manual 2-10 ni.com
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
F-Distribution
Histogram
Inverse Chi-Square
Distribution
Inverse F-Distribution
Inverse Normal Distribution
Inverse T-Distribution
Mean
Median and Mode
Moment about Mean
Normal Distribution
Polynomial Interpolation
Root-Mean-Square (RMS)
Spline Interpolant
Spline Interpolation
Standard Deviation
T-Distribution
Variance
Special Functions
Airy
Bessel 1st
Bessel 2nd
Beta
Complimentary Gamma
Cosine Integral
© National Instruments Corporation 2-11 Measurement Studio User Manual
Chapter 2 Measurement Studio .NET Class Libraries
Table 2-1. Analysis .NET Library Measurement Types included in
the Professional and Enterprise Packages (Continued)
Analysis .NET Library Professional Package Enterprise Package
Dawson’s Integral
Dilogarithm
Elliptic 1st
Elliptic 2nd
Exponential Integral
Factorial
Fresnel Integrals
Gamma
Gauss Hypergeometric
Hyperbolic Cosine Integral
Hyperbolic Sine Integral
Incomplete Beta
Incomplete Elliptic 1st
Incomplete Elliptic 2nd
Incomplete Gamma
Jacobian Elliptic Function
Kelvin 1st
Kelvin 2nd
Kummer
Logarithm of Factorial
Modified Bessel 1st
Modified Bessel 2nd
Parabolic Cylinder
Psi
Sine Integral
Measurement Studio User Manual 2-12 ni.com
Loading...
+ 149 hidden pages