Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I recently reintalled the OS on my computer, and had to install a number of drivers to get everything to work. It made me wonder, what is a driver, how does it work? And is there a difference between for example a printer driver, and a graphic card driver?

share|improve this question

closed as too broad by Marcks Thomas, mpy, Scott, Mokubai, Simon Sheehan Oct 20 '13 at 3:58

There are either too many possible answers, or good answers would be too long for this format. Please add details to narrow the answer set or to isolate an issue that can be answered in a few paragraphs. If this question can be reworded to fit the rules in the help center, please edit the question.

1  
This question seems a little broad. What a driver is exactly is not an easy subject to understand, but it also is well document, and there is learning material out there that explains the basic idea behind them. –  Ramhound Oct 17 '13 at 14:41

3 Answers 3

When I write software to print to a printer, I do not want to need to know the specific special commands you need to send to a Lexmark printer to make it print versus a HP printer. What I want to write to instead is a abstraction given to me by the operating system, that way I only need to write my printing code once and my users can use whatever printer they want as long as the OS can translate the generic interface in to the manufacturer specific interface.

Now how does the operating system know how to translate that abstraction in to the manufacturer specific commands for the device? The operating system publishes a API that the manufacturer can write their "translation code" that goes from the generic interface to their specific hardware.

That "translation code" is a driver.

The difference between a graphics driver and a printer driver is that a printer driver talks to the print API and the graphics talk to the graphics API.

share|improve this answer

One of the jobs of an OS is to provide "abstraction" - an environment where programmers do not have to detail with low-level details and can instead work on the task they want the computer to do. This reduces development time and costs.

I/O can be looked at in a very generalized way. You open a file, read or write to it, then close it when you are done. This I/O paradigm here (and it's not the only paradigm but certainly the most common and easiest to understand) can apply to a wide number of devices obviously.

But the low-level details of devices are often vastly different. Programming and operating a floppy drive controller is very different from a hard disk controller, which is very different from NAND flash.

Given, say, something like a programmer who is trying to develop an application like a spreadsheet - it would be very beneficial if he or she did not have to worry about all the meticulous and often times convoluted techniques and requirements involved in getting those devices to read blocks, spin their motors, etc.

We likely get a far better spreadsheet program if someone who understands the low-level I/O hardware details packages that in an API, and then the spreadsheet programmer can use that (hopefully well-documented) API and work on what he/she knows best. So we write a driver for each device that implements our I/O paradigm - the driver would be the small program that takes high level requests and has the knowledge necessary to get a device to obey them.

The additional benefit is that we (usually) don't have to change our applications when new types of devices come out. We just add more drivers and tell the application to save to a different place.

Now this is a simplified look but hopefully gives you a good idea.

share|improve this answer
    
Thanks, fully understanding how it works might be a bit above my IT level, but it deffinetly gave me a better idea of what it is, Thank you! –  Thomas Oct 18 '13 at 7:51

Drivers are the middleware that allow computer programs to use resources of a specific hardware device.

share|improve this answer
    
More detail would improve this answer –  Dave M Oct 17 '13 at 15:46
    
I wanted it to be a tldr answer. –  karel Oct 17 '13 at 15:58

Not the answer you're looking for? Browse other questions tagged or ask your own question.