Download Print this page

Keithley ADC-16 User Manual page 33

Analog input board

Advertisement

ADC-16 USER
GUIDE
6. EITHER
a. Execute a simple ADC-16 operation.
OR
b. Select the desired group of ADC-16 operations, referred to as the group's Frame. Execute
these operations, taking some data.
*
Indicates that this function is performed in the "Quick-Start'' programs. (see next section).
Choose Step 6a for simple applications such as performing a single A/D conversion or reading a
digital input port. Choose 6b for more complex operations such as an interrupt-based scan of the
multiple channels.
The following sections describe the various parts of the program flow diagram. However, many
programmers may learn faster simply by referring to the example programs in the Distribution
Software.
Quick-Start Program
To aide in the creation of programs, the Distribution Software includes a Quick-Starf program, which
includes all driver loading, pointer definition, and ADC-16 initialization. For interpreted BASIC, the
Quick-Start program is ADC16.BAS
.
The program is in standard BASIC source code with an Insert
Your Code Here section.
When you begin a program, it will be easiest to begin with the Quick-Start program and add new
sections to the existing code. The alternative is to struggle through rewriting the driver, pointer, and
initialization code.
Initializing Pointers And Loading The Driver
The last part
of
Section 6.2 contains a listing of an Interpreted BASIC example program. You may
wish to refer to this example program during the discussions in this section.
In Interpreted BASIC, the driver and a number of pointers to the driver must be loaded within the
program itself. The entry-point variables must be loaded at this time (each command has a unique
entry point). This is performed by a subroutine in ADC16.BAS. Since there are several entry points,
it
is recommended that the ADC16.BAS Quick-Start program (or one of the example programs) be used
as the starting point for new programs. This will ensure the correct loading of pointers. The following
statement calls the subroutine that loads the driver entry points.
2 6 0
GOSUB
7 1 0
7
10
&Cl6DEVOPEN%=O
7 2 0
ADCl6GE!FDEVHANDLE%=3
xxx
RETURN
6 - 2

Advertisement

loading