home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 12
/
CD_ASCQ_12_0294.iso
/
vrac
/
pclcjs.zip
/
DEVICE.C
< prev
next >
Wrap
C/C++ Source or Header
|
1993-05-12
|
635b
|
50 lines
#include <dos.h>
#include "cjslib.h"
int get_dtype(int drive)
{
union REGS inregs, outregs;
DEVPARAMS dev_data;
dev_data.spec_func=0;
inregs.x.bx=drive;
inregs.h.ch=0x08;
inregs.h.cl=0x60;
inregs.x.dx=&dev_data;
inregs.x.ax=0x440D;
intdos(&inregs,&outregs);
return(dev_data.dev_type);
}
long get_vsn(int drive)
{
union REGS inregs, outregs;
MID disk_data;
disk_data.infolevel=0;
inregs.x.bx=drive;
inregs.h.ch=0x08;
inregs.h.cl=0x66;
inregs.x.dx=&disk_data;
inregs.x.ax=0x440D;
intdos(&inregs,&outregs);
return(disk_data.serialnum);
}