Thread View: comp.os.msdos.programmer
1 messages
1 total messages
Started by Esmail Bonakdarian
Fri, 08 Jan 1993 22:31
How to get real memory size
Author: Esmail Bonakdarian
Date: Fri, 08 Jan 1993 22:31
Date: Fri, 08 Jan 1993 22:31
31 lines
1551 bytes
1551 bytes
I am trying to write my own sysinfo utility, and I am having difficulty
determining the physical amount of memory present. I can use biosequip()
to get the amount of base memory (and number of serial and parallel ports,
whether the mathco is present or not), but I am not able to determine the
amount of extended memory when I have QEMM installed.
Is there a way to determine the total amount of physical memory (i.e., 4MB, 8MB
etc) installed on the system regardless of the memory manager and whether the
memory is configured to be used as expanded or extended?
Also, while I'm asking, where is the BIOS manufacturer signature located?
I am able to get the BIOS date, but not id the maker (e.g. AMI, Phoenix, etc).
Esmail
PS: I'm using TC++ v1.01 with MS-DOS 5.0
----------------------------------------
#include <stdio.h>
#include <dos.h>
void main(void)
{ int ext_mem_size = 0;
union REGS regs;
regs.h.ah = 0x88;
int86(0x15, ®s, ®s);
ext_mem_size = regs.x.ax;
printf(" Extended memory : %d K-bytes\n", ext_mem_size);
}
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads