34 Using the RF Multiplexers
Chapter 3
Saving and Recalling States
The *SAV
<numeric_state>
command saves the current instrument state.
The state number (0-9) is specified in the
<numeric_state>
parameter. The
channel states (channel closed to common) are saved.
The *RCL
<numeric_state>
command recalls a previously saved state.
Enter the number (0-9) in the
<numeric_state>
parameter of the desired
saved state. If *SAV was not previously executed using the selected
number, the RF Multiplexer will configure to the reset values (channel 0 to
COMmon on all banks).
Detecting Error Conditions
There are two general approaches to error checking. The simplest, but most
time consuming, is to ask the instrument whether there are errors at every
step of the switching process. This is called “polling” and is illustrated in the
following example.
Example: Polling Method
of Error Checking
05 DIM Err_num$ [256]
10 OUTPUT 70915; "CLOS(@101);:SYST:ERR?"
20 ENTER 70915;Err_num$
30 IF VAL (Err_num$) <> 0 THEN
40 PRINT "Error";Err_num$
50 STOP
60 END IF
70 . . . (program continues)
Example: Error Checking
Using Interrupts
The other approach involves the use of interrupts. The following program is
a method of checking for errors using interrupts as you program the RF
Multiplexer. The program monitors the RF Multiplexer’s Standard Event
Status Register for an error condition.
If no errors occur, the RF Multiplexer functions as programmed. If errors do
occur, the RF Multiplexer interrupts the computer, and the error codes and
messages are read from the error queue. This approach requires less
checking but is more complex. This BASIC example uses a GPIB select
code of 7, primary address of 09, and secondary address of 15 for the RF
Multiplexer.
10
!Call computer subprogram "Errmsg" if an RF Multiplexer programming
20
!error occurs. Enable the computer to respond to an interrupt from the
30
!RF Multiplexer.
35
!
40 ON INTR 7 CALL Errmsg
50 ENABLE INTR 7:2
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com
Содержание E1472A
Страница 3: ...Artisan Technology Group Quality Instrumentation Guaranteed 888 88 SOURCE www artisantg com...
Страница 9: ...8 Notes Artisan Technology Group Quality Instrumentation Guaranteed 888 88 SOURCE www artisantg com...
Страница 69: ...Artisan Technology Group Quality Instrumentation Guaranteed 888 88 SOURCE www artisantg com...