How can load custom usb configuration/interface descriptor on LPC 1769 CMIS DAP?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How can load custom usb configuration/interface descriptor on LPC 1769 CMIS DAP?

Jump to solution
4,830 Views
tarak311
Contributor II

I have uploaded usbd_lib_cdc in my LPC Expresso 1769 CMIS-DAP board. It has 2 interface which has 3 endpoints (interface 1 has one interrupt endpoint while interrupt 2 has 2 bulk endpoint. But it still shows only one interface and 2 interrupt endpoint. Am I missing something?

I am using MCU Expresso and Linux host and I checking usb descriptor by using lsusb -v command(see screenshots below).

Labels (3)
1 Solution
4,271 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,
On the LPCXPresso 1769 board, the USB port connects the LPC11U35 not the LPC1769 and the LPC11U35 is used to as an onboard debugger, I've also attached the enumeration information after USB port connects a PC host and it seems as same as you showed in the original post. So I think you misunderstand it.
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

        ---------------- Connection Information ---------------
Connection Index         : 0x02
Connection Status        : 0x01 (DeviceConnected)
Current Config Value     : 0x01
Device Address           : 0x03
Is Hub                   : 0x00 (no)
Number Of Open Pipes     : 0x02 (2)
Device Bus Speed         : 0x01 (Full-Speed)
Pipe0ScheduleOffset      : 0x00 (0)
Pipe1ScheduleOffset      : 0x00 (0)

        ------------------ Device Descriptor ------------------
bLength                  : 0x12 (18 bytes)
bDescriptorType          : 0x01 (Device Descriptor)
bcdUSB                   : 0x110 (USB Version 1.10)
bDeviceClass             : 0x00 (defined by the interface descriptors)
bDeviceSubClass          : 0x00
bDeviceProtocol          : 0x00
bMaxPacketSize0          : 0x08 (8 bytes)
idVendor                 : 0x1FC9 (NXP Semiconductors)
idProduct                : 0x001D
bcdDevice                : 0x100
iManufacturer            : 0x01
 Language 0x0409         : "NXP"
iProduct                 : 0x02
 Language 0x0409         : "NXP CMSIS-DAP"
iSerialNumber            : 0x03
 *!*ERROR  string descriptor 3 not found
bNumConfigurations       : 0x01

        ------------------ String Descriptors -----------------
             ------ String Descriptor 0 ------
bLength                  : 0x04 (4 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language ID[0]           : 0x0409 (English - United States)
             ------ String Descriptor 1 ------
bLength                  : 0x08 (8 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP"
             ------ String Descriptor 2 ------
bLength                  : 0x1C (28 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP CMSIS-DAP"
             ------ String Descriptor 4 ------
bLength                  : 0x1C (28 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP CMSIS-DAP"

        -------------- Configuration Descriptor ---------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x02 (Configuration Descriptor)
wTotalLength             : 0x0029 (41 bytes)
bNumInterfaces           : 0x01
bConfigurationValue      : 0x01
iConfiguration           : 0x00
bmAttributes             : 0x80
 D7: Reserved, set 1     : 0x01
 D6: Self Powered        : 0x00 (no)
 D5: Remote Wakeup       : 0x00 (no)
 D4..0: Reserved, set 0  : 0x00
MaxPower                 : 0xFA (500 mA)

        ---------------- Interface Descriptor -----------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x04 (Interface Descriptor)
bInterfaceNumber         : 0x00
bAlternateSetting        : 0x00
bNumEndpoints            : 0x02 (2 Endpoints)
bInterfaceClass          : 0x03 (HID - Human Interface Device)
bInterfaceSubClass       : 0x00 (None)
bInterfaceProtocol       : 0x00 (None)
iInterface               : 0x04
 Language 0x0409         : "NXP CMSIS-DAP"

        ------------------- HID Descriptor --------------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x21 (HID Descriptor)
bcdHID                   : 0x0100 (HID Version 1.00)
bCountryCode             : 0x00 (00 = not localized)
bNumDescriptors          : 0x01
Descriptor 1:
bDescriptorType          : 0x22 (Class=Report)
wDescriptorLength        : 0x0021 (33 bytes)
Error reading descriptor : ERROR_GEN_FAILURE

        ----------------- Endpoint Descriptor -----------------
bLength                  : 0x07 (7 bytes)
bDescriptorType          : 0x05 (Endpoint Descriptor)
bEndpointAddress         : 0x81 (Direction=IN  EndpointID=1)
bmAttributes             : 0x03 (TransferType=Interrupt)
wMaxPacketSize           : 0x40 (64 bytes)
bInterval                : 0x01 (1 ms)

        ----------------- Endpoint Descriptor -----------------
bLength                  : 0x07 (7 bytes)
bDescriptorType          : 0x05 (Endpoint Descriptor)
bEndpointAddress         : 0x01 (Direction=OUT  EndpointID=1)
bmAttributes             : 0x03 (TransferType=Interrupt)
wMaxPacketSize           : 0x40 (64 bytes)
bInterval                : 0x01 (1 ms)
‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

View solution in original post

10 Replies
4,271 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
Actually, I'm not clear with your question, so I was wondering if you can describe it in details.
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

4,271 Views
tarak311
Contributor II

Thanks for the reply, 

I am trying to use usbd_lib_cdc on lpc 1769 cmis dap and use linux as a host. So when I run lsusb command I can see Nxp board listed as an hid device with two intrupt endpoint but it is supposed to show 1 intrupt and two bulk endpoint. U can see in 2 uploaded picture in question. 

0 Kudos
Reply
4,271 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,
Thanks for your reply.
Obviously, you should correct the set of descriptors for the device, and please refer to the usbd_lib_cdc_uart demo in the LPCOpen library of LPCXpresso LPC1769 board.

https://www.nxp.com/support/developer-resources/software-development-tools/lpc-developer-resources-/...
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

4,271 Views
tarak311
Contributor II

Thanks for quick response,

I tried loading usbd_lib_cdc_uart  from lpcopen library but I have same output from $lsusb -v which is two interrupt endpoints in just one interface (HID class). And do I need to put in high speed/ full mode if yes then how?

0 Kudos
Reply
4,271 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,
Thanks for your reply.
It seems so weird, I was wondering if you can introduce the testing produce, then I can replicate this phenomenon, it can help me to figure it out.
I'm looking forward to your reply.
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

4,271 Views
tarak311
Contributor II

Thanks for your reply,

And I think the reason it is not working because it is lpc1769 cmis dap and I was looking at the schematic dia from which I found out that D+ and D- from main microcontroller (LPC1769FB100) dosn't goes to cimis side so I  think I have to use P0.29 and P0.30 as D+ and D- or find a way to program cmis dap . Please correct me I am wrong. 

0 Kudos
Reply
4,271 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,

Thanks for your reply.

What's board do you use? LPCXpress LPC1769 board?
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply
4,271 Views
tarak311
Contributor II

 LPCXPRESSO1769 WITH CMSIS-DAP

0 Kudos
Reply
4,272 Views
jeremyzhou
NXP Employee
NXP Employee

Hi Tarak Patel,
On the LPCXPresso 1769 board, the USB port connects the LPC11U35 not the LPC1769 and the LPC11U35 is used to as an onboard debugger, I've also attached the enumeration information after USB port connects a PC host and it seems as same as you showed in the original post. So I think you misunderstand it.
Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

        ---------------- Connection Information ---------------
Connection Index         : 0x02
Connection Status        : 0x01 (DeviceConnected)
Current Config Value     : 0x01
Device Address           : 0x03
Is Hub                   : 0x00 (no)
Number Of Open Pipes     : 0x02 (2)
Device Bus Speed         : 0x01 (Full-Speed)
Pipe0ScheduleOffset      : 0x00 (0)
Pipe1ScheduleOffset      : 0x00 (0)

        ------------------ Device Descriptor ------------------
bLength                  : 0x12 (18 bytes)
bDescriptorType          : 0x01 (Device Descriptor)
bcdUSB                   : 0x110 (USB Version 1.10)
bDeviceClass             : 0x00 (defined by the interface descriptors)
bDeviceSubClass          : 0x00
bDeviceProtocol          : 0x00
bMaxPacketSize0          : 0x08 (8 bytes)
idVendor                 : 0x1FC9 (NXP Semiconductors)
idProduct                : 0x001D
bcdDevice                : 0x100
iManufacturer            : 0x01
 Language 0x0409         : "NXP"
iProduct                 : 0x02
 Language 0x0409         : "NXP CMSIS-DAP"
iSerialNumber            : 0x03
 *!*ERROR  string descriptor 3 not found
bNumConfigurations       : 0x01

        ------------------ String Descriptors -----------------
             ------ String Descriptor 0 ------
bLength                  : 0x04 (4 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language ID[0]           : 0x0409 (English - United States)
             ------ String Descriptor 1 ------
bLength                  : 0x08 (8 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP"
             ------ String Descriptor 2 ------
bLength                  : 0x1C (28 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP CMSIS-DAP"
             ------ String Descriptor 4 ------
bLength                  : 0x1C (28 bytes)
bDescriptorType          : 0x03 (String Descriptor)
Language 0x0409          : "NXP CMSIS-DAP"

        -------------- Configuration Descriptor ---------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x02 (Configuration Descriptor)
wTotalLength             : 0x0029 (41 bytes)
bNumInterfaces           : 0x01
bConfigurationValue      : 0x01
iConfiguration           : 0x00
bmAttributes             : 0x80
 D7: Reserved, set 1     : 0x01
 D6: Self Powered        : 0x00 (no)
 D5: Remote Wakeup       : 0x00 (no)
 D4..0: Reserved, set 0  : 0x00
MaxPower                 : 0xFA (500 mA)

        ---------------- Interface Descriptor -----------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x04 (Interface Descriptor)
bInterfaceNumber         : 0x00
bAlternateSetting        : 0x00
bNumEndpoints            : 0x02 (2 Endpoints)
bInterfaceClass          : 0x03 (HID - Human Interface Device)
bInterfaceSubClass       : 0x00 (None)
bInterfaceProtocol       : 0x00 (None)
iInterface               : 0x04
 Language 0x0409         : "NXP CMSIS-DAP"

        ------------------- HID Descriptor --------------------
bLength                  : 0x09 (9 bytes)
bDescriptorType          : 0x21 (HID Descriptor)
bcdHID                   : 0x0100 (HID Version 1.00)
bCountryCode             : 0x00 (00 = not localized)
bNumDescriptors          : 0x01
Descriptor 1:
bDescriptorType          : 0x22 (Class=Report)
wDescriptorLength        : 0x0021 (33 bytes)
Error reading descriptor : ERROR_GEN_FAILURE

        ----------------- Endpoint Descriptor -----------------
bLength                  : 0x07 (7 bytes)
bDescriptorType          : 0x05 (Endpoint Descriptor)
bEndpointAddress         : 0x81 (Direction=IN  EndpointID=1)
bmAttributes             : 0x03 (TransferType=Interrupt)
wMaxPacketSize           : 0x40 (64 bytes)
bInterval                : 0x01 (1 ms)

        ----------------- Endpoint Descriptor -----------------
bLength                  : 0x07 (7 bytes)
bDescriptorType          : 0x05 (Endpoint Descriptor)
bEndpointAddress         : 0x01 (Direction=OUT  EndpointID=1)
bmAttributes             : 0x03 (TransferType=Interrupt)
wMaxPacketSize           : 0x40 (64 bytes)
bInterval                : 0x01 (1 ms)
‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
4,271 Views
tarak311
Contributor II

I was using lsusb -v command to see the descriptors. I also have attached two screenshots (in question) of the descriptor.

0 Kudos
Reply