Hi,
is use this source code to detect the memory size:
xor eax, eax
mov ah, 0x88
int 0x15
add eax, 1024 ; 1024 KB == 1 MB
mov [mem_size_kbytes], eax
The problem is, when the memory is higher than 64 MB, the size is wrong. How can i dectect the memory correct in Real Mode ?
Problem with Memory detection
Re:Problem with Memory detection
Hi,
i know the problem, i can't detect more than 64
MB with using interrupt 15. How can i detect more than 64 MB in Real Mode ?
Please help me
Matze
i know the problem, i can't detect more than 64
MB with using interrupt 15. How can i detect more than 64 MB in Real Mode ?
Please help me
Matze
Re:Problem with Memory detection
Use 88h as a last ditch effort (At which point it's probably easier to do the direct probing thing). On newer processors get the BIOS to return a memory map (Then figure out how to read one ). Function 802 on int 15 should do the trick I think. Take a look a Ralf Brown's interrupt list for details.
This is actually far more useful than direct probing as it will give you any holes/reserved sections of memory as well without trampling on anything.
This is actually far more useful than direct probing as it will give you any holes/reserved sections of memory as well without trampling on anything.