Rohde & Schwarz R&S FSVR Guide De Démarrage Rapide page 167

Table des Matières

Publicité

®
R&S
FSVR
REM ***********************************************************************
Public Sub HCopy()
Dim retCount as Long
Dim SRQWaitTimeout As Long
Dim eventType As Long
Dim eventVi As Long
Dim statusSRQ As Long
DIM Devices(100) as string
FOR i = 0 TO 49
Devices$(i) = Space$(50)
NEXT i
'--------- Default setting of the R&S FSV -------------------------------
CALL SetupStatusReg
CALL InstrWrite(analyzer,"*RST")
CALL InstrWrite(analyzer,"INIT:CONT OFF")
'Single sweep mode
CALL InstrWrite(analyzer,"SYST:DISP:UPD ON")
'Screen display on
'--------- Measurement settings ------------------------------------------
CALL InstrWrite(analyzer,"FREQ:CENT 100MHz;SPAN 10MHz")
'Frequency setting
CALL InstrWrite(analyzer,"DISP:TRAC:Y:RLEV -10dBm")
'Reference level
CALL InstrWrite(analyzer,"INIT;*WAI")
'--------- Querying the available output devices -------------------------
CALL InstrWrite(analyzer,"SYST:COMM:PRIN:ENUM:FIRSt?")
'Read out and display first output device
CALL InstrRead(analyzer,Devices$(0), 50, retCount)
Debug.Print "Printer 0: "+Devices$(0)
For i = 1 to 99
CALL InstrWrite(analyzer,"SYST:COMM:PRIN:ENUM:NEXT?")
'Read out next printer name
CALL InstrRead(analyzer,Devices$(i)
IF Left$(Devices$(i),2) = "''" THEN GOTO SelectDevice
'Stop at end of list
Debug.Print "Printer"+Str$(i)+": " Devices$(i)
'Display printer name
NEXT i
SelectDevice:
'---- Selection of output device, printer language and output interface ----
CALL InstrWrite(analyzer,"SYST:COMM:PRIN:SEL "+ Devices(6))
'Printer selection #6
CALL InstrWrite(analyzer,"HCOP:DEST 'SYST:COMM:PRIN'")
'Configuration: "Printout to
'printer interface"
CALL InstrWrite(analyzer,"HCOP:DEV:LANG GDI")
Guide de démarrage rapide 1311.0670.63 ─ 03
Brève introduction à la commande à distance
Exemples détaillés de programmation
'Create buffer for printer name
'Preallocate buffer for printer name
'Configure status register
'Reset instrument
'Perform measurement
167

Publicité

Table des Matières
loading

Ce manuel est également adapté pour:

R&s fsvr7R&s fsvr13R&s fsvr30R&s fsvr40

Table des Matières