Solved

Breaking through HAL

Posted on 1998-04-08
5
256 Views
Last Modified: 2010-04-10
I need to store various structures at specific addresses on and Windows NT machine.  Unfortunately Windows NT had a Hardware Abstraction Layer (HAL) which seems to prevent me from doing this.  Is there a way to break through HAL or at least get around it so that I can do this?  I need help fast
0
Comment
Question by:jerm
  • 3
5 Comments
 
LVL 22

Expert Comment

by:nietod
ID: 1184119
What do you mean by "store various sturcutres at specific addresses"?  Windows 95 and NT use virtual memory.  You cannot have dirrect access to physical memory. But you should not need dirrect access to physical memory.  Why do you want to do this?
0
 

Author Comment

by:jerm
ID: 1184120
Actually I am reusing old code which uses direct IO (access to physical memory) to share data between two computers running real time applications.  I understand that Win95 and NT do not like this, but was hoping to be able to use the old code without many changes.

Is this possible
0
 
LVL 22

Accepted Solution

by:
nietod earned 50 total points
ID: 1184121
No.  

But with some work you can make it work.  Try using a memory mapped file instead.
0
 
LVL 22

Expert Comment

by:nietod
ID: 1184122
Use the CreateFileMapping() API.  You will probably want to use a "named" mapping so the two programs can use the same mapping.  (The other option is to pass a handle from one program to the other, but this usually requires that the one program starts the other running.  I don't know if that's the case you have.)  

I hope this help gets you started.  Ask if you have any questions.
0
 
LVL 4

Expert Comment

by:piano_boxer
ID: 1184123
One simple answer:
You need to write a device driver.
Its not that hard, try looking at the samples from the Win32 device driver kit.

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Errors will happen. It is a fact of life for the programmer. How and when errors are detected have a great impact on quality and cost of a product. It is better to detect errors at compile time, when possible and practical. Errors that make their wa…
Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now