HP Drive Instrukcja Użytkownika

Przeglądaj online lub pobierz Instrukcja Użytkownika dla Podręczniki do oprogramowania HP Drive. HP Drive User's Manual Instrukcja obsługi

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 114
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów

Podsumowanie treści

Strona 1 - Getting Started Guide

Getting Started GuideYour Guide to Getting Started with IVI DriversRevision 1.0

Strona 2

10 Chapter 1 • • • •••Starting in the 1970s, programmers used device-dependent commands for computer control of instruments. But lack of standardiza

Strona 3 - Contents

100 Chapter 10 • • • •••

Strona 4 - Contents

101 • • • ••• Chapter 11• • • • • • Advanced TopicsNow that you’ve seen how to create a short program to perform a measurement in popular programming

Strona 5

102 Chapter 11 • • • •••Driver developers also provide wrapper interfaces optimized for specific development environments. The wrapper functions as a

Strona 6

Advanced Topics 103 • • • •••Now that we’ve defined the capabilities, we can look at each driver in terms of those it supports. Custom Specific Driver

Strona 7

104 Chapter 11 • • • •••capabilities, it is called an IVI-COM custom driver. If the driver includes the class capabilities, it is called an IVI-COM C

Strona 8

Advanced Topics 105 • • • ••••The instruments must provide the same behavior, at least with respect to the calling program.Meeting these requirements

Strona 9 - Introduction

106 Chapter 11 • • • •••IVI Configuration StoreThe IVI Configuration Store holds information about the IVI drivers installed on your computer and con

Strona 10 - Why IVI?

Advanced Topics 107 • • • •••and contains the commands and functions necessary to communicate with the instrument. You can use the software module ent

Strona 11 - Introduction

108 Chapter 11 • • • •••In the illustration below, we replace the Vendor X DMM with a Vendor Y DMM. All we need to do is change the LogicalName so th

Strona 12 - Why Use an IVI Driver?

Advanced Topics 109 • • • •••IVI-COMThis C# example shows interchangeability using IIviDriver, which references all of IVI’s inherent capabilities.IIv

Strona 13 - Shared Components

Introduction 11 • • • •••vendor’s instrument and not need to relearn the commands. Also commands that are common to all drivers, such as Initialize an

Strona 14 - Chapter 1

110 Chapter 11 • • • •••a reference to the instance of the driver. This line of code then casts the reference returned to type IIviDriver, from whic

Strona 15

Advanced Topics 111 • • • •••The rest of the code follows that used for the examples, but note that it is written to the class-compliant interfaces, n

Strona 16

