Re: Question about _URB_SELECT_CONFIGURATION

Tech-Archive recommends: Fix windows errors by optimizing your registry



I'm using the same calling sequence (the interfacelist is NULL terminated).
I don't know why you are seeing different behavior.
Perhaps it is affected by the layout of the configuration descriptor.

-Stan

"huangjj" <huangjj@xxxxxxxxxxx> wrote in message
news:%23hqtTWRzHHA.1204@xxxxxxxxxxxxxxxxxxxxxxx
I have multiple alternate settings.
I use isousb sample code of XPDDK to test on Win2000 SP4.

I use USBD_ParseConfigurationDescriptorEx like the following
way to prepare the interface list for alternate setting 1.

I can get the pointer to the interface descriptor of alternate setting 1
and
set it in the associated interface list.

After Urb is passed down and completed, I also get all information of
alternate setting 1 successfully.

However, I didn't see set interface command is sent on USB bus.

// get pointer to interface descriptor with alternate setting 1
interfaceDescriptor =
USBD_ParseConfigurationDescriptorEx(
ConfigurationDescriptor,
ConfigurationDescriptor,
interfaceNumber, // interface number
1, //alt setting 1
-1, // hub class
-1, // subclass, don't care
-1); // protocol, don't care

if (interfaceDescriptor)
{
interfaceList->InterfaceDescriptor = interfaceDescriptor;
interfaceList++;
}

"Stan Mitchell" <stanlmitchell@xxxxxxxxxxxxxxxx>
If your device only has AlternateSetting 0 for that interface then the
SELECT_INTERFACE request will _not_ be sent.




.



Relevant Pages

  • Re: Question about _URB_SELECT_CONFIGURATION
    ... I use isousb sample code of XPDDK to test on Win2000 SP4. ... way to prepare the interface list for alternate setting 1. ... // get pointer to interface descriptor with alternate setting 1 ...
    (microsoft.public.development.device.drivers)
  • Re: Question about _URB_SELECT_CONFIGURATION
    ... generate a SELECT_INTERFACE request for the AlternateSetting specified in ... So you will get two requests for the one URB. ... needs to parse configuration descriptor to prepare one interface ... information of alternate setting 1. ...
    (microsoft.public.development.device.drivers)
  • Re: Question about _URB_SELECT_CONFIGURATION
    ... way to prepare the interface list for alternate setting 1. ... I didn't see set interface command is sent on USB bus. ... // get pointer to interface descriptor with alternate setting 1 ...
    (microsoft.public.development.device.drivers)
  • Re: [PATCH] Fix for USB ugen panics
    ... "The default alternate setting zero (with zero bandwidth) selected by a Set ... trying to say is that alternate interface 0 will be selected by default upon ...
    (freebsd-current)
  • Re: Question about _URB_SELECT_CONFIGURATION
    ... Select interface request is not sent to device. ... So you will get two requests for the one URB. ... information of alternate setting 1. ...
    (microsoft.public.development.device.drivers)