Solved

Access BIOS data in Windows 95

Posted on 1998-07-16
12
173 Views
Last Modified: 2013-12-29
Do you know how to access the BIOS data, it will be real mode address 0xF000 to 0xFFFF, under Windows 95 using Visual Basic or Visual C++ or any Windows API
0
Comment
Question by:jliong
  • 5
  • 2
  • 2
  • +3
12 Comments
 
LVL 2

Expert Comment

by:ryans
Comment Utility
I don't remember the EXACT systax, but shouldn't it be possible with using DEBUG from the prompt?
0
 
LVL 2

Expert Comment

by:ryans
Comment Utility
Whoops sorry, nevermind that.  Minor GPF in the brain.
0
 
LVL 2

Expert Comment

by:richrussell
Comment Utility
You can get the CMOS data block using ports 0x070 and 0x071. The following will read in the 64K data block from which you can get memory size, number of drives, ports, current date and time, etc..

for(n=0;n<64;n++){
 outp(0x070,n);
 printf("%H ",inp(0x071));
}

Basically you put the byte you want to get in port 70, and the BIOS returns it's value in port 71.

I used this method to write a Year 2000 compliancy testing program as it allows access to the hardware real time clock, so you can set it and compare it to the DOS one.

Check out the list of BIOS byte values for what each one is. You can download this from several places - eg as part of Ralph Brown's Interrupt list at:
http://www.cs.cmu.edu/afs/cs.cmu.edu/usr/ralf/pub/WWW/files.html
0
 

Author Comment

by:jliong
Comment Utility
Accessing I/O port 70 and reading I/O port 71 is just reading the content of RTC (Real Time Clock), but not the BIOS.  The point of this question will be how to access the read mode memory address in the protected mode.

0
 
LVL 7

Expert Comment

by:busuka
Comment Utility
Very simple: write real-mode application (DOS-based) and access
memory directly from it.
0
 
LVL 1

Expert Comment

by:saneesh100
Comment Utility
Hai..
 U are accessing the real mode address fomr a protected mode OS right ?? so u have to convert the address to linear first i mean the segment:Offset into a linear address .Then u can use segment selector functions to access it properly ..

 I can give u more data if u can send me u'r emailID

 
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 

Author Comment

by:jliong
Comment Utility
Saneesh100:

My email is jliong@kcc.com (temporary), can you also cc to aau@fs1.gemlight.com.hk.

Thanks a lot.
0
 
LVL 1

Accepted Solution

by:
HenryChanE earned 500 total points
Comment Utility
 If you really want to write a 32bit apps, using real mode is not possible, as Win32 had controlled the whole system. Instead, a VXD driver is necessary. To write VXD's, DDK(Device Driver Kit) is needed from MSDN.

  If you simply want to get a status from a specific port address, function inp() can be use under VC++.
0
 

Author Comment

by:jliong
Comment Utility
Henry,

It seems that your propsed solution (VXD) is very reasonable. However, since I give 500 points for this question I need more assistance from you. I will do my part to get the DDK and mug around it, but can you give me some example source code which is similar to my requirement, i.e. access the real mode address 0xF000 to 0xFFFF from a VXD.

Thanks a lot.
0
 

Author Comment

by:jliong
Comment Utility
Hi Henry,

Would you mind updating me whether you are still working on my problem or not? I wish to reopen to other experts if you are not interested of this question anymore by 28th Aug., 1998.

Kindest regards,

Jacky
0
 
LVL 1

Expert Comment

by:HenryChanE
Comment Utility
Jacky,
  I've tried to write my own VXD, but I found lot's of questions about the DDK. I feel that write a VXD is quite complicated, so I've give it up !!!

  Sorry about that I cann't help on your question. I think you may reopen this question in VC++ topic, there will be more experts deal with these stuff.

  If you find the answer, pls. let me know at henrychan@poboxes.com

Regards,

Henry
0
 

Author Comment

by:jliong
Comment Utility
Henry,

Thanks for your effort. I definitely will give you all the details once I can get a proper solution. I take your point I should  reopen the question in some other groups. What I will do is to give you 50 points (if the system allows) and then reopen it at, e.g. VC++ group. I will score you good instead of excellent because there is a large part of work unanswered.

Thanks and regards,

Jacky
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Our Group Policy work started with Small Business Server in 2000. Microsoft gave us an excellent OU and GPO model in subsequent SBS editions that utilized WMI filters, OU linking, and VBS scripts. These are some of experiences plus our spending a lo…
When you start your Windows 10 PC and got an "Operating system not found" error or just saw  "Auto repair for startup". After a while, you have entered a loop for Auto repair which does not fix anything and you will be in a  panic as all your work w…
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

772 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

11 Experts available now in Live!

Get 1:1 Help Now