Windows侧常见USB接口描述符综述


市面上有很多通信类模块,有高通、展锐、MTK各大平台,这些平台的产品根据USB协议组织的划分,隶属于CDC类设备,而CDC类设备有划分为多个子类,本文重点给出两种子类,一是网络接口类,二是串行接口类,其中网络接口主要包括MBIM接口、NCM接口、RNDIS接口和RMNET接口,而串行接口主要包括ACM接口和普通的串行接口,本文会从如下两个方面,分别介绍这些接口:

  1. 接口自身的描述符信息
  2. 针对接口的驱动加载策略,也就是加载什么驱动。

1. 术语

名词全称说明
MBIMMobile Broadband Interface Model基于MBIM消息的通信模式
RNDISRemote NDIS基于USB实现RNDIS实际上就是TCP/IP over USB,就是在USB设备上跑TCP/IP
ACMAbstract Control Model虚拟的串口通信模式
NCMNetwork Control Model基于以太网的通信模式
RMNETRemote Manager NET一种高通独有的网络通信模式
CDCCommunication Device Class通信类设备

2. CDC类设备综述

2.1. 概述

我们知道主机侧在枚举USB设备的过程中,会通过GET_DESCRIPTOR命令来获取USB设备的设备描述符USB_DEVICE_DESCRIPTOR、配置描述符 USB_CONFIGURATION_DESCRIPTOR、接口描述符USB_INTERFACE_DESCRIPTOR(详情查看附录5.1小节)和端点描述符USB_ENDPOINT_DESCRIPTOR等,并根据接口描述符中的bInterfaceClass、bInterfaceSubClass和bInterfaceProtocol用来区分interface类型,其中一般情况,复合设备的一个USB_INTERFACE_DESCRIPTOR就代表了一个function功能,而CDC类复合设备的有些function功能,需要模块侧上报两个USB_INTERFACE_DESCRIPTOR描述符信息,一个是Communications Interface,一个是Data Interface,比如MBIM接口、NCM接口以及ACM接口。

关于USB总线的一些基础知识,请查看《Universal Serial Bus 3.2 Specification》和《Universal Serial Bus Class Definitions for Communications Devices》。

2.2. CDC类Communications Interface描述符

Communications Interface有一个重要功能就是用来区分不同的CDC子类设备,其中bInterfaceClass用于指示USB设备为CDC类设备。

bInterfaceSubClass用于区分CDC类设备这个大类下不同的子类,比如MBIM、RNDIS、NCM和ECM。bInterfaceProtocol用于区分各个子类使用的协议。而USB协议组织给CDC类设备分配的码值信息,如下所示。
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
一般的interface主要包含interface描述符以及3个EP描述符信息,而CDC设备类的Communications interface描述符除了几个标准描述符外,还新增了class-specific描述符信息,由于这些class-specific描述符仅仅存在于interface层面,所以又称Functional Descriptors,比如Header Functional Descriptor、Union Functional Descriptor以及各个CDC设备子类独有的Class Functional Descriptors,如下所示,关于Functional Descriptors的通用格式,请查看附录5.8小节。
在这里插入图片描述

对于CDC类设备Communications interface描述符而言,有两点需要注意

  1. Header Functional Descriptor描述符的位置要排在所有的Functional Descriptor前面。
  2. 对于CDC类Communications Interface接口而言,其所需的EP个数一般为不超过1个,而且是中断类型的EP。

2.2.1. Header Functional Descriptor

Header Functional Descriptor代表一个interface的function descriptors集开始,在所有的function descriptors中,其必须处于第一个位置。
在这里插入图片描述

2.2.2. Union Functional Descriptor

Union Functional Descriptor描述了一组接口group中,各个接口的relationship,简单的说也就是表明那个是master接口,那个是slave接口,也就是下图中的bControlInterface指示的接口为master接口,而bSubordinateInterfaceN指示的接口为slave接口,通过下图也可以知道,master接口有且只有一个,而slave接口可以有1到多个。
在这里插入图片描述

2.2.3. MBIM接口Class Functional Descriptors

