Remote Commands
R&S
®
FSVA3000/ R&S
®
FSV3000
1209
User Manual 1178.8520.02 ─ 01
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)
End Try
End Sub
14.15.2.8
Evaluation of Event Status Register
REM ------ Subroutine for evaluating the Event Status Register ------------
Public SUB Esrread()
Esr$ = SPACE$(20) 'Preallocate blanks to text
'variable
CALL InstrWrite (analyzer, "*ESR?") 'Read ESR
CALL InstrRead(analyzer, Esr$)
IF (VAL(Esr$) AND 1) > 0 THEN Debug.Print "Operation complete"
IF (VAL(Esr$) AND 2) > 0 THEN Debug.Print "Request Control"
IF (VAL(Esr$) AND 4) > 0
THEN Debug.Print "Query Error"
IF (VAL(Esr$) AND 8) > 0
THEN Debug.Print "Device dependent error"
IF (VAL(Esr$) AND 16) > 0
THEN Debug.Print "Execution Error; Program aborted"'Output error message
STOP 'Stop software
END IF
IF (VAL(Esr$) AND 32) > 0
THEN Debug.Print "Command Error; Program aborted"'Output error message
STOP 'Stop software
END IF
IF (VAL(Esr$) AND 64) > 0 THEN Debug.Print "User request"
IF (VAL(Esr$) AND 128) > 0 THEN Debug.Print "Power on"END SUB
REM **********************************************************************
REM ------ Subroutine for evaluating the Event Status Register ------------
Public Sub Esrread()
Programming Examples