Quick Start
R&S
®
ESR
125
User Manual 1175.7068.02 ─ 12
CALL InstrRead(analyzer, CFfrequency$, 20, retCount)
'Read value
CR&S FSVan$ = SPACE$(20) 'Provide text variable (20 characters)
CALL InstrWrite(analyzer, "FREQ:SPAN?")
'Request span
CALL InstrRead(analyzer, CR&S FSVan$, 20, retCount)
'Read value
RLlevel$ = SPACE$(20) 'Provide text variable (20 characters)
CALL InstrWrite(analyzer, "DISP:TRAC:Y:RLEV?")
'Request ref level setting
CALL InstrRead(analyzer, RLlevel$, 20, retCount)
'Read value
REM --------- Displaying values in the Immediate window --------------------
Debug.Print "Center frequency: "; CFfrequency$,
Debug.Print "Span: "; CR&S FSVan$,
Debug.Print "Reference level: "; RLlevel$,
END SUB
REM*************************************************************************
3.6.1.6
Marker Positioning and Readout
REM -------- Example of marker function -----------------------------------
PUBLIC SUB ReadMarker()
Dim retCount as Long
CALL InstrWrite(analyzer, "CALC:MARKER ON;MARKER:MAX")
'Activate marker 1 and search for peak
MKmark$ = SPACE$(30) 'Provide text variable (30 characters)
CALL InstrWrite(analyzer, "CALC:MARK:X?;Y?")
'Query frequency and level
CALL InstrRead(analyzer, MKmark$, 30, retCount)
'Read value
REM --------- Displaying values in the Immediate window -------------------
Debug.Print "Marker frequency/level "; MKmark$,
END SUB
REM ************************************************************************
3.6.1.7
Command Synchronization
The synchronization methods used in the following example are described in the Oper-
ating Manual, chapter "Remote Control - Basics", section "Command Sequence and
Command Synchronization".
REM --------- Commands for command synchronization ------------------------
PUBLIC SUB SweepSync()
Dim retCount as Long
Dim SRQWaitTimeout As Long
Dim eventType As Long
Dim eventVi As Long
REM The command INITiate[:IMMediate] starts a single sweep if the
Brief Introduction to Remote Control