Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Zortech C++ 3.0r4 - <b>the dos package</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
The DOS package

   This is analogous to the Bios package except that it provides an
   interface to operating system calls. These functions are supported under

   both MS-DOS and OS/2 and most of these functions are available when using
   the DOS extenders.

   Some of the available dos_ functions are not supported or only partially
   supported in the X memory model, refer to the entry for each function for
   more information.

   The DOS package functions can be split conveniently into four groups.
   Those concerned with disk or file access, those concerned with the system
   time and date, those concerned with memory allocation and various
   miscellaneous functions.


Disk and File Functions

   There a variety of functions involved with disk and file operations which go
   directly through the MS-DOS software interrupts. The first of these are
   dos_abs_disk_read and dos_abs_disk_write. These functions provide a
   way of directly reading and writing logical disk sectors to and from the
   disk. One possible use for these routines would be in a diskcopy type
   utility. dos_getdrive and dos_setdrive provide a way for the
   programmer to ascertain the current drive number, and to change the
   current drive. dos_getdiskfreespace can be used to find out the amount
   of free space that is available on a disk. dos_getftime and dos_setftime
   allow the file date and time stamps to be read and modified. Finally
   dos_getfileattr and dos_setfileattr can be used to read or modify a
   file's attribute bits.

System Date/Time Functions

   There are four functions associated with the DOS system time and date.
   These are dos_gettime and dos_settime which allow the system time to

   be read and set, and dos_getdate and dos_setdate which do the same for
   the system date.

Memory Allocation Functions

   Four memory allocation functions are provided as part of the DOS package.
   dos_alloc and dos_calloc request memory from the heap in a similar
   way to malloc and calloc. These functions are direct calls to MS-DOS and
   do not go through the normal allocation management system. dos_free is
   provided to free memory allocated by dos_alloc and dos_calloc. The final
   function, dos_setblock, carries out a similar function to realloc,
   allowing the size of an allocated memory block to be changed.

Miscellaneous Functions

   The rest of the functions provide an interface to various miscellaneous
   facilities provided by DOS. dos_exterr obtains the extended error
   information provided by MS-DOS 2.11 and later. The functions
   dos_get_ctrl_break and dos_set_ctrl_break allow the DOS control
   break status to be tested or changed. dos_get_verify and dos_set

   verify do the same for the DOS verify status.





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