Agilent Technologies InfiniiVision 3000 Programmer's Manual page 1205

X-series
Hide thumbs Also See for InfiniiVision 3000:
Table of Contents

Advertisement

4
5
6
7
For more information, see the SCPI.NET driver help that comes with
Agilent Command Expert.
'
' Agilent SCPI.NET Example in Visual Basic .NET
' -------------------------------------------------------------------
' This program illustrates a few commonly used programming
' features of your Agilent oscilloscope.
' -------------------------------------------------------------------
Imports System
Imports System.IO
Imports System.Text
Imports Agilent.CommandExpert.ScpiNet.AgInfiniiVision3000X_01_20
Namespace InfiniiVision
Agilent InfiniiVision 3000 X-Series Oscilloscopes Programmer's Guide
Cut- and- paste the code that follows into the Visual Basic .NET source
file.
Edit the program to use the VISA address of your oscilloscope.
Add a reference to the SCPI.NET 3.0 driver:
a
Right- click the project you wish to modify (not the solution) in the
Solution Explorer window of the Microsoft Visual Studio
environment.
Choose Add Reference....
b
In the Add Reference dialog, select the Browse tab, and navigate to
c
the ScpiNetDrivers folder.
Windows XP: C:\Documents and Settings\All Users\Agilent\
Command Expert\ScpiNetDrivers
Windows 7: C:\ProgramData\Agilent\Command Expert\
ScpiNetDrivers
Select the .dll file for your oscilloscope, for example
d
AgInfiniiVision3000X_01_20.dll; then, click OK.
e
Right- click the project you wish to modify (not the solution) in the
Solution Explorer window of the Microsoft Visual Studio environment
and choose Properties; then, select
"InfiniiVision.ScpiNetInstrumentApp" as the Startup object.
Build and run the program.
Class ScpiNetInstrumentApp
Private Shared myScope As AgInfiniiVision3000X
Public Shared Sub Main(ByVal args As String())
Try
Dim strScopeAddress As String
'strScopeAddress = "a-mx3054a-60028.cos.agilent.com";
strScopeAddress = _
"TCPIP0::a-mx3054a-60028.cos.agilent.com::inst0::INSTR"
Console.WriteLine("Connecting to oscilloscope...")
Programming Examples
1205
39

Advertisement

Table of Contents
loading

Table of Contents