device drivers

general methodology adopted for writing device drivers
babs02_99Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
orozcoConnect With a Mentor Commented:
Ok. It's difficult to describe a general procedure to make device drivers for all the operating systems, I think that you have to know the operating system because for example in ms-dos the dd (device drivers) works with I/O directly from the BIOS interrupts, and has the following principal parts:
1- Device header
2- Local Procedures/Data
3- Strategy
4- Interrupt procedures
5- Command processing procedures
 All Device drivers in ms-dos has to have all these commands.

Under Windows 3.0, the problem is a little more complicated, and in Windows 3.1 is a little diferent, and so on.
Windows 95 uses an architecture driver/mini-driver that is easy to the people make specific code for the device.
Unix uses a diferent architecture because the I/O is separated in two subsystems, I/O by character and I/O by block.
0
 
donnerjackCommented:
Do you need it for win95/98 or NT?
The best way to do it is to take a software that builds most of it and let you fill a function or two with your code. try WinDriver products
http://www.windriver.com/
or
http://www.jungo.com/
0
 
MDarlingCommented:
You earn the Vaguest Question Award!

Device drivers for what?
What operating system?
What target machine?
What compiler(s) do you have?
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
nietodCommented:
babs02_99.  You cannot keep asking this vague questions and then rejected answers.   The reason the answers are not what you want is that no one can tell exactly what you are asking about.  The problem is in your questions questions, not in the answers.
0
 
orozcoCommented:
If you want a device drivers for unix document contact me at benito_orozco@hotmail.com
0
 
babs02_99Author Commented:
am sorry for the fact that my qu turned out to b the vaguest!
but ,what i want to know is the general procedure to b adopted,irrespective of the operating system,so that depending on the situation, i'l b able to write a device driver.

0
 
nietodCommented:
Device drivers under other OSs are TOTALLY different.  Some OSs don't have device drivers (formally).  Mac device drivers are very different than windows ones.  There is almost nothing that can be said about them in general.
0
 
MDarlingCommented:
for(each operating system)
{
   find out as much as you can about the hardware.  

   find out as much as you can about the low level operating system.

   write the driver.

   write the highlevel api to interact with driver.
}

0
 
babs02_99Author Commented:
i wanted to know the knowledge which is required to write a device driver,similar to the answer proposed by
mdarling
0
 
nietodCommented:
That is more of a joke than an answer.  (I mean an intentional joke, not a "joke of an answer".)

Its like asking "How do you build a vehicle"?   Well even the most general instructions on how to build a car are going to be useless to you when you build a submarine, or an airplane, or a rocket.

That is the type of question you are asking.  

You might say that the only thing in common for device drivers between two OSes is the name "device driver".  But actually even that is not true.  

Look at the accepted answer.  It is so general that it is undoubtedly useless to you.  Yet it is still incorrect for every OS but one.

Its like answering the vehicle question by saying, well you need wheels--true for cars and trucks, airplanes, but not a submarine.   Alright, too precise.   You need an engine.  Subs have engines too.  Opps not for a rocket.   Alright, you need a power source.  Opps not for a hang glider....  If eventually you can answer the question, the answer is going to be so general it will be meaningless.
0
 
MDarlingCommented:
At least someone here gets irony :)
0
 
nietodCommented:
Irony?  Oh, we don't get any of that around here.  At least not since '87 when I was the last practicioner of it and I had to step because everyone was looking at me funny.  
                                 --Steve Martin from Roxane, (as best I can recall from memory.)
0
 
MDarlingCommented:
*L* i remember that - who nose someone else here might get it ;)
0
 
babs02_99Author Commented:
ok, i'l change my questions,if the earlier one seems funny to all of u!
i'l divide into 2 parts

1.) the os is DOS
2.) the os is WIN NT

how to write the drivers for these os's?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.