BASIC Program Example (DRIFT)
1
!RE-STORE"DRIFT"
2
!This program sets up two AFG’s to output 1 MHz square waves.
3
!To prevent these signals from drifting and creating a phase
4
!difference, the reference oscillator of a "master" AFG is shared
5
!by a "servant" AFG. The master’s reference oscillator signal is
6
!output on VXI backplane trigger line ECLT0.
10
!Assign I/O paths between the computer and the AFGs.
20
ASSIGN @Afg_m TO 70910
!master AFG
30
ASSIGN @Afg_s TO 70911
!servant AFG
40
COM @Afg_m,@Afg_s
50
!
60
!Set up error checking
70
CALL Rst
80
OUTPUT @Afg_m;"*CLS"
!master
90
OUTPUT @Afg_m;"*SRE 32"
100
OUTPUT @Afg_m;"*ESE 60"
110
OUTPUT @Afg_m;"*OPC?"
120
ENTER @Afg_m;Complete
130
!
140
OUTPUT @Afg_s;"*CLS"
!servant
150
OUTPUT @Afg_s;"*SRE 32"
160
OUTPUT @Afg_s;"*ESE 60"
170
OUTPUT @Afg_s;"*OPC?"
180
ENTER @Afg_s;Complete
190
ON INTR 7 CALL Errmsg
200
ENABLE INTR 7;2
210
!
220
!Call the subprograms which reset the AFGs output sine waves 180
230
!degrees out of phase.
240
CALL Square_wave_m
250
CALL Square_wave_s
260
!
270
!Set master AFG to wait-for-arm state
280
OUTPUT @Afg_m;"INIT:IMM"
!start waveform
290
!
300
WAIT .1 !allow interrupt to be serviced
310
OFF INTR 7
320
END
330
!
340
SUB Square_wave_m
350 Square_wave_m:
!Subprogram which sets up master AFG
360
COM @Afg_m,@Afg_s
370
OUTPUT @Afg_m;"SOUR:ROSC:SOUR INT2;";
!reference osc. source
380
OUTPUT @Afg_m;":TRIG:STAR:SOUR INT2;";
!trigger source
390
OUTPUT @Afg_m;":SOUR:FREQ2:FIX 1E6;";
!frequency
400
OUTPUT @Afg_m;":SOUR:FUNC:SHAP SQU;";
!function
410
OUTPUT @Afg_m;":SOUR:VOLT:LEV:IMM:AMPL 5V"
!amplitude
Continued on Next Page
220 Marker Outputs/Multiple AFG Operations
Chapter 6
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...