blob: a8bf84b0f0692b247954c8cbad35a9e9b6d13d3e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
USES Dos,Crt;
VAR Lw: Char;
FUNCTION Checkdrive(Drive : Byte): Boolean;
VAR Regs: Registers;
Anz_Floppy,A_Or_B: Byte;
BEGIN
Anz_Floppy:=((Mem[$40:$10] And 192) Shr 6)+1;
A_Or_B:=Mem[$50:$04];
If ((Drive=1) And (Anz_Floppy=1) And (A_Or_B=00))
Or ((Drive=0) And (Anz_Floppy=1) And (A_Or_B=01)) Then
BEGIN
Checkdrive:=False;
Exit;
END;
Checkdrive:=Not(Disksize(Drive+1)=-1);
END;
BEGIN
REPEAT
BEGIN
Lw:=Readkey;
Lw:=Upcase(Lw);
If Not Checkdrive(Ord(Lw)-65) Then
Writeln('Laufwerk ',Lw,' nicht vorhanden')
Else Writeln('Laufwerk ',Lw,' vorhanden');
END;
UNTIL Lw=#13;
END.
|