More Complex Programming Examples
R&S FSMR
1166.3363.12 7.46
E-1
Creating a File on the Instrument
In the following example, the TEST1.SET file available on the controller is stored in the instrument under
D:\USER\DATA\DUPLICAT.SET.
REM ************************************************************************
Public Sub WriteFile()
'--------- Generate variables ----------------------------------------------
FileBuffer$ = Space$(100000)
'Buffer for file
Dim digits As Long
'Number of digits of
'length
information
Dim fileBytes As Long
'Length of file in bytes
fileSize$ = Space$(100)
'Length of file as a string
result$ = Space$(100)
'Buffer for simple results
'--------- Default setting of status register ------------------------------
Call SetupStatusReg
'Configure status register
'--------- Prepare the definite length block data --------------------------
fileBytes = FileLen("H:\work\vb\test1.set") 'Determine length of file
fileSize$ = Str$(fileBytes)
digits = Len(fileSize$) – 1
'Determine number of digits of
fileSize$ = Right$(fileSize$, digits)
'length information
FileBuffer$ = "#" + Right$(Str$(digits), 1) + fileSize$
'Store
length
information
in
'file
buffer
'--------- Read file from controller ---------------------------------------
Open "H:\work\vb\TEST1.SET" For Binary As #1
FileBuffer$ = FileBuffer$ + Left$(Input(fileBytes, #1), fileBytes)
Close #1
'--------- Write file ------------------------------------------------------
-
Call ibwrt(analyzer%, "SYST:COMM:GPIB:RTER EOI")
'Set receive
'terminator
on
the
'instrument
Call ibwrt(analyzer%, "MMEM:DATA 'D:\USER\DATA\DUPLICAT.SET'," +
FileBuffer$)
'Select file
END SUB
REM ************************************************************************
Содержание FSMR
Страница 1: ...R S FSMR Measuring Receiver Operating Manual Test Measurement Operating Manual 1313 9723 12 01...
Страница 4: ......
Страница 22: ......
Страница 26: ...Contents Preparing for Operation R S FSMR 1155 5047 12 I 1 2 E 2 Fig 1 1 Front View...
Страница 28: ...Front View R S FSMR 1166 3363 12 1 2 E 2 Fig 1 1 Front View...
Страница 30: ...Front View R S FSMR 1166 3363 12 1 4 E 2 Fig 1 1 Front View...
Страница 32: ...Front View R S FSMR 1166 3363 12 1 6 E 2 Fig 1 1 Front View...
Страница 34: ...Front View R S FSMR 1166 3363 12 1 8 E 2 Fig 1 1 Front View...
Страница 66: ......
Страница 86: ......
Страница 130: ...Menu Overview R S FSMR 1166 3363 12 3 42 E 3 Menu Overview another Keys MKR Key...
Страница 141: ...R S FSMR Menu Overview 1166 3363 12 3 53 E 3 LOCAL Menu LOCAL...
Страница 144: ......
Страница 150: ......
Страница 156: ......
Страница 202: ......
Страница 208: ......
Страница 216: ......
Страница 230: ......
Страница 254: ......
Страница 280: ......
Страница 348: ......
Страница 376: ...Configuration Setup R S FSMR 1166 3363 12 4 19 28 E 2...
Страница 390: ......
Страница 408: ......
Страница 428: ......
Страница 446: ......
Страница 536: ......
Страница 799: ......
Страница 921: ......
Страница 935: ......
Страница 937: ...Contents Error Messages R S FSMR 1166 3363 12 I 9 2 E 1...