2.4.2  Parallel and Serial Devices and Driver Layers

Figure 2.9 illustrates a representative hardware configuration for parallel and serial devices.

Figure 2.9    Parallel and Serial Hardware Configurations

Both the parallel and serial devices are connected directly on the system bus.

Figure 2.10 shows the corresponding layered drivers for I/O operations on the devices shown in Figure 2.9.

Figure 2.10    Parallel and Serial Driver Layers

As mentioned in Section 2.1, a parallel driver traditionally writes data, which usually has been set up by a Windows NT subsystem-specific printer driver and spooled by the subsystem, out through a parallel port to a printer. The system’s parallel driver (parclass in Figure 2.10) handles printer output through a parallel port by calling down to the system parallel port driver. Other parallel class drivers can handle input from and output to other types of devices through a parallel port. The system parallel port driver provides all necessary port arbitration support.

The system’s serial driver shown in Figure 2.10 is both a lowest-level and highest-level NT driver.

When an end-user application opens a parallel or serial port, the user-mode subsystem calls an NT I/O system service to open the file object representing the appropriate port. If the call succeeds, that port becomes an exclusive device: dedicated for use by the application until it closes the port and the subsystem releases the file object handle.