Selecting 2nd configuration for Composite USB Device

Dear Friends,

How can I select a 2nd configuration for composite device?

As we all know that in windows, usbccgpsys is loaded for composite device but it takes only first configuration. Once usbccgp.sys is loaded then higher level driver can not change the configuration.

As per my understanding solution of this problem can be:
Solution 1 : create our own driver with similar functionality of usbccgp.sys where we can select our desired configuration.
Problem: As we know, usbccgp.sys is core component of windows USB architecture and implementing it all functionality would be difficult.

Solution 2 : create filter driver below usbccgp.sys which select our desired configuration and forward our selected configuration as 1st configuration to usbccgp.sys.
Problem: I am sure whether this approach will work or not? if this will work then how can I achieve it?

Please help me friends in finding the solution of this problem.
should I follow any of the above mention solution or is there any other solution of this problem.

There are also some restrictions:

  1. Can’t do any changes in the USB device side. I have to find the solution from the PC side only.
  2. OS is Window XP

looking forward to hear from you.

Cheers :slight_smile:
Vikas Nirwan

xxxxx@gmail.com wrote:

How can I select a 2nd configuration for composite device?

Are you a different person from Amit Rajkumar Shahi, who has been asking
this exact same question this week? If not, you should check the
archives for the last week. We have discussed this exact issue.

As we all know that in windows, usbccgpsys is loaded for composite device but it takes only first configuration. Once usbccgp.sys is loaded then higher level driver can not change the configuration.

Right. That means you have to “fool” usbccgp.sys.

Solution 2 : create filter driver below usbccgp.sys which select our desired configuration and forward our selected configuration as 1st configuration to usbccgp.sys.

Yes, exactly.

Problem: I am sure whether this approach will work or not? if this will work then how can I achieve it?

Well, that’s your job, right? You just need to ask yourself “how does
usbccgp.sys find out information about the device”, and “how can I
convince him that the device actually looks like something else?” It’s
not very hard.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

Vikas Nirwan wrote:

Problem: As we know, usbccgp.sys is core component of windows
USB architecture and implementing it all functionality would be
difficult.

Not really. My generic parent is roughly ~900 lines of code (in KMDF) and only took about a week to write. (With judicious help from Doron, of course!)

In fact, if you and your other countrymen/alter egos insist on shipping bizarre USB devices which you are “not authorized” to change, you’re probably better off writing your own driver set than trying to fool MS’s.