C and QuickBASIC
Programs
The C program MULTFUNC.C is in directory "CPROG", and the
QuickBASIC program MULTFUNC.BAS is in directory "QBPROG" on
the example program disk HP P/N E1340-10036.
Internally
Triggering a Burst
of Cycles
The following program outputs a burst of 50,000 waveform cycles when the
AFG’s internal trigger occurs.
HP IBASIC (INT_BRST)
1 !RE-SAVE"INT_BRST"
2 GET "SUBS",500,3 !place subprograms at line 500, continue w/line 3
3 !Program which demonstrates how to output a burst of waveform cycles
4 !when an internal trigger is received.
5 !
10 !Compute the E1340 base address in E1300 A16 address space
20 COM Base_addr
30 Base_addr=DVAL("1FC000",16)+(80*64) !base address
40 !
50 !Reset the AFG
60 Afg_reset
70 !Set function and load RAM
80 Function(0,0) !sine wave in RAM 0
90 !Set the frequency (frequency register 2)
100 Frequency2(10000.) !10 kHz
110 !Set amplitude, offset, impedance, correction
120 Amplitude(5,0,50,0) !5 Vpk, 0V, 50 ohms, correction enabled
130 !Set the burst count
140 Burst(5.0E+4) !50k cycles
150 !Set the Aux Out level, Aux In level, clock source, Aux Out signal,
160 !RAM bank, frequency register, and output mode.
170 Mode(0,0,2,1,0,1,3) !norm,norm,burst,pulse/cycle,bank 0,reg 2,inbrst
180 END
190 !
Comments
1. To output a counted burst, the clock source must be set to "Burst"
and the output mode set to "Internal Burst". The burst count range is
1 to 65534. The reset value is undefined (register-based).
2. This program sets the output frequency from Frequency Register 2.
Either Frequency Register 1 or Register 2 and be used to set a
continuous (fixed) frequency.
260 HP E1340A Register-Based Programming
Appendix C
Summary of Contents for E1340A
Page 12: ...Notes 12 HP E1340A Arbitrary Function Generator Module User s Manual ...
Page 14: ...14 HP E1340A Arbitrary Function Generator Module User s Manual ...
Page 42: ...Chapter 2 Generating Standard Waveforms with the HP E1340A 42 ...
Page 54: ...Chapter 2 Generating Standard Waveforms with the HP E1340A 54 ...
Page 58: ...Chapter 3 Generating Arbitrary Waveforms with the HP E1340A 58 ...
Page 84: ...Chapter 4 HP E1340A Sweeping and Frequency Shift Keying 84 ...
Page 130: ...Chapter 6 HP E1340A High Speed Operation 130 ...
Page 202: ...202 HP E1340A SCPI Conformance Information Chapter 7 ...
Page 218: ...218 HP E1340A Specifications Appendix A ...
Page 284: ...284 HP E1340A Register Based Programming Appendix C ...
Page 295: ...Index HP E1340A Arbitrary Function Generator User s Manual 295 ...