Technical data
System Commands 29
Agilent Infiniium 90000 Series Oscilloscopes Programmer's Reference 753
:SYSTem:SETup
Command :SYSTem:SETup <binary_block_data>
The :SYSTem:SETup command sets up the oscilloscope as defined by the
data in the binary block of data from the computer.
<binary
_block_data>
A binary block of data, consisting of bytes of setup information. The
number of bytes is a dynamic number that is read and allocated by
oscilloscope's software.
Example This example reads setup information from a file and restores it to the
oscilloscope.
' Read setup from a file:
Dim strPath As String
strPath = "c:\scope\config\setup.dat"
Dim hFile As Long
hFile = FreeFile
Dim varSetup As Variant
Open strPath For Binary Access Read As hFile ' Open file for input.
Get hFile, , varSetup ' Read data.
Close hFile ' Close file.
' Write setup to oscilloscope.
myScope.WriteIEEEBlock ":SYSTem:SETup", varSetup
Debug.Print "Setup bytes restored: " + CStr(LenB(varSetup))
Query :SYSTem:SETup?
The :SYSTem:SETup? query outputs the oscilloscope's current setup to the
computer in binary block data format as defined in the IEEE 488.2
standard.
Returned Format
[:SYSTem:SETup] #NX...X<setup_data_string><NL>
The first character in the setup data block is a number added for disk
operations.
Example This example stores the current oscilloscope setup to the variable,
varSetup, and then saves it to a file.
' Get setup from the oscilloscope.
Dim varSeup As Variant
myScope.WriteString ":SYSTem:HEADer OFF" ' Response headers off.
myScope.WriteString ":SYSTem:SETup?"
varSetup = myScope.ReadIEEEBlock(BinaryType_UI1)
' Output setup string to a file:
Dim strPath As String
strPath = "c:\scope\config\setup.dat"
Dim hFile As Long
hFile = FreeFile
Open strPath For Binary Access Write Lock Write As hFile