Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- ClipOn 3.0 Reference - c_disktype() http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 C_DISKTYPE()

 DESCRIPTION

 The C_DISKTYPE() function returns media information about a specified
 disk drive.

 SYNTAX

 C_DISKTYPE(drive)

 PARAMETERS

 drive (N) is the drive number of the disk to check.  Any valid
 drive number for the computer may be specified.  If the drive
 number is not valid, C_DISKTYPE() will return zero (0).
 (0 = default drive, 1 = A, 2 = B, 3 = C, 4 = D, etc.)

 RETURNS

 C_DISKTYPE() returns media information as a numeric code.  The
 codes are as follows:

 CODE     DESCRIPTION
 ----     -----------
 0        Drive invalid or can not be identified
 1        Single Sided - 9 sector
 2        Double Sided - 9 sector (normal 360Kb - 5.25")
 3        Single Sided - 8 sector
 4        Double Sided - 8 sector
 5        High Density - 15 sector (normal 1.2Mb - 5.25")
 6        Fixed (all hard disks and RAM disks)
 7        Double Sided - 9 sector (normal 720Kb - 3.5")
 8        High Density - 18 sector (normal 1.4Mb - 3.5")

 EXAMPLES

 && Initialize variable to zero, variable will contain the bytes
 && that should be on the disk for a given type
 diskspace = 0
 clear

 ? "Insert Disk in Drive A:"

 if c_isdrive(1)             && Test for drive ready
   if c_disktype(1) = 5      && If disk type is 5
     diskspace = 1213952     && Then diskette is DS/HD (1.2Mb)
   else
     diskspace = 362496      && Otherwise assume 360Kb
   endif
 endif


See Also: C_ISDRIVE() C_FSPACE() C_DISKSTAT() C_DISKBYTE()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson