Bug report for USB examples

cancel
Showing results for 
Search instead for 
Did you mean: 

Bug report for USB examples

96 Views
Contributor I

Is there a better place for reporting bugs? I couldn't find any.

I've run into an issue with some of the RT1050 USB examples where they don't enumerate correctly when connected to a computer running windows 10.

I found it with the following examples, but may be in others:

   usb_device_composite_cdc_msc_sdcard_lite

   usb_device_composite_cdc_msc_lite

   usb_device_composite_cdc_msc

The problem is caused by an incorrect subclass in the IAD section of the configuration descriptor (g_UsbDeviceConfigurationDescriptor). In those examples, the subclass is set to 0x03 (Telephone Control Model) instead of 0x02 (Abstract Control Model). In fact, the interface descriptors in those examples are correctly set to Abstract Control Model.

Here's the code from usb_device_composite_cdc_msc_sdcard_lite/bm/usb_device_descriptor.c:

/* Define configuration descriptor */
USB_DMA_INIT_DATA_ALIGN(USB_DATA_ALIGN_SIZE)
uint8_t g_UsbDeviceConfigurationDescriptor[] = {

...

   /* Interface Association Descriptor */
   /* Size of this descriptor in bytes */
   USB_IAD_DESC_SIZE,
   /* INTERFACE_ASSOCIATION Descriptor Type */
   USB_DESCRIPTOR_TYPE_INTERFACE_ASSOCIATION,
   /* The first interface number associated with this function */
   0x00,
   /* The number of contiguous interfaces associated with this function */
   0x02,
    /* The function belongs to the Communication Device/Interface Class */
    USB_CDC_VCOM_CIC_CLASS, 0x03,
    /* The function uses the No class specific protocol required Protocol */
    0x00,
    /* The Function string descriptor index */
    0x02,

...

Changing that highlighted 0x03 to 0x02 allowed the example to correctly enumerate. To be consistent with the code, it should probably be "USB_CDC_VCOM_CIC_SUBCLASS", which evaluates to 0x02 in that example.

I found this in version 2.4.2, but it seems to still exist in 2.7.0 of the SDK.

0 Kudos
1 Reply

2 Views
NXP TechSupport
NXP TechSupport

Hi Jay:

Thank you for your feedback. I will reproduce your issue in my side and then report to the soft team.

You can report bugs here by creating a private ticket.

Support | NXP 

pastedImage_2.png

Regards

Daniel

0 Kudos