Agilent Technologies InfiniiVision 3000 Programmer's Manual page 1188

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

Advertisement

39
Programming Examples
' For Sleep subroutine.
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
'
' Main Program
' -------------------------------------------------------------------
Sub Main()
ErrorHandler:
End Sub
'
' Initialize the oscilloscope to a known state.
' -------------------------------------------------------------------
Private Sub Initialize()
1188
On Error GoTo ErrorHandler
' Open a device session using the SICL_ADDRESS.
id = iopen("usb0[2391::6054::US50210029::0]")
Call itimeout(id, 5000)
' Initialize - start from a known state.
Initialize
' Capture data.
Capture
' Analyze the captured waveform.
Analyze
' Close the vi session and the resource manager session.
Call iclose(id)
Exit Sub
MsgBox "*** Error : " + Error, vbExclamation
End
On Error GoTo ErrorHandler
' Clear the interface.
Call iclear(id)
' Get and display the device's *IDN? string.
strQueryResult = DoQueryString("*IDN?")
MsgBox "Result is: " + RTrim(strQueryResult), vbOKOnly, "*IDN? Result"
' Clear status and load the default setup.
DoCommand "*CLS"
DoCommand "*RST"
Exit Sub
Agilent InfiniiVision 3000 X-Series Oscilloscopes Programmer's Guide

Advertisement

Table of Contents
loading

Table of Contents