1024
Agilent Infiniium 90000 Series Oscilloscopes Programmer's Reference
38
Sample Programs
DoCommand ":MEASure:FREQuency"
varQueryResult = DoQueryNumber(":MEASure:FREQuency?")
MsgBox "Frequency:" + _
FormatNumber(varQueryResult / 1000, 4) + " kHz"
DoCommand ":MEASure:VAMPlitude"
varQueryResult = DoQueryNumber(":MEASure:VAMPlitude?")
MsgBox "Vertical amplitude:" + _
FormatNumber(varQueryResult, 4) + " V"
' Download the screen image.
' -----------------------------------------------------------------
' Get screen image.
Dim byteData() As Byte
byteData = DoQueryIEEEBlock_UI1(":DISPlay:DATA? PNG")
' Save screen image to a file.
Dim strPath As String
strPath = "c:\scope\data\screen.png"
If Len(Dir(strPath)) Then
Kill strPath
' Remove file if it exists.
End If
Dim hFile As Long
hFile = FreeFile
Open strPath For Binary Access Write Lock Write As hFile
Put hFile, , byteData
' Write data.
Close hFile
' Close file.
MsgBox "Screen image (" + CStr(UBound(byteData) + 1) + _
" bytes) written to " + strPath
' Download waveform data.
' -----------------------------------------------------------------
' Get the waveform type.
Debug.Print "Waveform type: " + _
DoQueryString(":WAVeform:TYPE?")
' Get the number of waveform points.
Debug.Print "Waveform points available: " + _
DoQueryString(":WAVeform:POINts?")
' Set the waveform source.
DoCommand ":WAVeform:SOURce CHANnel1"
Debug.Print "Waveform source: " + _
DoQueryString(":WAVeform:SOURce?")
' Choose the format of the data returned:
DoCommand ":WAVeform:FORMat WORD"
Debug.Print "Waveform format: " + _
DoQueryString(":WAVeform:FORMat?")
' Display the waveform settings from preamble:
Dim Preamble()
Summary of Contents for Infiniium 90000 Q-Series
Page 1: ...s1 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference...
Page 50: ...50 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 2 Setting Up...
Page 274: ...274 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 14 Digital Commands...
Page 292: ...292 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 15 Disk Commands...
Page 318: ...318 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 16 Display Commands...
Page 364: ...364 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 17 Function Commands...
Page 382: ...382 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 19 Histogram Commands...
Page 412: ...412 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 21 Limit Test Commands...
Page 416: ...416 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 22 Lister Commands...
Page 696: ...696 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 25 Measure Commands...
Page 702: ...702 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 26 Pod Commands...
Page 760: ...760 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 29 Self Test Commands...
Page 818: ...818 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 31 System Commands...
Page 830: ...830 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 32 Time Base Commands...
Page 930: ...930 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 33 Trigger Commands...
Page 1018: ...1018 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 37 Error Messages...
Page 1150: ...1150 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference 38 Sample Programs...
Page 1186: ...1186 Agilent Infiniium 90000 Series Oscilloscopes Programmer s Reference Index...