home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Sauce 'n' Code 2
/
sauce-n-code-02.adf
/
ASCII_Source
/
Drive_Stats.asc
< prev
next >
Wrap
Text File
|
1995-07-02
|
1KB
|
49 lines
'*****************************************************************************
'*
'* Check Drive Status Routine
'* Written By Johnathan Parish & Steve Bennett
'*
'*****************************************************************************
If Length(4)=0
Reserve As Work 4,36 : Rem ****** bank for disk status check *****
End If
_CHECK_DRIVE["df0:"]
P=Param
If P=80 Then Print "Disk Is Write Protected"
If P=81 Then Print "Validating Disk"
If P=82 Then Print "Disk Is Ready To Save Onto"
Procedure _CHECK_DRIVE[DR$]
' 80=write protected
' 81=validating
' 82=disk ok to save onto
If Not Exist(DR$) Then STATUS=-1 : Goto FINALOUT
Dreg(1)=Varptr(DR$)
Dreg(2)=-2
LOCK=Doscall(-84)
Dreg(1)=LOCK
Dreg(2)=Start(4)
OK=Doscall(-114)
If Leek(Start(4)+24)=-1 Then STATUS=-1 : Goto OUT
STATUS=Leek(Start(4)+8)
OUT:
Dreg(1)=LOCK
DUMMY=Doscall(-90)
FINALOUT:
Wait Vbl
End Proc[STATUS]