Remote Control
R&S
®
ESR
1004
User Manual 1175.7068.02 ─ 12
hasErr = False
Console.WriteLine(result)
Else
Console.WriteLine(result)
End If
Loop While hasErr
End Sub
11.17.1.7
Evaluation of SCPI Status Registers
REM ------ Subroutine for evaluating Questionable Status Register ---------
Public SUB Questionablestatus()
Ques$ = SPACE$(20)
'Preallocate blanks to text
'variable
CALL InstrWrite (analyzer, "STATus:QUEStionable:EVENt?")
CALL InstrRead(analyzer, Ques$)
Debug.Print "Questionable Status:"; Ques$
END SUB
REM ***********************************************************************
REM ------ Subroutine for evaluating Operation Status Register ------------
Public SUB Operationstatus()
Oper$ = SPACE$(20) 'Preallocate blanks to text
'variable
CALL InstrWrite (analyzer, "STATus:OPERation:EVENt?")
CALL InstrRead(analyzer, Oper$)
Debug.Print "Operation Status:"; Oper$
END SUB
REM ***********************************************************************
REM ------ Subroutine for evaluating Questionable Status Register ---------
Public Sub Questionablestatus()
Dim myQSR As String = Nothing
Try
myQSR = mbSession.Query("STATus:QUEStionable:EVENt?") 'Read QSR
Console.WriteLine("Questionable Status:" + myQSR)
Catch exp As Exception
Console.WriteLine(exp.Message)
End Try
End Sub
REM ------ Subroutine for evaluating Operation Status Register ------------
Public Sub Operationstatus()
Dim myOSR As String = Nothing
Try
myOSR = mbSession.Query("STATus:OPERation:EVENt?") 'Read OSR
Console.WriteLine("Operation Status:" + myOSR)
Catch exp As Exception
Console.WriteLine(exp.Message)
Remote Control – Programming Examples