MBIM接口的Function Descriptor主要包括两种:一种为MBIM Functional Descriptor,另一种为MBIM Extended Functional Descriptor,下面分别给出这两种Functional Descriptor的具体格式信息。

2.2.3.1. MBIM Functional Descriptor

MBIM Functional Descriptor是必须的,其function descriptors code=0x1B,而且必须在Header Functional Descriptor的后面,具体格式如下所示。
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

2.2.3.2. MBIM Extended Functional Descriptor

MBIM Extended Functional Descriptor也是必现的,其function descriptors code=0x1C,而且必须紧跟着MBIM Functional Descriptor的后面,具体格式如下所示。
在这里插入图片描述
在这里插入图片描述

2.2.4. NCM接口Class Functional Descriptors

NCM接口是在ECM基础之上进行了优化改进,兼容ECM,所以这里只要给出NCM接口完整的Function Descriptors即可,主要为NCM接口新增的NCM Functional Descriptor和ECM原有的CDC Ethernet Networking Functional Descriptor,分别如下所示。

2.2.4.1. NCM Functional Descriptor

NCM Functional Descriptor格式如下所示,其function descriptors code=0x1A,
在这里插入图片描述

2.2.4.2. CDC Ethernet Networking Functional Descriptor

CDC Ethernet Networking Functional Descriptor格式如下所示,其function descriptors code=0x0F,
在这里插入图片描述

2.2.5. ACM接口Class Functional Descriptors

ACM接口就是一个虚拟的串行接口,俗称COM端口,这样在主机侧就能以com端口的方式使用该接口,比如可以直接使用现存的常用串口工具SSCOM以及PUTTY,无需开发新的工具,方便快捷,其主要为Abstract Control Management Functional Descriptor和Call Management Functional Descriptor。分别如下所示。

2.2.5.1. Abstract Control Management Functional Descriptor

该Functional Descriptor是必须的,详细格式如下所示,其function descriptors code=0x02,
在这里插入图片描述

2.2.5.2. Call Management Functional Descriptor

该Functional Descriptor是必须的,详细格式如下所示,其function descriptors code=0x01,
在这里插入图片描述

2.2.6. RNDIS接口Class Functional Descriptors

关于RNDIS接口,在本文只需要知道其是一个基于USB接口进行TCP/IP协议通信的接口即可,关于更详细的信息,比如在windows侧的架构图以及RNDIS相关的OID码值等,请查看如下微软官方网址:
https://docs.microsoft.com/en-us/windows-hardware/drivers/network/remote-ndis–rndis-2
另外,RNDIS接口没有特定的Functional Descriptor,其只是复用ACM接口的Functional Descriptor,关于这点,3.3小节会给出更详细的描述符说明,本小节不在陈述。

2.2.7. RMNET接口Class Functional Descriptors

RMNET接口是高通独有的通信接口,其就是一个普通的接口,没有特定的Functional Descriptor,3.4小节会给出更详细的描述符说明,本小节不在陈述。

2.3. CDC类Data Interface描述符

Data Interface的一个重要功能就是用来指示各个CDC子类接口的数据通道,也就是Bluk EP信息,而USB协议组织给CDC类设备分配的码值信息,如下所示。
在这里插入图片描述
在这里插入图片描述

3. 网络类描述符

3.1. MBIM接口

3.1.1. 概述

MBIM接口需要两个interface,一个是communications interface,另一个是data interface,其中communications interface中的bInterfaceClass=0x02,bInterfaceSubClass=0x0E和bInterfaceProtocol=0x00,而data interface中的bInterfaceClass=0x0A,bInterfaceSubClass=0x00和bInterfaceProtocol=0x02,MBIM接口详细描述符如下所示。附录5.2小节会给出一个完整的接口描述符。
在这里插入图片描述
注意
上图中带option字样的,是可选项。

3.1.2. 主机侧驱动