112 Chapter 11 • • • •••IviDMM_ConfigureTrigger (session, IVIDMM_VAL_IMMEDIATE, 0.01);IviDMM_Read (session, 1000, &reading);printf ("%f&quo

Strona 17 - Using IVI with Visual C++

Advanced Topics 113 • • • •••2 Several vendors include examples as part of driver installation. For the Agilent 34401A driver (from Agilent Technologi

Strona 18 - Chapter 2

114 Chapter 11 • • • •••

Strona 19 - Initialize COM

12 Chapter 1 • • • •••IVI drivers conform to and are documented according to the IVI specifications and usually display the standard IVI logo. Note:

Strona 20 - Set the Trigger Delay

Introduction 13 • • • •••Flavors of IVI DriversTo support all popular programming languages and development environments, IVI drivers provide either a

Strona 21 - Close the Session

14 Chapter 1 • • • •••To see the list of drivers registered with the IVI Foundation, go to http://www.ivifoundation.org.Familiarizing Yourself with

Strona 22 - Using IVI-C in Visual C++

Introduction 15 • • • ••••Access an instrument property – We set the trigger delay to 0.01 seconds.•Set the reading timeout – We set the reading timeo

Strona 23 - Using IVI with Visual C++

16 Chapter 1 • • • •••

Strona 24 - Declare Variables

17 • • • ••• Chapter 2• • • • • • Using IVI with Visual C++The EnvironmentMicrosoft Visual C++ is a software development environment for the C++ progr

Strona 25 - Define Error Checking

18 Chapter 2 • • • •••Create a New Project and Import the Driver Type LibrariesTo use an IVI Driver in a Visual C++ program, you must provide the pa

Strona 26

Using IVI with Visual C++ 19 • • • •••“$(VXIPNPPATH)VisaCom”Note: These steps need only be done once for each computer you use. All subsequent Visual

Strona 28 - Further Information

20 Chapter 2 • • • •••Initialize the InstrumentYou can now write the main constructs for your program. Below the smart pointer statement, type dmm-&

Strona 29 - Visual Basic .NET

Using IVI with Visual C++ 21 • • • •••Set the Reading Timeout/Display the ReadingCreate a variable to represent the reading and make a reading with a

Strona 30 - Chapter 3

22 Chapter 2 • • • •••exit(1);{IAgilent34401Ptr dmm(__uuidof(Agilent34401));try{dmm->Initialize("GPIB::23",false,true,"simulate=tr

Strona 31

Using IVI with Visual C++ 23 • • • •••2 From the Tools menu select Options.3 Expand “Projects and Solutions”, then click on “VC++ Directories”4 Click

Strona 32

24 Chapter 2 • • • •••10 Expand “Configuration Properties”11 Expand “Linker”12 Select Input. In the Additional Dependencies field, type“hp34401a.lib

Strona 33

Using IVI with Visual C++ 25 • • • •••Define Error Checking1 Next define error checking for your program. First you will define a macro to catch the e

Strona 34

26 Chapter 2 • • • •••• Simulate=1 in the Options parameter sets the driver to simulation mode• &session assigns the Instrument Handle to the va

Strona 35

Using IVI with Visual C++ 27 • • • •••#endifint main(int argc, _TCHAR* argv[]){ViSession session;ViStatus error = VI_SUCCESS;ViReal64 reading;checkE

Strona 36

28 Chapter 2 • • • •••1 From the Start Menu, select Build, and click Build IVI Demo.2 From the Start Menu, select Debug, and run the application.Fur

Strona 37 - Using IVI with LabVIEW

29 • • • ••• Chapter 3 Using IVI with Visual C# and • • • • • • Visual Basic .NETThe EnvironmentC# and Visual Basic are object-oriented pro

Strona 38 - Chapter 4

Contents 3 • • • •••• • • • • • ContentsChapter 1 Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strona 39

30 Chapter 3 • • • •••Create a New Project and Reference the DriverTo use an IVI Driver in a Visual C# program, you must first add a reference to it

Strona 40 - Take the Reading

Using IVI with Visual C# and Visual Basic 31 • • • •••Create an Instance of the DriverTo allow your program to access the driver without specifying th

Strona 41 - Run the Application

32 Chapter 3 • • • •••Initialize the InstrumentYou can now write the main constructs for your program. Create a variable to represent your instrumen

Strona 42 - Using IVI-COM

Using IVI with Visual C# and Visual Basic 33 • • • •••Configure the InstrumentTo set the range to 1.5 volts and the resolution to 1 millivolt, typedmm

Strona 43 - Using IVI with LabVIEW

34 Chapter 3 • • • •••Your final program should contain the code below:using System;using System.Collections.Generic;using System.Text;using Agilent

Strona 44

Using IVI with Visual C# and Visual Basic 35 • • • •••Imports Agilent.Agilent34401.InteropModule Module1Sub Main()Dim dmm As New Agilent34401 d

Strona 45

36 Chapter 3 • • • •••

Strona 46

37 • • • ••• Chapter 4• • • • • • Using IVI with LabVIEWTMThe EnvironmentNational Instruments LabVIEW is a graphical development environment for signa

Strona 47

38 Chapter 4 • • • •••functions, making it easier to use in LabVIEW. If your IVI-C driver does not have a LabVIEW wrapper, you can create one using

Strona 48

Using IVI with LabVIEWTM 39 • • • •••Initialize the Instrument1 Select Initialize With Options VI from the hp34401a palette and place it on the Block

Strona 49 - Using IVI with LabWindows

4Contents• • • •••Create a New Project and Import the Driver Type Libraries. . . . . . . . . . 22Declare Variables. . . . . . . . . . . . . . . . . .

Strona 50

40 Chapter 4 • • • •••Configure the Instrument1 From the Configuration subpalette, select Configure Measurement VI and place it on the Block Diagram

Strona 51

Using IVI with LabVIEWTM 41 • • • •••3 Connect resource name and error information from Configure Trigger to Read VI.Display the ReadingCreate an indi

Strona 52

42 Chapter 4 • • • •••Setting a Property in an IVI-C DriverProperties such as Trigger Delay can also be set (and read) with a property node. This is

Strona 53 - Set the Reading Timeout

Using IVI with LabVIEWTM 43 • • • •••2 From the File menu, select New VI. The Front Panel and Block Diagram appear.3 Right-click in the Block Diagram.

Strona 54

44 Chapter 4 • • • •••7 From the Type Library drop-down, select the IVI Agilent 34401A (Agilent Technologies) 1.1 Type Library Version 1.1, and then

Strona 55

Using IVI with LabVIEWTM 45 • • • •••4 Back in the Class Browser, under Properties and Methods, scroll down and select Initialize. Click Create and dr

Strona 56 - Chapter 5

46 Chapter 4 • • • •••3 Connect the automation refnum and error terminals from Initialize Invoke Node to DCVoltage.Configure Invoke Node.4 In the Cl

Strona 57 - Using IVI with MATLAB

Using IVI with LabVIEWTM 47 • • • •••Run the ApplicationYour final VI Block Diagram should contain the elements shown below. To run your VI:1 Switch t

Strona 58 - Configure the IVI Driver

48 Chapter 4 • • • •••

Strona 59 - Using IVI with MATLAB®

49 • • • ••• Chapter 5• • • • • • Using IVI with LabWindowsTM/CVITMThe EnvironmentNational Instruments LabWindows/CVI is an ANSI-C integrated developm

Strona 60 - Chapter 6

Contents 5 • • • •••Create a Project and Access the Driver . . . . . . . . . . . . . . . . . . . . . . . . . 38Initialize the Instrument . . . . . .

Strona 61 - Connect to the Instrument

50 Chapter 5 • • • •••Note: Any of the three files listed above will work. Adding one of the HP 34401A instrument driver files loads that instrument

Strona 62 - Remove the Driver from Memory

Using IVI with LabWindowsTM/CVITM 51 • • • •••4 Select the Instrument Handle parameter. From the Code Menu, click Declare Variable to set the Instrume

Strona 63

52 Chapter 5 • • • •••Configure the Instrument1 From the library tree, select Configuration and click ConfigureMeasurement. The ConfigureMeasurement

Strona 64

Using IVI with LabWindowsTM/CVITM 53 • • • •••3 Select the Code menu and click Insert Function Call to insert the function and values into your progra

Strona 65 - Chapter 7

54 Chapter 5 • • • ••••session in the Instrument Handle fieldDisplay the Reading1 Select the Reading parameter. 2 Select Code and click Declare Vari

Strona 66 - Data Source

Using IVI with LabWindowsTM/CVITM 55 • • • •••printf (“%f”, reading);Note: Including error checking in your programs is good practice. Use the CheckEr

Strona 67 - 7 Click Next

56 Chapter 5 • • • •••

Strona 68 - Control Source

57 • • • ••• Chapter 6• • • • • • Using IVI with MATLAB®The Development EnvironmentMATLAB from The MathWorks is an interactive software environment fo

Strona 69

58 Chapter 6 • • • •••Configure the IVI DriverThe Instrument Control Toolbox provides a graphical Test & Measurement Tool that enables you to in

Strona 70 - Close Session

Using IVI with MATLAB® 59 • • • •••Next, you must define your Driver Session to link the Software Module with the Hardware Asset and indicate whether

Strona 71 - in the United

6Contents• • • •••Further Information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Chapter 6 Using IVI with MATL

Strona 72 - Chapter 7

60 Chapter 6 • • • •••10 Select the Logical Names tab. In the Logical Names dialog, select Add and enter the following:•DMM in the Name field•This l

Strona 73 - Using IVI with PAWS

Using IVI with MATLAB® 61 • • • •••11 Select File and Save IVI Configuration Store. Saving to the store may take several moments. 12 Close the Test &a

Strona 74 - Prepare the PAWS Environment

62 Chapter 6 • • • •••Set the Trigger DelayTo set the trigger delay to 0.01 seconds, typemyDmm.Trigger.Delay = 0.01;Set Reading TimeoutTo take a rea

Strona 75 - Using IVI with PAWS

Using IVI with MATLAB® 63 • • • •••Further InformationTo learn more about using MATLAB with IVI instrument drivers, visit: http://www.mathworks.com/iv

Strona 76 - Chapter 8

64 Chapter 6 • • • •••

Strona 77 - Connect to the IVI-COM Driver

65 • • • ••• Chapter 7• • • • • • Using IVI with Measure Foundry®The EnvironmentMeasure Foundry is a visual software environment for creating test and

Strona 78

66 Chapter 7 • • • •••Data SourceThe property pages contain all the information necessary to create an instance of the driver, initialize and config

Strona 79

Using IVI with Measure Foundry® 67 • • • ••••Agilent34401 in the device type field•GPIB and 23 in the VISA connect string field•DCV in the measurement

Strona 80

68 Chapter 7 • • • •••9 Click Next.10 Configure the trigger delay. In the Properties dialog, enter 0.01 in the trigger delay field and Immediate in

Strona 81

Using IVI with Measure Foundry® 69 • • • •••

Strona 82 - Build the Project

Contents 7 • • • •••Prepare the PAWS Environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74Add the WCEM Interface Functions. . . .

Strona 83 - Load and Run the Project

70 Chapter 7 • • • •••Data SinkThe property pages contain all the information necessary to display the output.1 In the Foundry window, select Displa

Strona 84

Using IVI with Measure Foundry® 71 • • • •••DT Measure Foundry® is a registered trademark of Data Translation® in the United States and/or other count

Strona 85 - Chapter 9

72 Chapter 7 • • • •••

Strona 86 - Add a Button

73 • • • ••• Chapter 8• • • • • • Using IVI with PAWSThe EnvironmentPAWS Developer's Studio gives you the capability to edit, compile, modify, de

Strona 87

74 Chapter 8 • • • •••download and install a driver, you do not need to exit PAWS Studio. Install the driver and continue with your program. Prepare

Strona 88

Using IVI with PAWS 75 • • • •••C$ 001110 DECLARE, VARIABLE, 'MEASURED' IS DECIMAL $C$E02000 OUTPUT, C'\LF\ATLAS PROGRAM STA

Strona 89

76 Chapter 8 • • • ••• { voltage range -300 v to 300 v continuous; } end; ** DC Voltage Measurement end; *end dmmNote: To und

Strona 90 - Chapter 9

Using IVI with PAWS 77 • • • •••9 To add a new *.h file called DMM.h to include the code necessary to reference the driver header files and librairies

Strona 91

78 Chapter 8 • • • •••#import "IviDmmTypeLib.dll" named_guids, raw_interfaces_only, raw_native_types no_namespace#import "Agilent3440

Strona 92

Using IVI with PAWS 79 • • • •••5 In the doOpen() interface function, insert the following code below the line Please insert your CEM driver code here

Strona 93 - Chapter 10

8Contents• • • •••Set the Trigger Delay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97Set the Reading Timeout . . .

Strona 94 - Chapter 10

80 Chapter 8 • • • •••if (FAILED(hr)){Display("\033[30;41m Bad return from get_DCVoltage(&pDMMDCVolt) method\033[m\n"); }hr

Strona 95

Using IVI with PAWS 81 • • • •••hr = pDMMData->Initiate();if (FAILED(hr)){Display("\033[30;41m Bad return from Initiate() method\033[m\n"

Strona 96

82 Chapter 8 • • • •••}driver.Release();pDMMData.Release();pDMMTrig.Release();pDMMDCVolt.Release();Note: The function doUnload gets called only once

Strona 97

Using IVI with PAWS 83 • • • •••Load and Run the Project1 From the Main Menu, select Build and click on Execute Wrts.Note: The message below may appea

Strona 98

84 Chapter 8 • • • •••

Strona 99

85 • • • ••• Chapter 9• • • • • • Using IVI with Visual Basic 6.0The EnvironmentVisual Basic 6.0 is a programming environment derived from Basic and d

Strona 100 - Chapter 10

86 Chapter 9 • • • •••2 From the Start Menu, select Project, and click References. The References dialog appears.3 Select the IVI Agilent34401 1.1 T

Strona 101 - Advanced Topics

Using IVI with Visual Basic 6.0 87 • • • •••Create an Instance of the Driver1 Double-click Test. The Project1 – Form1(Code) screen appears. Note that

Strona 102 - Driver Types

88 Chapter 9 • • • •••Configure the InstrumentSet the function to DC Voltage, range to 1.5 volts, and resolution to 1 millivolt.1 Type dmm.Function

Strona 103 - Advanced Topics

Using IVI with Visual Basic 6.0 89 • • • •••Set the Trigger DelaySet the trigger delay to 0.01 seconds.Type: dmm.Trigger.Delay = 0.01Display the Readi

Strona 104 - Chapter 11

9 • • • ••• Chapter 1• • • • • • IntroductionPurpose Welcome to IVI Getting Started Guide. This guide introduces key concepts about IVI drivers and sh

Strona 105

90 Chapter 9 • • • •••TipsThe Agilent 34401 driver conforms to the IviDmm class, so you can easily write your program to use the class-compliant int

Strona 106 - IVI Configuration Store

Using IVI with Visual Basic 6.0 91 • • • •••Further InformationLearn more about Visual Basic at http://msdn.microsoft.com/library/default.asp?url=/lib

Strona 107

92 Chapter 9 • • • •••

Strona 108

93 • • • ••• Chapter 10• • • • • • Using IVI with Agilent VEE ProThe Development EnvironmentAgilent Visual Engineering Environment Pro is a graphical

Strona 109

94 Chapter 10 • • • •••3 Click Add under instrument in the list at the right to add a simulated instrument. The Instrument Properties dialog box ap

Strona 110 - Chapter 11

Using IVI with Agilent VEE Pro 95 • • • •••7 Click the IVI-COM Driver tab. Select Agilent 34401 from the drop-down list.Note: The VISA address that yo

Strona 111

96 Chapter 10 • • • •••3 Double-click <Double-Click to Add Operation> in the To/From myDMM object. The Select an Operation dialog box appears.

Strona 112

Using IVI with Agilent VEE Pro 97 • • • •••3 In the Edit Initialize dialog box, GPIB0::23::INSTR has already been entered in the ResourceName field. E

Strona 113

98 Chapter 10 • • • •••Close the SessionNow that you have completed all of the driver operations, you should close the driver session to free resour

Strona 114

Using IVI with Agilent VEE Pro 99 • • • •••Further InformationLearn more about VEE Pro at www.agilent.com/find/vee.

Komentarze do niniejszej Instrukcji

Brak uwag