EasyManua.ls Logo

HP 8360 L Series - Looping and Synchronization, Example Program; Program Comments

HP 8360 L Series
429 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Looping and
Clear and reset the controller and type in the following program:
Synchronization,
Example
Program
6
10
Source=719
20
ABORT 7
30
LOCAL 7
40 CLEAR Source
50
REMOTE Source
60
CLS
70
OUTPUT
Source;"*RST"
80
OUTPUT
Source;"FREQ:START
4 GHZ; STOP 5 GHZ;
MODE
SWEEP"
90
OUTPUT
Source;"POWER:LEVEL
-1 DBM; STATE
ON"
100 OUTPUT
Source;"SWEEP:TIME
1"
110
OUTPUT
Source;"*OPC?"
120
ENTER Source;X
130
REPEAT
140
DISP "Enter number of sweeps to take :
CO to exit]";
150
INPUT N
160
IF
N>O
THEN
170
FOR
I=1
TO N
180
DISP "Taking number :
";I
sweep
190
OUTPUT
Source;"INIT:IMM;*OPC?"
200
ENTER \
210
NEXT I
220 END IF
230 UNTIL N=O
240
END
Run the program.
Program Comments
10: Assign the source’s HP-IB address to a variable.
20 to 50: Abort any HP-IB activity and initialize the HP-IB
interface.
60: Clear the computer’s display.
70:
Set the
source to its initial state
for
programming.
80: Set up the frequency parameters using a compound message.
90: Set up the source’s power level and state using a compound
message.
100: Set up the source’s sweep time to 1 second.
110: Send the *OPC? command to the source to ensure that the
previous commands are completed and the source is ready to begin
controlled sweeps.
120: Enter the response to the *OPC? into the variable X. The
response should be a ‘1’.
130: Start of the loop.
Getting Started Programming l-99

Table of Contents

Related product manuals