User`s manual

1580 CONTROL 16,25;2 !access A16 space with READIO and WRITEIO
1590 A16_addr=DVAL("D400",16) !AFG A16 base address
1600 Offset=READIO(-16,A16_addr+6) !read AFG offset register
1610 Base_addr=Offset*256 !shift offset for 24-bit address
1620 SUBEND
1630 !
1640 SUB Rst
1650 Rst: !Subprogram which resets the E1445.
1660 COM @Afg,Base_addr
1670 OUTPUT @Afg;"*RST;*OPC?" !reset the AFG
1680 ENTER @Afg;Complete
1690 SUBEND
1700 !
1710 SUB Wf_del
1720 Wf_del: !Subprogram which deletes all sequences and segments.
1730 COM @Afg,Base_addr
1740 OUTPUT @Afg;"FUNC:USER NONE" !select no sequences
1750 OUTPUT @Afg;"LIST:SSEQ:DEL:ALL" !Clear sequence memory
1760 OUTPUT @Afg;"LIST:SEGM:DEL:ALL" !Clear segment memory
1770 SUBEND
1780 !
1790 SUB Errmsg
1800 Errmsg:!Subprogram which displays E1445 programming errors
1810 COM @Afg,Base_addr
1820 DIM Message$[256]
1830 !Read AFG status byte register and clear service request bit
1840 B=SPOLL(@Afg)
1850 !End of statement if error occurs among coupled commands
1860 OUTPUT @Afg;""
1870 OUTPUT @Afg;"ABORT" !abort output waveform
1880 REPEAT
1890 OUTPUT @Afg;"SYST:ERR?" !read AFG error queue
1900 ENTER @Afg;Code,Message$
1910 PRINT Code,Message$
1920 UNTIL Code=0
1930 STOP
1940 SUBEND
Visual BASIC and
Visual C/C++ Program
Versions
The Visual BASIC example program, VXIDOWN.FRM, is in directory
“VBPROG” and the Visual C example program, VXIDOWN.C, is in
directory “VCPROG” on the CD that came with your Agilent E1445A.
The above example programs use the Agilent E1406A Command Module to
download the data into memory. However, the command module is only
used to demonstrate the downloading method for those programs. A better
method is to use an embedded controller. If you wish to use the
Agilent E1406A Command Module to download data, use the method
described in “Using Combined Waveform Segments and Segment
Sequences” on page 250.
268 High Speed Operation Chapter 7