Software
1.
ADJU12.BAS

The ADJU12.BAS is used to adjust reference voltage, the factory settings of VR resistors are adjust to full scalar voltage (10V).

After you run this program, the output voltage of D/A channel 1 and channel 2 are set to full scalar voltage, so that you may screw VR2 and VR3 to adjust output voltage to full scalar voltage. To adjust A/D channel, you may connect D/A channel 1 and A/D channel then screw the VR3 until A/D input number equal to 4095.
2.
AUTO12.BAS

Loopback test program.
3.
ADDA12.BAS

Diagnostic program.
Diagnostic Test
1.
Insert the demonstration media into drive, then copy diagnostic program into your computer.
2.
Key in the BASIC test program, then type run. (please refer section 4)
3.
The screen will display:

which selection do you want?
1. D/A MODE
2. A/D MODE
4.
If you select "1. D/A MODE", pin 2 and pin 15 of D-type connector will output 64 steps saw-tooth wave.
5.
If you select "2. A/D MODE", screen will display each value (from 0 to 16383 of the 16 channel).
Programming Techniques Under MS/DOS
1.
Analog to digital (A/D) procedure

(1) Output channel number to port
 
OUT port , channel

(2) Clear register

OUT (port+1) , 0

(3) Start convert

FOR I = 1 to 6
A = INP(port + 12)
NEXT I
FOR I = 1 to 8
A = INP(port + 8)
NEXT I

(4) Read high byte (low nibble)

C = INP(port +3)
HB = (C/16 - INT(C/16)) * 16

(5) Read low byte (8 bits)

LB = INP(port + 2)

(6) Data

AD = HB * 256 + LB
2.
Digital to analog (D/A) procedure

(1) Output high byte (channel 1/low nibble)
OUT port + 5, Hdata
(2) Output low byte (channel 1/8 bits)
OUT port + 4, Ldata
(3) Output high byte (channel 2/low nibble)
OUT port + 7, Hdata
 (4) Output low byte (channel 2/8 bits)
OUT port + 6, Ldata
BASIC Test Program
10 CLS: PORT=368
20 LOCATE 5,18: PRINT " 12 BIT AD-DA CONVERSION CARD"
30 LOCATE 6,18: PRINT "======================="
40 LOCATE 9,20: PRINT "1. D/A CONVERSION DEMO"
50 LOCATE 11,20: PRINT "2. A/D CONVERSION DEMO"
60 A$=INKEY$: IF A$="" THEN 60
70 IF A$="1" TH
EN 200
80 IF A$="2" THEN 400
90 GOTO 10
200 CLS
202 LOCATE 5,15: PRINT "D/A CINVERSION DEMO"
204 LOCATE 7,15: PRINT "OUTPUT WAVEFORM FROM D/A PORT"
206 LOCATE 9,15: PRINT "PRESS ANY KEY RETURN MENU"
210 OUT PORT+4,0 : OUT PORT+6,0
220 FOR I = 0 TO 15
230 OUT PORT+5, I : OUT PORT+7,I
240 NEXT I
250 A$=INKEY$: IF A$="" THEN 210
260 GOTO 10
400 CLS
410 FOR CHANNEL = 0 TO 15
420 GOSUB 550
430 B = INP(PROT+3)
440 C = INP(PORT+2)
450 D = (B-16*(INT(B/16))) *256 + C
460 PRINT " CHANNEL= "; CHANNEL, "DATA= ":D
470 NEXT CHANNEL
480 PRINT:PRINT:PRINT
490 GOTO 410

550 OUT PORT+1,0
560 OUT PORT+0, CHANNEL
570 FOR I = 1 TO 6: A= INP(PORT+12):NEXT I
580 FOR I = 1 TO 8: A= INP(PORT+8):NEXT I
590 RETURN