Specifications
338 Chapter 18
PSA Programming Examples
Using Visual Basic® .NET with the IVI-Com Driver
PSA Programming Examples
Using Visual Basic
®
.NET with the IVI-Com
Driver
This example uses Visual Basic .NET with the IVI-Com driver. It makes
a time domain (Waveform) measurement using the Basic mode. Basic
mode is standard in the E4406A Vector Signal Analyzer and is optional
(B7J) in the PSA Series Spectrum Analyzers. The vb file
(vbivicomsa_basicwaveform.vb) and the compiled executable file
(vbivicomsa.exe) can be found on the Documentation CD.
’*************************************************************************
’ VBIviComSA_BasicWaveform.vb, August 5, 2003
’ This example demonstrates the use of the IVI-COM driver in VB.NET
’ through an interop assembly. The Raw I/Q trace data from the Waveform
’ measurement in Basic Mode is queried and printed to the screen.
’
’ Requirements:
’ 1) E4406A or PSA Series Spectrum Analyzer with Option B7J
’ 2) Latest AgilentSa IVI-COM driver
’ You may download it here: http://www.agilent.com/find/inst_drivers
’ This example was tested with version 2.1.0.0 of the driver
’ 3) Create a new project and add the References to this module
’ and to the the IVI-COM driver dlls:
’ For .NET, right click on Reference, choose Add Reference
’ and then click on Browse and directly link the DLLs in the directory:
’ C:\Program Files\IVI\Bin\Primary Interop Assemblies
’ Agilent.AgilentSa.Interop.dll
’ Agilent.AgilentSaAppBasic.Interop.dll
’ Agilent.Itl.Interop
’ IviDriverLib.dll
’ IviSpecAnLib.dll
’
’ THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
’ KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
’ IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
’ PARTICULAR PURPOSE.
’