ioctl12.hlp (Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
DSK_GETDEVICEPARAMS (1.2)
                                                      Up Next Previous
────────────────────────────────────────────────────────────────────────────
 
#define INCL_DOSDEVIOCTL
 
USHORT DosDevIOCtl(pbBPB, pbCommand, 0x0063, 0x0008, hDevice)
PBYTE pbBPB;        /* pointer to structure for BIOS parameter blocks */
PBYTE pbCommand;    /* pointer to variable with command               */
HFILE hDevice;      /* device handle                                  */
 
The DSK_GETDEVICEPARAMS function retrieves the device parameters for an MS
OS/2 block device. The device driver maintains two BIOS parameter blocks
(BPB) for each disk drive. One block corresponds to the medium currently in
the disk drive. The other is a recommended BPB, based on the type of medium
that corresponds to the physical device. For example, a high-density disk
drive has a BPB for a 96 tracks-per-inch (tpi) floppy disk; a low-density
disk drive has a BPB for a 48-tpi floppy disk.
 
Parameter  Description
────────────────────────────────────────────────────────────────────────────
 
pbBPB      Points to the BIOSPARAMETERBLOCK structure that receives the
           BPB.
 
pbCommand  Points to the variable that specifies which BPB to retrieve. If
           the variable is 0x0000, the function retrieves the recommended
           BPB for the drive (the BPB for the physical device). If the
           variable is 0x0001, the function retrieves the BPB for the medium
           currently in the drive.
 
hDevice    Identifies the disk drive that receives the device-control
           function. The handle must have been created previously by using
           the DosOpen function.
 
Return Value
 
The return value is zero if the function is successful or an error value if
an error occurs.
 
See Also
 
DosOpen, DSK_SETDEVICEPARAMS, BIOSPARAMETERBLOCK
 
                                      ♦