home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Simtel MSDOS 1992 June
/
SIMTEL_0692.cdr
/
msdos
/
desqview
/
dvglue10.arc
/
DVMEM.C
< prev
next >
Wrap
C/C++ Source or Header
|
1988-07-10
|
2KB
|
66 lines
/*=======================================================*/
/* DVMEM.C */
/* functions to find out how much memory is avail */
/* */
/* (c) Copyright 1988 Ralf Brown All Rights Reserved */
/* May be freely copied for noncommercial use, so long */
/* as this copyright notice remains intact, and any */
/* changes are marked in the comment blocks preceding */
/* functions. */
/*=======================================================*/
#include "tvapi.h"
/*======================================================*/
/* DVcommon_mem--get amount of common memory in bytes */
/* Ralf Brown 4/3/88 */
/*======================================================*/
void pascal DVcommon_mem(WORD *avail, WORD *largest, WORD *total)
{
WORD av ;
_AX = 0xDE04 ;
geninterrupt(0x15) ;
av = _BX ; /* _BX will be destroyed in dereferencing pointers */
*largest = _CX ;
*total = _DX ;
*avail = av ;
}
/*======================================================*/
/* DVconv_mem--get amount of conventional memory in K */
/* Ralf Brown 4/3/88 */
/*======================================================*/
void pascal DVconv_mem(WORD *avail, WORD *largest, WORD *total)
{
WORD av ;
_AX = 0xDE05 ;
geninterrupt(0x15) ;
av = _BX ; /* _BX will be destroyed in dereferencing pointers */
*largest = _CX ;
*total = _DX ;
*avail = av ;
}
/*======================================================*/
/* DVexp_mem--get amount of expanded memory in K */
/* Ralf Brown 4/3/88 */
/*======================================================*/
void pascal DVexp_mem(WORD *avail, WORD *largest, WORD *total)
{
WORD av ;
_AX = 0xDE06 ;
geninterrupt(0x15) ;
av = _BX ; /* _BX will be destroyed in dereferencing pointers */
*largest = _CX ;
*total = _DX ;
*avail = av ;
}
/* End of DVMEM.C */