User`s manual

Using the
Divide-by-N
Frequency
Generator
The DIV_N program shows how to set the AFG trigger source. The program
selects the AFG’s divide-by-N frequency generator (
[SOURce:]FREQuency2
subsystem). This generator is recommended for use with the AFG’s 40 MHz
reference oscillator (also selected in the program) to produce exact frequencies
such as 10 MHz, 20 MHz, etc,.
The steps of this program are:
1. Select the 40 MHz reference oscillator
[SOURce:]ROSCillator:SOURce <source>
2. Select the divide-by-N time base
TRIGger[:STARt]:SOURce <source>
3. Set the output frequency
[SOURce:]FREQuency2[:CW | :FIXed] <frequency>
4. Set the output function
[SOURce:]FUNCtion[:SHAPe] <shape>
5. Set the signal amplitude
[SOURce:]VOLTage[:LEVel][:IMMediate][:AMPLitude] <amplitude>
6. Place the AFG in the wait-for-arm state
INITiate[:IMMediate]
BASIC Program Example (DIV_N)
1 !RE-STORE"DIV_N"
2 !This program selects the 40 MHz reference oscillator and the
3 !SOURce:FREQuency2 subsystem (divide-by-N frequency synthesis) to
4 !generate an “exact” square wave frequency of 10 MHz.
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 which reset the AFG and which
130 !generate the square wave.
140 CALL Rst
150 CALL Squ_wave
Continued on Next Page
174 Arming and Triggering Chapter 5