BASIC Program Example (SWP_PVST)
1
!RE-STORE"SWP_PVST"
2
!This program sweeps from 5 kHz to 15 kHz in 0.1 seconds to
3
!demonstrate how to set the sweep time. The program also sets
4
!the direction of the sweep.
5
!
10
!Assign I/O path between the computer and E1445A.
20
ASSIGN @Afg TO 70910
30
COM @Afg
40
!
50
!Set up error checking
60
ON INTR 7 CALL Errmsg
70
ENABLE INTR 7;2
80
OUTPUT @Afg;"*CLS"
90
OUTPUT @Afg;"*SRE 32"
100
OUTPUT @Afg;"*ESE 60"
110
!
120
!Call the subprograms
130
CALL Rst
140
CALL Swp_pvst
150
!
160
WAIT .1 !allow interrupt to be serviced
170
OFF INTR 7
180
END
190
!
200
SUB Swp_pvst
210 Swp_pvst:
!Subprogram which sets sweep direction, points, and time
220
COM @Afg
230
OUTPUT @Afg;"SOUR:FREQ1:MODE SWE;";
!sweep mode
240
OUTPUT @Afg;" :SOUR:FREQ1:STAR 5E3;";
!start frequency
250
OUTPUT @Afg;" :SOUR:FREQ1:STOP 15E3;";
!stop frequency
260
OUTPUT @Afg;" :SOUR:SWEEP:DIR DOWN;";
!sweep direction
270
OUTPUT @Afg;" :SOUR:SWEEP:POIN 100;";
!sweep points
280
OUTPUT @Afg;" :SOUR:SWE:COUN INF;";
!sweep count
290
OUTPUT @Afg;" :TRIG:SWE:SOUR TIM;";
!sweep advance source
300
OUTPUT @Afg;" :SOUR:SWE:TIME .12375;";
!sweep time
310
OUTPUT @Afg;":SOUR:FUNC:SHAP SIN;";
!function
320
OUTPUT @Afg;":SOUR:VOLT:LEV:IMM:AMPL 5 V"
!amplitude
330
OUTPUT @Afg;"INIT:IMM"
!wait-for-trigger state
340
SUBEND
350
!
360
SUB Rst
370 Rst:
!Subprogram which resets the E1445.
380
COM @Afg
390
OUTPUT @Afg;"*RST;*OPC?"
!reset the AFG
400
ENTER @Afg;Complete
410
SUBEND
420
!
430
SUB Errmsg
Continued on Next Page
136 Sweeping and Frequency-Shift Keying
Chapter 4
Summary of Contents for E1445A
Page 2: ......
Page 14: ...Notes 12 Agilent E1445A User s Manual Contents...
Page 18: ...Notes 16 Agilent E1445A Arbitrary Function Generator User s Manual...
Page 19: ...Notes Agilent E1445A Arbitrary Function Generator User s Manual 17...
Page 20: ...Notes 18 Agilent E1445A Arbitrary Function Generator User s Manual...
Page 54: ...Notes 52 Getting Started Chapter 1...
Page 84: ...Notes 82 Generating Standard Waveforms Chapter 2...
Page 204: ...Notes 202 Arming and Triggering Chapter 5...
Page 432: ...Figure 9 1 E1445A Status Groups and Associated Registers 430 AFG Status Chapter 9...
Page 446: ...Notes 444 AFG Status Chapter 9...
Page 464: ...Notes 462 Agilent E1445A Specifications Appendix A...
Page 534: ...Notes 532 Agilent E1445A User s Manual Index...