Download Print this page

Keithley ADC-16 User Manual page 47

Analog input board

Advertisement

ADC-16 USER GUIDE
MULTIPLE BOARD SYSTEMS
Systems with more than one boarc must use more than one Handle. The following example shows
how to obtain and use the Handles in a system with two
ADC-16s.
BrdNum
=
0
'First board
CALL ABSOLUTE (BrdNum, ADCl6A, Derr, ADCl6GetDevHandle)
BrdNum
=
1
'Second board
CALL ABSOLUTE (BrdNum, ADCl6B, Derr
,
ADCl6GetDevKandle)
Subsequent calls would use the Handles of either Board (ADC16A or ADC16B) to determine the
selected board.
TYPES OF CALL COMMANDS
Two types of Call commands are available to control the
ADC-16
once the board and the driver are
installed and initialized. These are Immediate Operation commands and Frame based commands.
IMMEDIATE OPERATION COMMANDS
Several single-function commands may be executed without any prior setup. The simplest of these is
KADRead
,
which selects an input channel, an input gain, and then performs a single A/D
conversion. The syntax for this command is as follows:
For a single
A/D
conversion on Channel 0 with Gain Range 0, the call would be
Chan
=
0: Gain = 0
CALL ABSOLUTE (DevHandle, Chan, Gain, ADValue, Derr,
KADRead)
PRINT "The A/D returned", ADValue
Note that the ADVulue and the DevHandle are
Long Integers
and must be declared in the variable
declaration section. The ADC-16 data is returned in the least significant fifteen bits of ADValue, if bit
sixteen is zero multiply the data by minus one.
MULTIPLE BOARD SYSTEMS
Systems with more than one board must use more than one Handle. The following example takes an
A/D
reading from Channel 0 of the first Board and Channel 5 of the second.
BrdNum
=
0
'First board
CALL ABSOLUTE(BrdN~,ADCl6A,Derr,ADCl6GetDevHandle)
BrdNum = 1
'Second board
CALL ABSOLUTE (BrdNum, ADCl6B, Derr
,
ADCl6GetDevHandle)
Chan = 0: Gain = 0
CALL ABSOLUTE(ADC16A, Chan, Gain, ADValue, Derr, KADRead)
PRINT "The first Board returned", ADValue
Chan = 5: Gain
=
0
CALL ABSOLUTE(ADC16B, Chan, Gain, ADValue, Derr, KADRead)
PRINT "The second Board returned", ADValue
6 - 16

Advertisement

loading