Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Access BIOS data in Windows 95

Posted on 1998-07-16
12
Medium Priority
?
199 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
ID: 1717797
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
ID: 1717798
Whoops sorry, nevermind that.  Minor GPF in the brain.
0
 
LVL 2

Expert Comment

by:richrussell
ID: 1717799
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
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:jliong
ID: 1717800
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
ID: 1717801
Very simple: write real-mode application (DOS-based) and access
memory directly from it.
0
 
LVL 1

Expert Comment

by:saneesh100
ID: 1717802
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
 

Author Comment

by:jliong
ID: 1717803
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 1500 total points
ID: 1717804
 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
ID: 1717805
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
ID: 1717806
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
ID: 1717807
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
ID: 1717808
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

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

This article provides a convenient collection of links to Microsoft provided Security Patches for operating systems that have reached their End of Life support cycle. Included operating systems covered by this article are Windows XP,  Windows Server…
In this modest contribution, I want to share with the IT community (especially system administrators, IT Support Engineers and IT Help Desks) about Windows crashes/hangs and how to deal with these particular problems.
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…
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…

963 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