主机侧识别到MBIM接口后,会自动加载微软的内置驱动cxwmbclass.sys或wmbclass.sys,下面以19H2系统为例,给出如下截图信息,我们以Fibo L831模块为例。
在这里插入图片描述
有一点需要讲解一下,cxwmbclass.sys和wmbclass.sys都是微软OS针对MBIM接口的内置驱动,只是两者是在不同的操作系统上提供,其中wmbclass.sys自win8系统就开始提供,而cxwmbclass.sys是win10系统才开始提供。

3.2. NCM接口

3.2.1. 概述

NCM接口需要两个interface,一个是communications interface,另一个是data interface,其中communications interface中的bInterfaceClass=0x02,bInterfaceSubClass=0x0D和bInterfaceProtocol=0x00,而data interface中的bInterfaceClass=0x0A,bInterfaceSubClass=0x00和bInterfaceProtocol=0x01,NCM接口详细描述符如下所示。附录5.3小节会给出一个完整的接口描述符。
在这里插入图片描述

3.2.2. 主机侧驱动

主机侧识别到NCM接口后,会自动加载微软的内置驱动usbncm.sys,注意该驱动自win11系统才开始提供,下面给出L860 R+ USB接口模式下,NCM接口的截图,如下所示。
在这里插入图片描述

3.3. RNDIS接口

3.3.1. 概述

由于RNDIS接口直接复用ACM接口的function描述符,除了ACM接口自身所需的两个interface外,还需要一个Association Interface,用于表明告知主机侧这是一个RNDIS接口,所以需要三个interface,其中Association Interface的bInterfaceClass=0xE0,bInterfaceSubClass=0x01和bInterfaceProtocol=0x03,另外两个就是ACM接口中所需的communications interface,另一个是data interface,关于ACM接口详细的信息,查看4.1小节,这里不再陈述。RNDIS接口详细描述符如下所示。附录5.4小节会给出一个完整的接口描述符。
在这里插入图片描述

3.3.2. 主机侧驱动

主机侧识别到RNDIS接口后,会自动加载微软的内置驱动rndismp6.sys和usb80236.sys,下面以19H2系统为例,给出如下截图信息。
在这里插入图片描述

3.4. RMNET接口

3.4.1. 概述

RMNET接口是高通独有的网络通信接口,其本质上就是一个普通接口,所以只需要一个自定义的interface即可,该interface的bInterfaceClass=0xFF,bInterfaceSubClass=0xFF和bInterfaceProtocol=0x30,RMNET接口详细描述符如下所示。附录5.5小节会给出一个完整的接口描述符。
在这里插入图片描述

3.4.2. 主机侧驱动

由于RMNET接口是一个普通的自定义接口,所以windows系统中没有专门的inbox驱动,需要针对该接口,需要IHV厂商自己开发一个驱动,就像下图中的fbusbwwan.sys驱动一样,下面以高通SDX12平台Fibo厂商FM101为例。
在这里插入图片描述

4. 串口类描述符

公司常用的USB串口,主要两类,一种是ACM串口,另一种就是普通串口,本文就这两者串口进行讲解。

4.1. ACM接口

4.1.1. 概述

ACM接口需要两个interface,一个是communications interface,另一个是data interface,其中communications interface中的bInterfaceClass=0x02,bInterfaceSubClass=0x02和bInterfaceProtocol=0x01,而data interface中的bInterfaceClass=0x0A,bInterfaceSubClass=0x00和bInterfaceProtocol=0x00,ACM接口详细描述符如下所示。附录5.6小节会给出一个完整的接口描述符。
在这里插入图片描述

4.1.2. 主机侧驱动

主机侧识别到ACM接口后,会自动加载微软的内置驱动usbser.sys,如下图所示
在这里插入图片描述

4.2. 普通串行接口

4.2.1. 概述

普通串行接口本质上就是一个普通接口,所以只需要一个自定义的interface即可,该interface的bInterfaceClass=0xFF,bInterfaceSubClass=0xFF和bInterfaceProtocol=0xXX,该接口详细描述符如下所示。附录5.7小节会给出Fibo 厂商FM101项目中一个普通串口的完整接口描述符。
在这里插入图片描述

4.2.2. 主机侧驱动

