Agilent Technologies E1446A Car Amplifier User Manual


 
150 OUTPUT @Amp;"*CLS"
160 OUTPUT @Amp;"*SRE 32"
170 OUTPUT @Amp;"*ESE 60"
180 !
190 !Call the subprograms
200 Rst
210 Sine_wave
220 !
230 WAIT .1 !allow interrupt to be serviced
240 OFF INTR 7
250 END
260 !
270 SUB Sine_wave
280 Sine_wave: !Subprogram which sets the E1445A to output a sine wave
290 COM @Afg,@Amp
300 OUTPUT @Afg;"SOUR:FREQ1:FIX 1E3;"; !frequency
310 OUTPUT @Afg;":SOUR:FUNC:SHAP SIN;"; !function
320 OUTPUT @Afg;":SOUR:VOLT:LEV:IMM:AMPL 2VPP;"; !amplitude
330 OUTPUT @Afg;":OUTP:LOAD:AUTO ON;"; !couple load to impedance
340 OUTPUT @Afg;":OUTP:IMP 50" !output impedance
350 !
360 !Set up the Agilent E1446A
370 OUTPUT @Amp;"INP1:IMP 50" !input impedance
380 OUTPUT @Amp;"INP1:ATT 3" !input attenuation (dB)
390 OUTPUT @Amp;"OUTP1:IMP 50;"; !main output impedance
400 OUTPUT @Amp;":OUTP1:ATT 0" !main output attenuation
410 !
420 OUTPUT @Afg;"INIT:IMM" !E1445A wait-for-arm state
430 SUBEND
440 !
450 SUB Rst
460 Rst: !Subprogram which resets the E1445A and E1446A
470 COM @Afg,@Amp
480 OUTPUT @Afg;"*RST;*OPC?" !reset the AFG
490 ENTER @Afg;Complete
500 OUTPUT @Amp;"*RST;*OPC?" !reset the AMP
510 ENTER @Amp;Complete
520 SUBEND
530 !
540 SUB Errmsg
550 Errmsg: !Subprogram which displays E1445/E1446 programming errors
560 COM @Afg,@Amp
570 DIM Message$[256]
580 !Read AFG (at sec addr 10) status byte register, clear service
590 !request bit
600 B=SPOLL(@Afg)
Continued on Next Page
Generating and Amplifying Sine Waves Programming the Agilent E1446A 2-13