Computing.Net > Forums > Programming > How to access physical memory?

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

How to access physical memory?

Reply to Message Icon

Name: Vincent SAINT MARTIN
Date: February 1, 2002 at 08:09:36 Pacific
Comment:

Hi all,
I wonder how I can access physical memory under Windows NT. I want to access to the BIOS informations; I have the start address (0xF0000000) and the end address (0xF000FFFF); my program works when compiled in 16 bits, but does not when compiled in 32 bits. Is there an API in Windows NT that allows to find the virtual address corresponding to the physical address?

Thank you for your time.




Sponsored Link
Ads by Google

Response Number 1
Name: Wizzard
Date: February 4, 2002 at 05:01:59 Pacific
Reply:

There are function calls in C to access BIOS information. I may be wrong but different BIOS's will hold different data in different memory locations, so your app probably wont work with all PC's.

It is far easier to use the function calls then at least it has all been done for you.

I have just compiled and run an app ro check the bios info under winXP and it worked fine.

All of the functions are in BIOS.H
There are a few functions available, like biosequip() which returns an INT which can be used to see what hardware your machine has (EG number of parallel ports installed, if a game port is available or the number of disk drivs installed.

Obviosly it was written some time ago for DOS but some things can still be used.

What exactly do you want to find in the BIOS?

Doing it this way is also safer that accessing the memory addresss directly.

Wizzard


0

Response Number 2
Name: Vincent SAINT MARTIN
Date: February 4, 2002 at 08:22:51 Pacific
Reply:

Hi,

Thanks to Wizzard and to Ron (for his e-mail answer).

I finally managed to do what I wanted to by going to the http://www.sysinternals.com homepage. I found the 'physmem' source code that demonstrates how to map physical addresses into the process user memory. The source code is very clear and it refers to undocumented Windows APIs.

Ron, it demonstrates how to extract functions from DLLs too.

Wizzard, where can I find bios.h?

Vincent.


0

Response Number 3
Name: Wizzard
Date: February 4, 2002 at 12:00:46 Pacific
Reply:

It comes with some C compilers.
I have Borland Turbo C++ 3, BIOS.h is included with that.

I don't know where you will get TC (Turbo C++), but presumably there are other free compilers on the net which will have it.

What are you developing in?

Maybe BIOS.h could simply be included in another compiler, say Visual C++, I dont know, I havnt tried it. I actually compiled the code using TC running under WinXP.

If you like I will email you bios.h

Wizzard


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: How to access physical memory?

How to read MSR or PhysMem in Win9x www.computing.net/answers/programming/how-to-read-msr-or-physmem-in-win9x/15126.html

how to access device manager(winxp) www.computing.net/answers/programming/how-to-access-device-managerwinxp/15667.html

how to access folder tree www.computing.net/answers/programming/how-to-access-folder-tree-/15734.html