Querying The Measured Statistical Values Of Period A & Period B Measurement (For Gp-Ib) - YOKOGAWA TA720 User Manual

Time interval analyzer communication interface
Hide thumbs Also See for TA720:
Table of Contents

Advertisement

6.6 Querying the Measured Statistical Values of Period A & Period B Measurement (for GP-IB)
6.6 Querying the Measured Statistical Values of Period A & Period B
Measurement (for GP-IB)
Sample3(GPIB)
————————————————————————————————————————————————————————————————————————————————————————
Private Function GetStatistics2() As Integer
Dim msg As String
Dim qry As String
Dim sts As Integer
Dim winlabel(10) As String
Dim i As Integer
Dim temp As String
msg = Space$(100)
qry = Space$(100)
sts = InitGpib
If (sts <> 0) Then
End If
msg = "*RST" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":MEASURE:MODE HHISTOGRAM" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":MEASURE:FUNCTION PPERIOD,AB" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":SAMPLE:GATE:MODE EVENT;EVENTSIZE 10000" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":HHISTOGRAM:MODE MULTI" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":HHISTOGRAM:MULTI:SIZE 10" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":HHISTOGRAM1:MULTI:TVALUE 37ns" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
msg = ":HHISTOGRAM2:MULTI:TVALUE 37ns" + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
End If
winlabel(0) = "3": winlabel(1) = "4":
winlabel(3) = "6": winlabel(4) = "7":
winlabel(6) = "9": winlabel(7) = "10": winlabel(8) = "11"
winlabel(9) = "14"
For i = 1 To 10
IM 704510-17E
Get Statistics
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
Call DisplayGPIBError(sts, msg)
GetStatistics2 = 1
Exit Function
msg = ":HHISTOGRAM:MULTI:WINDOW" + LTrim(Str(i)) _
+ ":LABEL " + winlabel(i - 1) + term
sts = ilwrt(Dev, msg, Len(msg))
If (sts < 0) Then
'Command buffer
'Query buffer
'Widow Label
'Initialize GPIB
'Initialize Setting Parameter
'Send Command
'Mode = HardHistogram
'Send Command
'Function = Period & Period Ch = A,B
'Send Command
'Gate = Event; EventSize 10000
'Send Command
'WindowMode = MULTI
'Send Command
'WINDOW SIZE 10
'Send Command
'Meas1: T=37ns
'Send Command
'Meas2: T=37ns
'Send Command
'Set Window Label
winlabel(2) = "5"
winlabel(5) = "8"
'Send Command
6
6-11

Advertisement

Table of Contents
loading

Table of Contents