home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
c64.rulez.org
/
2014.05.c64.rulez.org.tar
/
c64.rulez.org
/
pub
/
c64
/
other-OS
/
Dos
/
1541v100.arj
/
I1541.INT
< prev
next >
Wrap
Text File
|
1996-01-06
|
7KB
|
174 lines
--------T-144000-----------------------------
int 14 - i1541 - installation check
ax = 4000H
rETURN: ax = 1541H
bh = i1541 MAJOR VERSION (bcd)
bl = i1541 MINOR VERSION (bcd)
cx = 0000H
--------T-144001-----------------------------
int 14 - i1541 - test if 1541 cable connected
ax = 4001H
rETURN: cf CLEAR IF CONNECTED
bl = lpt NUMBER WHERE 1541 CABLE IS CONNECTED (1..3)
cf SET IF CABLE NOT CONNECTED
nOTE: THIS PROCEDURE SCANS ALL THE lpt PORTS SEARCHING THE ADAPTER CABLE
--------T-144002-----------------------------
int 14 - i1541 - select lpt port for output
ax = 4002H
bl = lpt NUMBER (1..3)
rETURN: cf CLEAR IF SUCCESSFUL
cf SET OTHERWISE
nOTE: FORCE THE INPUT OUTPUT ROUTINES TO WORK ON THE CABLE PLACED ON lpt bl
sEEaLSO: ax=4001H
--------T-144003-----------------------------
int 14 - i1541 - reset all devices
ax = 4003H
nOTE: tHIS ROUTINE SENDS A RESET PULSE OF 100MS TO ALL cbm DEVICES.
iT'S NECESSARY TO WAIT {$7e}2S AFTER RESET BEFORE EXECUTING OTHER
INSTRUCTIONS.
--------T-144004-----------------------------
int 14 - i1541 - send listen signal
ax = 4004H
bh = DEVICE NUMBER (0..15)
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=4005H/4006H
--------T-144005-----------------------------
int 14 - i1541 - send secondary address for listen
ax = 4005H
bl = CHANNEL NUMBER 0..15 (BITS 0-3)
MODE (BITS 4-7)
6H : READ AND WRITE
eH : CLOSE CHANNEL
fH : OPEN CHANNEL
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=4004H/4006H
--------T-144006-----------------------------
int 14 - i1541 - send unlisten signal
ax = 4006H
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=4004H/4005H
--------T-144007-----------------------------
int 14 - i1541 - send talk signal
ax = 4007H
bh = DEVICE NUMBER (0..15)
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=4008H/4009H
--------T-144008-----------------------------
int 14 - i1541 - send secondary address for talk
ax = 4008H
bl = CHANNEL NUMBER 0..15 (BITS 0-3)
MODE (BITS 4-7)
6H : READ AND WRITE
eH : CLOSE CHANNEL
fH : OPEN CHANNEL
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
40H : TURN AROUND TIME-OUT
sEEaLSO: ax=4007H/4009H
--------T-144009-----------------------------
int 14 - i1541 - send untalk signal
ax = 4009H
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=4007H/4008H
--------T-14400a-----------------------------
int 14 - i1541 - send a byte to a device
ax = 400aH
bl = BYTE TO SEND
cl = IS THE LAST BYTE
00H : IF THE BYTE TO SEND IS NOT THE LAST
01H : IF THE BYTE TO SEND IS THE LAST
rETURN: cf CLEAR IF SUCCESSFUL
cf SET IF ERROR
al = ERROR NUMBER
00H : DEVICE NOT PRESENT ERROR
01H : LISTENER NOT READY ERROR
02H : MISSING EOI TIME-OUT
03H : EOI NOT COMPLETED
04H : DATA NOT RELEASED
05H : FRAME ERROR
sEEaLSO: ax=400bH
--------T-14400b-----------------------------
int 14 - i1541 - receive a byte from a device
ax = 400bH
rETURN: cf CLEAR IF SUCCESSFUL
al = BYTE RECEIVED
cl = IS THE LAST BYTE
00H : IF THE RECEIVED BYTE IS NOT THE LAST
01H : IF THE RECEIVED BYTE IS THE LAST
cf SET IF ERROR
al = ERROR NUMBER
80H : EOI RESPONSE REQUIRED ERROR
81H : TALKER NOT READY
82H : CLOCK NOT SET
83H : CLOCK NOT RELEASED
cl = 00H
sEEaLSO: ax=400aH
--------T-14400c-----------------------------
int 14 - i1541 - wait
ax = 400cH
cx = NUMBER OF 838NS TICKS (1/1.193180mhZ) TO WAIT
(0 MEANS 65536 ({$7e}55MS))
eXAMPLE: tO WAIT 10US YOU MUST SET cx=(10US/838NS)=12
--------T-14400d-----------------------------
int 14 - i1541 - longwait
ax = 400dH
dx:cx = NUMBER OF 838NS TICKS (1/1.193180mhZ) TO WAIT
(0 MEANS 4294967296 ({$7e}1hOUR))
eXAMPLE: tO WAIT 1S YOU MUST SET dx:cx=(1S/838NS)=1193180
--------T-14400e-----------------------------
int 14 - i1541 - get info
ax = 400eH
rETURN: ax = lpt PORT I/O ADDRESS IN USE (0 IF NO CABLE IN USE)
bl = lpt NUMBER (1..3) IN USE (0 IF NO CABLE IN USE)
cf SET IF THE CABLE IS AUTO DETECTABLE
cf CLEAR IF CABLE NOT AUTO DETECTABLE OR NOT PRESENT
nOTE: tHE cf SET MEANS THAT THE AUTO DETECT ROUTINE CAN RECOGNISE THE
PRESENCE OF A CABLE ON THE lpt PORT IN USE.