Querying Device Configuration Information
Once you have a driver loaded and initialized, it is sometimes useful to
inform the user what type of device was detected. Once you have a
pointer to the device driver initialization function group, you can use
the GetConfigInfo function to get
complete information about the manufacturer of the installed device,
the name of the device as well as information about when the device
driver was tested and certified. All the information is returned in the
GA_configInfo structure, and can be
obtained as follows:
ibool GetConfigInfo(GA_devCtx *dc)
{
GA_initFuncs initFuncs;
GA_configInfo info;
initFuncs.dwSize = sizeof(initFuncs);
if
(!GA_queryFunctions(dc,GA_GET_INITFUNCS,&initFuncs))
return false;
info.dwSize = sizeof(info);
init.GetConfigInfo(&info);
// do something useful with the information!
return true;
}
Note: Make sure you initialize the dwSize member of
the GA_configInfo structure to the
size of the structure being passed to GetConfigInfo!
Copyright © 2002 SciTech Software, Inc. Visit our web site at http://www.scitechsoft.com