7-84
Chapter 7
Programming Examples
Analyzer System Setup Examples
Example 5C: Saving and Restoring the Analyzer Instrument State
NOTE
The instrument state may also be stored in the analyzer's internal registers.
This is the fastest and most efficient method for toggling between instrument
states. This example is for use when the analyzer's internal memory is full, or
when the are other internal-memory limitations.
This example demonstrates how to use both the learn string and the calibration arrays to
completely re-program the analyzer state. If you were performing two entirely different
measurements on a device and wanted to quickly change between instrument states and
perform the measurements, this example program is a potential solution.
The example will request the learn string and calibration array from the analyzer and
store them in a disk file on the system controller. Once the storage is complete, the
operator will be prompted to change the state of the analyzer and then re-load the state
that was previously stored in the disk file. Once the file is created on the disk, the state
information can be retrieved from the controller and restored on the analyzer.
NOTE
The disk file can only be created once. Errors will occur if the operator
repeatedly tries to recreate the file.
For this example, only a thru calibration will be performed and transferred. This means
only one calibration array will be read from the analyzer and written to the disk file with
the instrument state. To work with more elaborate calibrations, additional arrays will
need to be defined and transferred to the disk file. This is not difficult, but requires some
further programming steps which were omitted in the interest of presenting a simple
example.
The following is an outline of the program's processing sequence:
• An I/O path is assigned for the analyzer.
• A binary path is assigned.
• The integers for reading the headers are defined.
• The system is initialized.
• An array is created to hold the learn string.
• The learn string is requested by the controller.
• The number of points in the trace is read.
• The controller allocates an array for the calibration data.
• The calibration data is read into the controller.
• The controller creates and assigns a data file for the calibration array and the learn
string.
• The learn string and calibration array are stored in the disk file.
• The operator presses
on the controller to read the calibration data back into the
analyzer.
Enter
Summary of Contents for 8719ES
Page 15: ...1 1 1 Alphabetical Command Reference ...
Page 293: ...2 1 2 Introduction to Instrument Control ...
Page 310: ...3 1 3 GPIB Programming ...
Page 334: ...4 1 4 Reading Analyzer Data ...
Page 343: ...5 1 5 Data Processing Chain ...
Page 350: ...6 1 6 Error Reporting ...
Page 364: ...7 1 7 Programming Examples ...
Page 502: ...A 1 A Preset Conditions ...
Page 517: ...B 1 B Command Listings ...