Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between physical device driver and logical device driver?

I would like to know the difference between the physical device driver (PDD) and the logical device driver (LDD)?

Apart from this difference that the logical device driver (LDD) is written by the operating system vendor, while the physical device driver (PDD) is implemented by the device vendor.

Is there any difference? Do we need both of them to communicate with hardware? What are their individual importance?

Thanks in advance.

like image 459
JavaTechnical Avatar asked Feb 01 '14 18:02

JavaTechnical


Video Answer


1 Answers

A logical device driver is a high level abstraction of how a device behaves. A physical device driver is a driver for a specific piece of hardware. The logical device driver talks to the physical device driver for you to keep you abstracted from the underlying hardware.

For example, there are many different types of printers, and they typically come with their own drivers. However, you wouldn't want to have to code your application to deal with all these different drivers. Instead, you talk to the logical driver using the standard printer API, and the logical driver talks to the physical driver for you. It's the job of the physical device driver vendor to ensure that their driver integrates into the logical device driver model.

The logical/physical divide exists throughout more modern operating systems. For example, you don't have to worry about which graphics card you are using, instead you talk to the graphics API of your operating system, and it knows how to communicate with the graphics card, via it's driver. The graphics susbsystem is essentially your logical driver, in this scenario.

like image 78
Sean Avatar answered Oct 19 '22 08:10

Sean