由于普通串行接口是一个普通的自定义接口,所以windows系统中没有专门的inbox驱动,需要针对该接口,需要IHV厂商自己开发一个驱动,就像下图中的fbusbser.sys驱动一样。
在这里插入图片描述

5. 附录

5.1. 接口描述符

//
// USB 1.1: 9.6.3 Interface, Table 9-9. Standard Interface Descriptor
// USB 2.0: 9.6.5 Interface, Table 9-12. Standard Interface Descriptor
// USB 3.0: 9.6.5 Interface, Table 9-17. Standard Interface Descriptor
//
typedef struct _USB_INTERFACE_DESCRIPTOR {
    UCHAR   bLength;
    UCHAR   bDescriptorType;
    UCHAR   bInterfaceNumber;
    UCHAR   bAlternateSetting;
    UCHAR   bNumEndpoints;
    UCHAR   bInterfaceClass;
    UCHAR   bInterfaceSubClass;
    UCHAR   bInterfaceProtocol;
    UCHAR   iInterface;
} USB_INTERFACE_DESCRIPTOR, *PUSB_INTERFACE_DESCRIPTOR;

5.2. MBIM接口描述符

Interface Association Descriptor CDC Control

OffsetFieldSizeValueDescription
0bLength108h
1bDescriptorType10BhInterface Association
2bFirstInterface100h
3bInterfaceCount102h
4bFunctionClass102hCDC Control
5bFunctionSubClass10Eh
6bFunctionProtocol100h
7iFunction100h

Interface Descriptor 0/0 CDC Control, 1 Endpoint

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber100h
3bAlternateSetting100h
4bNumEndpoints101h
5bInterfaceClass102hCDC Control
6bInterfaceSubClass10Eh
7bInterfaceProtocol100h
8iInterface105h

Header Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype100hHeader
3bcdCDC20110h1.10

Union Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype106hUnion
3bControlInterface100h
4bSubordinateInterface0101hCDC Data

Unknown Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength10Ch
1bDescriptorType124hCS Interface
2bDescriptorSubtype11Bh\ Unknown
3900 01 00 10 20 80 00 08 20

Unknown Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength108h
1bDescriptorType124hCS Interface
2bDescriptorSubtype11ChUnknown
3500 01 40 DC 05

Endpoint Descriptor 81 1 In, Interrupt, 32 ms

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress181h1 In
3bmAttributes103hInterrupt
1…0: Transfer Type…11Interrupt
7…2: Reserved000000…
4wMaxPacketSize20040h 64 bytes
6bInterval109h32 ms

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
7…0: Reserved00000000
4wBytesPerInterval20040h

Interface Descriptor 1/0 CDC Data, 0 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber101h
3bAlternateSetting100h
4bNumEndpoints100h
5bInterfaceClass10AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol102h
8iInterface100h

Interface Descriptor 1/1 CDC Data, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber101h
3bAlternateSetting101h
4bNumEndpoints102h
5bInterfaceClass10AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol102h
8iInterface106h

Endpoint Descriptor 8E 14 In, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress18Eh14 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst106hUp to 7 packets at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

Endpoint Descriptor 0F 15 Out, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress10Fh15 Out
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst102hUp to 3 packets at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

5.3. NCM接口描述符

Interface Association Descriptor CDC Control

OffsetFieldSizeValueDescription
0bLength108h
1bDescriptorType10BhInterface Association
2bFirstInterface100h
3bInterfaceCount102h
4bFunctionClass102hCDC Control
5bFunctionSubClass10Dh
6bFunctionProtocol100h
7iFunction104h

Interface Descriptor 0/0 CDC Control, 1 Endpoint

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber100h
3bAlternateSetting100h
4bNumEndpoints101h
5bInterfaceClass102hCDC Control
6bInterfaceSubClass10Dh
7bInterfaceProtocol100h
8iInterface105h

Header Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype100hHeader
3bcdCDC20120h1.20

Union Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype106hUnion
3bControlInterface100h
4bSubordinateInterface0101hCDC Data

Unknown Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength106h
1bDescriptorType124hCS Interface
2bDescriptorSubtype11AhUnknown(NCM Functional Descriptor subtype)
3300 01 00

