How to Load the Generic Plug and Play VxD Sample in Windows 95

Last reviewed: August 5, 1996
Article ID: Q140731
The information in this article applies to:
  • Microsoft Win32 Device Development Kit (DDK) for Windows 95

SUMMARY

The Windows 95 DDK contains a generic Plug and Play VxD sample for developers who want to support a device that does not fit into any of Windows 95's predefined device classes (COMM, SCSI, MOUSE, and so on). The sample does not, however, document how to load this generic Plug and Play VxD driver. This article explains how to load it.

MORE INFORMATION

Windows 95 supports the dynamic arrival and removal of devices (PCMCIA cards, and so on). Therefore it also supports the dynamic loading and unloading of drivers for these devices. Initial Installation of these drivers is accomplished by using a Device Information File (.inf), as documented in Pnp.doc in the Windows 95 DDK. One of the registry entries defined in an .inf file is the DevLoader for the device.

A DevLoader is a VxD that is responsible for loading a driver that fits into a specific Windows 95 device class. For example, VCOMM acts as the DevLoader for VCOMM port drivers, IOS is the DevLoader for IOS port drivers and SCSI miniports, and VMOUSE is the DevLoader for mouse mini-drivers. In most cases, however, developers have no reason to develop a DevLoader just to load their generic Plug and Play VxD. In this case, a developer can specify that Configuration Manager act as the DevLoader for the device. This can be accomplished by adding the following two entries to the AddReg section of the device's .inf file (where Mydevice.vxd is the name of the VxD to be loaded):

    HKR,,DevLoader,,*CONFIGMG
    HKR,,DeviceDriver,,MYDEVICE.VXD

Once Configuration Manager loads the VxD, it will send a PNP_NEW_DEVNODE message to the VxD's control procedure with EBX containing the handle to the device's devnode. The VxD can then register with Configuration Manager using CONFIGMG_Register_Device_Driver to receive CONFIG_xxx notifications.

REFERENCES

For more information, please refer to Pnp.doc and the Plug and Play samples in the Windows 95 DDK.


Additional reference words: 4.00 PnP
KBCategory: kbtool kbhowto kbwebcontent
KBSubcategory:


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: August 5, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.