
ACROSSER TECHNOLOGY
26
3.5.2 Programming With The BASICA Driver
The BASICA driver routine is provided with BASICA
source program. This routine is saved in the "BAS_LIB"
sub-directory with file name of "B3001LIB.BAS". It is a
subroutine started with a line number of 8000. It performs
a trigger to the A/D converter and wait until data is
returned. Two variables have to be assigned before
entering this subroutine.
Input Variables
BASEPORT-
The base port address of AR-B3001 I/O
port. It can be located in the range of &H100 to &H3FC.
ADCHN -
The channel number of the input channel for
which analog input is going to be acquired.
Returns
ADDATA -
Converted data. The valid data is in the range
of -4095 to +4095. The respective voltage of this data is
equals to (5/4096) * ADDATA Volts. If the input analog
voltage is out of range (-5V to +5V), ADDATA will equals
to -4096 or +4096.
Example
1000 BASEPORT = &H3E0
1010 ADCHN = 0
1020 GOSUB 8000
1030 PRINT ADDATA; "
1040 VOLTAGE = (INT(ADDATA*5000/4096)/1000)
1050 PRINT USING "+#.###"; VOLTAGE
Summary of Contents for AR-B3001
Page 4: ...ACROSSER TECHNOLOGY 4 This page is intentionally left blank...
Page 6: ...ACROSSER TECHNOLOGY 6 Figure 2 1 Board Layout of AR B3001...
Page 14: ...ACROSSER TECHNOLOGY 14 This page is intentionally left blank...
Page 28: ...ACROSSER TECHNOLOGY 28 This page is intentionally left blank...
Page 41: ...ACROSSER TECHNOLOGY 41...