Ethernet Networking Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength10Dh
1bDescriptorType124hCS Interface
2bDescriptorSubtype10FhEthernet Networking
3iMACAddress106h
4bmEthernetStatistics400000000hGet Ethernet Statistic request not supported
8wMaxSegmentSize20800h2048 bytes
10wNumberMCFilters20000h
15: Hashing0… …Perfect multicast address filtering (no hashing)
14…0: MC Filters.0000000 00000000Set Ethernet Multicast Filters request not supported
12bNumberPowerFilters100h

Endpoint Descriptor 81 1 In, Interrupt

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress181h1 In
3bmAttributes103hInterrupt
1…0: Transfer Type…11Interrupt
7…2: Reserved000000…
4wMaxPacketSize20040h64 bytes
6bInterval104h

Interface Descriptor 1/0 CDC Data, 0 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber101h
3bAlternateSetting100h
4bNumEndpoints100h
5bInterfaceClass1 0AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol101h
8iInterface108h

Interface Descriptor 1/1 CDC Data, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber101h
3bAlternateSetting101h
4bNumEndpoints102h
5bInterfaceClass10AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol101h
8iInterface109h

Endpoint Descriptor 82 2 In, Bulk, 512 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress182h2 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20200h512 bytes
6bInterval100h

Endpoint Descriptor 02 2 Out, Bulk, 512 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress102h2 Out
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20200h512 bytes
6bInterval100h

5.4. RNDIS接口描述符

Interface Association Descriptor RF Controller

OffsetFieldSizeValueDescription
0bLength108h
1bDescriptorType10BhInterface Association
2bFirstInterface100h
3bInterfaceCount102h
4bFunctionClass1E0hWireless Controller
5bFunctionSubClass101hRF Controller
6bFunctionProtocol103hRemote NDIS
7iFunction105h“REMOTE NDIS Device”

Interface Descriptor 0/0 CDC Control, 1 Endpoint

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber100h
3bAlternateSetting100h
4bNumEndpoints101h
5bInterfaceClass102hCDC Control
6bInterfaceSubClass102hAbstract Control Model
7bInterfaceProtocol1FFhVendor-Specific
8iInterface103h“RNDIS Communication Interface”

Header Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype100hHeader
3bcdCDC20110h1.10

Call Management Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype101hCall Management
3bmCapabilities100h
7…2: Reserved000000…
1: Data Ifc Usage…0.Call management only over Comm Ifc
0: Call Management…0Does not handle call management itself
4bDataInterface101h

Abstract Control Management Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength104h
1bDescriptorType124hCS Interface
2bDescriptorSubtype102hAbstract Control Management
3bmCapabilities100hRequests/notifications not supported
7…4: Reserved0000…
3: Connection…0…
2: Send Break…0…
1: Line Coding…0.
0: Comm Features…0

Union Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype106hUnion
3bControlInterface100h“RNDIS Communication Interface”
4bSubordinateInterface0101h“RNDIS Data Interface”

Endpoint Descriptor 82 2 In, Interrupt, 125 us

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress182h2 In
3bmAttributes103hInterrupt
1…0: Transfer Type…11Interrupt
7…2: Reserved000000…
4wMaxPacketSize20040h64 bytes
6bInterval101h125 us

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
7…0: Reserved00000000
4wBytesPerInterval20040h

Interface Descriptor 1/0 CDC Data, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber101h
3bAlternateSetting100h
4bNumEndpoints102h
5bInterfaceClass10AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol100h
8iInterface104h“RNDIS Data Interface”

Endpoint Descriptor 81 1 In, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress181h1 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst102hUp to 3 packets at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

Endpoint Descriptor 01 1 Out, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress101h1 Out
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst102hUp to 3 packets at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

5.5. RMNET接口描述符

Interface Descriptor 0/0 Vendor-Specific, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber100h
3bAlternateSetting100h
4bNumEndpoints102h
5bInterfaceClass1FFhVendor-Specific
6bInterfaceSubClass1FFh
7bInterfaceProtocol130h
8iInterface100h

