|
@@ -67,27 +67,27 @@ static const struct {
|
|
.bInterfaceNumber = 0,
|
|
.bInterfaceNumber = 0,
|
|
.bAlternateSetting = 0,
|
|
.bAlternateSetting = 0,
|
|
.bNumEndpoints = 1,
|
|
.bNumEndpoints = 1,
|
|
- .bInterfaceClass = 0x02,
|
|
|
|
- .bInterfaceSubClass = 0x02,
|
|
|
|
|
|
+ .bInterfaceClass = USB_CLS_CDC_CONTROL,
|
|
|
|
+ .bInterfaceSubClass = USB_CDC_SCLS_ACM,
|
|
.bInterfaceProtocol = 0x00,
|
|
.bInterfaceProtocol = 0x00,
|
|
.iInterface = 5,
|
|
.iInterface = 5,
|
|
},
|
|
},
|
|
.cdc_hdr = {
|
|
.cdc_hdr = {
|
|
.bLength = sizeof(struct usb_cdc_hdr_desc),
|
|
.bLength = sizeof(struct usb_cdc_hdr_desc),
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
- .bDescriptorsubtype = 0x00,
|
|
|
|
|
|
+ .bDescriptorsubtype = USB_CDC_DST_HEADER,
|
|
.bcdCDC = 0x0110,
|
|
.bcdCDC = 0x0110,
|
|
},
|
|
},
|
|
.cdc_acm = {
|
|
.cdc_acm = {
|
|
.bLength = sizeof(struct usb_cdc_acm_desc),
|
|
.bLength = sizeof(struct usb_cdc_acm_desc),
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
- .bDescriptorsubtype = 0x02,
|
|
|
|
|
|
+ .bDescriptorsubtype = USB_CDC_DST_ACM,
|
|
.bmCapabilities = 0x02,
|
|
.bmCapabilities = 0x02,
|
|
},
|
|
},
|
|
.cdc_union = {
|
|
.cdc_union = {
|
|
.bLength = sizeof(struct usb_cdc_union_desc) + 1,
|
|
.bLength = sizeof(struct usb_cdc_union_desc) + 1,
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
.bDescriptorType = USB_CS_DT_INTF,
|
|
- .bDescriptorsubtype = 0x06,
|
|
|
|
|
|
+ .bDescriptorsubtype = USB_CDC_DST_UNION,
|
|
.bMasterInterface = 0,
|
|
.bMasterInterface = 0,
|
|
},
|
|
},
|
|
.cdc_union_slave = 1,
|
|
.cdc_union_slave = 1,
|
|
@@ -105,7 +105,7 @@ static const struct {
|
|
.bInterfaceNumber = 1,
|
|
.bInterfaceNumber = 1,
|
|
.bAlternateSetting = 0,
|
|
.bAlternateSetting = 0,
|
|
.bNumEndpoints = 2,
|
|
.bNumEndpoints = 2,
|
|
- .bInterfaceClass = 0x0a,
|
|
|
|
|
|
+ .bInterfaceClass = USB_CLS_CDC_DATA,
|
|
.bInterfaceSubClass = 0x00,
|
|
.bInterfaceSubClass = 0x00,
|
|
.bInterfaceProtocol = 0x00,
|
|
.bInterfaceProtocol = 0x00,
|
|
.iInterface = 6,
|
|
.iInterface = 6,
|
|
@@ -134,7 +134,7 @@ static const struct {
|
|
.bInterfaceNumber = 2,
|
|
.bInterfaceNumber = 2,
|
|
.bAlternateSetting = 0,
|
|
.bAlternateSetting = 0,
|
|
.bNumEndpoints = 0,
|
|
.bNumEndpoints = 0,
|
|
- .bInterfaceClass = 0xfe,
|
|
|
|
|
|
+ .bInterfaceClass = USB_CLS_APP_SPECIFIC,
|
|
.bInterfaceSubClass = 0x01,
|
|
.bInterfaceSubClass = 0x01,
|
|
.bInterfaceProtocol = 0x01,
|
|
.bInterfaceProtocol = 0x01,
|
|
.iInterface = 7,
|
|
.iInterface = 7,
|
|
@@ -143,7 +143,7 @@ static const struct {
|
|
.bLength = sizeof(struct usb_dfu_func_desc),
|
|
.bLength = sizeof(struct usb_dfu_func_desc),
|
|
.bDescriptorType = USB_DFU_DT_FUNC,
|
|
.bDescriptorType = USB_DFU_DT_FUNC,
|
|
.bmAttributes = 0x0d,
|
|
.bmAttributes = 0x0d,
|
|
- .wDetachTimeOut = 1000,
|
|
|
|
|
|
+ .wDetachTimeOut = 0,
|
|
.wTransferSize = 4096,
|
|
.wTransferSize = 4096,
|
|
.bcdDFUVersion = 0x0101,
|
|
.bcdDFUVersion = 0x0101,
|
|
},
|
|
},
|