Chapter 12
Early in the device driver development process, it is important to devote some thought to how an end user will install your driver and install the hardware it serves. Microsoft Windows 2000 and Microsoft Windows 98 use a text file with the file extension INF to control most of the activities associated with installing drivers. You provide the INF file. It either goes on a diskette or on a disc that you package with the hardware, or else Microsoft puts it on the Windows 2000 installation disc. In the INF file, you tell the operating system which file(s) to copy onto the end user's hard disk, which registry entries to add or modify, and so on.
In this chapter, I'll discuss several aspects of installing your driver. I'll lead you through the important parts of a simple INF file to help you tie together the DDK documentation about INF file syntax. I'll explain in detail the format of device identifiers used for various types of devices—this information is hard to come by right now, as it happens. I'll discuss how to initialize property values in a device's hardware registry key and how to access those properties later from drivers and applications. Since I had to define a custom device class for all the sample "devices" used in this book, I thought it would help you to see how I did that. To round out this chapter (and, in fact, the entire book), I'll discuss a method you can use to cause an application to start automatically when the PnP Manager starts one of your devices.