Endpoint Descriptor 81 1 In, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress181h1 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

Endpoint Descriptor 01 1 Out, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress101h1 Out
3bmAttributes102hBulk
1…0: Transfer Type…10 Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

5.6. ACM接口描述符

Interface Association Descriptor Abstract Control Model

OffsetFieldSizeValueDescription
0bLength108h
1bDescriptorType10BhInterface Association
2bFirstInterface102h
3bInterfaceCount102h
4bFunctionClass102hCDC Control
5bFunctionSubClass102hAbstract Control Model
6bFunctionProtocol101hAT Commands: V.250 etc
7iFunction10Bh

Interface Descriptor 2/0 CDC Control, 1 Endpoint

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber102h
3bAlternateSetting100h
4bNumEndpoints101h
5bInterfaceClass102hCDC Control
6bInterfaceSubClass102hAbstract Control Model
7bInterfaceProtocol101hAT Commands: V.250 etc
8iInterface10Ch

Header Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype100hHeader
3bcdCDC20120h1.20

Union Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype106hUnion
3bControlInterface102h
4bSubordinateInterface0103hCDC Data

Call Management Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength105h
1bDescriptorType124hCS Interface
2bDescriptorSubtype101hCall Management
3bmCapabilities100h
7…2: Reserved000000…
1: Data Ifc Usage…0.Call management only over Comm Ifc
0: Call Management…0Does not handle call management itself
4bDataInterface103h

Abstract Control Management Functional Descriptor

OffsetFieldSizeValueDescription
0bFunctionLength104h
1bDescriptorType124hCS Interface
2bDescriptorSubtype102hAbstract Control Management
3bmCapabilities107h
7…4: Reserved0000…
3: Connection…0…
2: Send Break…1…Send Break request supported
1: Line Coding…1.Line Coding requests and Serial State notification supported
0: Comm Features…1Set/Clear/Get Comm Feature requests supported

Endpoint Descriptor 83 3 In, Interrupt

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress183h3 In
3bmAttributes103hInterrupt
1…0: Transfer Type…11Interrupt
7…2: Reserved000000…
4wMaxPacketSize20040h64 bytes
6bInterval104h

Interface Descriptor 3/0 CDC Data, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber103h
3bAlternateSetting100h
4bNumEndpoints102h
5bInterfaceClass10AhCDC Data
6bInterfaceSubClass100h
7bInterfaceProtocol100h
8iInterface10Dh

Endpoint Descriptor 84 4 In, Bulk, 512 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress184h4 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20200h512 bytes
6bInterval100h

Endpoint Descriptor 04 4 Out, Bulk, 512 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress104h4 Out
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20200h512 bytes
6bInterval100h

5.7. 普通串行接口描述符

Interface Descriptor 4/0 Vendor-Specific, 2 Endpoints

OffsetFieldSizeValueDescription
0bLength109h
1bDescriptorType104hInterface
2bInterfaceNumber104h
3bAlternateSetting100h
4bNumEndpoints102h
5bInterfaceClass1FFhVendor-Specific
6bInterfaceSubClass1FFh
7bInterfaceProtocol130h
8iInterface100h

Endpoint Descriptor 03 3 Out, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress103h3 Out
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

Endpoint Descriptor 86 6 In, Bulk, 1024 bytes

OffsetFieldSizeValueDescription
0bLength107h
1bDescriptorType105hEndpoint
2bEndpointAddress186h6 In
3bmAttributes102hBulk
1…0: Transfer Type…10Bulk
7…2: Reserved000000…
4wMaxPacketSize20400h1024 bytes
6bInterval100h

SuperSpeed Endpoint Companion

OffsetFieldSizeValueDescription
0bLength106h
1bDescriptorType130hSuperSpeed Endpoint Companion
2bMaxBurst100hOne packet at a time
3bmAttributes100h
4…0: MaxStreams…00000
7…5: Reserved000…
4wBytesPerInterval20000h

5.8. Function descriptors通用格式

在这里插入图片描述

  • 30
    点赞
  • 27
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

四儿家的小祖宗

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值