User`s manual
1080 !
1090 SUB Seq_list
1100 Seq_list: !This subprogram downloads the sequence list (repetition
1110 !count, marker, segment address) to sequence memory over
1120 !the VXIbus.
1130 INTEGER Sequence(1:2,1:2)
1140 REAL Addrm1,Addrm2
1150 COM @Afg,Base_addr
1160 CONTROL 16,25;3!access A24 space with WRITEIO
1170 OUTPUT @Afg;"SOUR:LIST1:SEGM:SEL SINE" !determine segment address
1180 OUTPUT @Afg;"SOUR:LIST1:SEGM:ADDR?"
1190 ENTER @Afg;Addrm1
1200 Addrm1=Addrm1/8 ! /8 to set starting address (boundary) of segment
1210 !
1220 !Sequence (1,1) is the repetition count and marker enable for
1230 !segment SINE. Sequence (1,2) is the starting address of segment SINE.
1240 Sequence(1,1)=(SHIFT(4096-2,-4)+Addrm1 DIV 65536)
1250 Sequence(1,2)=(Addrm1 MOD 65536-65536*(Addrm1 MOD 65536>32767))
1260 !
1270 OUTPUT @Afg;"SOUR:LIST1:SEGM:SEL TRI" !determine segment address
1280 OUTPUT @Afg;"SOUR:LIST1:SEGM:ADDR?"
1290 ENTER @Afg;Addrm2
1300 Addrm2=Addrm2/8 ! /8 to set starting address (boundary) of segment
1310 !
1320 !Sequence (2,1) is the repetition count, marker enable, and last point
1330 !indication for the segment sequence. Sequence (2,2) is the starting
1340 !address of segment TRI.
1350 Sequence(2,1)=(SHIFT(4096-1,-4)+Addrm2 DIV 65536)+12
1360 Sequence(2,2)=Addrm2 MOD 65536-65536*(Addrm2 MOD 65536>32767)
1370 !
1380 OUTPUT @Afg;"SOUR:LIST1:SSEQ:SEL WAVE_OUT" !sequence name
1390 OUTPUT @Afg;"SOUR:LIST1:SSEQ:DEF 2" !segments in sequence
1400 OUTPUT @Afg;"SOUR:ARB:DOWN VXI,WAVE_OUT,2"
1410 OUTPUT @Afg;"*OPC?"
1420 ENTER @Afg;Ready
1430 !
1440 !Download the waveform sequence to sequence memory using WRITEIO
1450 !and the AFG’s Sequence register. The register’s address is
1460 !located in A24 address space.
1470 WRITEIO -16,Base_addr+IVAL("22",16);Sequence(1,1) !16 MS Bits
1480 WRITEIO -16,Base_addr+IVAL("24",16);Sequence(1,2) !16 LS Bits
1490 WRITEIO -16,Base_addr+IVAL("22",16);Sequence(2,1) !16 MS Bits
1500 WRITEIO -16,Base_addr+IVAL("24",16);Sequence(2,2) !16 LS Bits
1510 OUTPUT @Afg;"SOUR:ARB:DOWN:COMP" !disable downloading
1520 SUBEND
1530 !
1540 SUB A24_offset
1550 A24_offset:!Subprogram which determines the base address for
1560 !the AFG registers in A24 address space.
1570 COM @Afg,Base_addr
Continued on Next Page
Chapter 7 High Speed Operation 267