CDMProv

[This is preliminary documentation and subject to change.]

SUMMARY

This is a sample WMI user mode provider that allows device drivers to expose diagnostic tests by means of the CIM Common Diagnostic Model (CDM). The driver writer will implement its diagnostics within the kernel mode device driver with WMI instrumentation and then write Managed Object Format for the CDM classes that refer to the WDM instrumentation. This sample, the CDM Provider, will expose the CDM classes on behalf of the device driver.

BUILDING THE SAMPLE

Follow these steps to build and run the CDM Provider with the sample code.

1.      Change the name of the provider from CdmProv to your own unique name and guid in cdmprov.mof.

2.      On your development machine run build –cz in the directory to create CDMProv.DLL

3.      On your target machine run mofcomp cdmprov.mof to include the CDM Provider specific information in the schema

4.      On your target machine run regsvr32 cdmprov.dll to cause the provider to self register.

RESOURCES

Please see the DDK DiagFilt sample and the cdmwdm.doc reference information.  Also see MSDN for more information on WMI user mode providers.

CODE TOUR

File Manifest

File           Description
cdmprov.htm    This file
cdmprov.mof    CDM Provider specific MOF
cdmprov.rc     Resource Script file for CDM Provider
cdmwdm.htm     Reference information for using CDM Provider
cimmap.cpp     WDM to CIM mapping routines
cimmap.h       WDM to CIM mapping routines
classfac.cpp   Provider class factory routines
classprov.cpp  Provider implementation routines
classprov.def  Module definition file for provider
debug.cpp      Debugging routines
debug.h        Debugging routines
maindll.cpp    Main dll housing for provider
makefile       Build makefile
reload.cpp     PnP device start restart routines
reload.h       PnP device start restart routines
sample.h       Provider implementation routines
sources        Build sources
testinfo.cpp   WDM interface routines
testinfo.h     WDM interface routines
wbemmisc.cpp   Misc routines to interact with WMI
wbemmisc.h     Misc routines to interact with WMI

 

Top of page

 

 

 
 

© 2000 Microsoft Corporation