Add endpoints results in invalid configuration descriptor

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
WGT_4383351
Level 5
Level 5
First like received

This is how cyfxbulklpdscr.c in AN87216 slave example is changed:

CyFxUSBSSConfigDscr:

     /* Configuration descriptor */

          /* Length of this descriptor and all sub descriptors */: from 0x2C,0x00, to 0x46,0x00,

     /* Interface descriptor */

          /* Number of end points */: from 0x02, to 0x04,

     And another two endpoints are added to the end of CyFxUSBSSConfigDscr.

    The max packet size of these endpoints are set to 256 bytes:    

          0x00,0x01,                      /* Max packet size = 256 bytes */

     The two existing endpoints's address are 0x01 and 0x81.

     The two new endpoints's address are 0x02 and 0x83

When load the firmware into RAM with Control Center, in the Windows Device Manager, the problem of the device is invalid configuration descriptor.

0 Likes
1 Solution

Hello,

You are not supposed to change the MaxPktSize for a Bulk endpoint from 1024 to 256 bytes. The MaxPktSize for a Bulk Endpoint should be set to 1024 itself. Please refer to Page 340 of the USB 3.0 Specification to understand this better. The link to the same is given below:

https://www.usb3.com/whitepapers/USB%203%200%20(11132008)-final.pdf

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna

View solution in original post

4 Replies
WGT_4383351
Level 5
Level 5
First like received

The configuration descriptors for high and full speed is not modified.

0 Likes
JayakrishnaT_76
Moderator
Moderator
Moderator
First question asked 1000 replies posted 750 replies posted

Hello,

Please let me know if you are using the firmware that was shared in the following thread:

Complex GPIF configuration

If yes, this was enumerating properly at my end without any error.

If no, then please share your project so that I can have a look into it.

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna
0 Likes

The reason may be related to MaxPktSize.

If I modify your cyfxbulklpdscr.c in slave project, change the endpoint CY_FX_EP_PRODUCER1's

/* Max packet size = 1024 bytes */ from 0x00,0x04, to 0x00,0x01, the same problem will appear.

Although just modify MaxPktSize in descriptor is not enough, but this should be enough to test the enumeration process, and in my project both descriptor and other part of the firmware are modified.

0 Likes

Hello,

You are not supposed to change the MaxPktSize for a Bulk endpoint from 1024 to 256 bytes. The MaxPktSize for a Bulk Endpoint should be set to 1024 itself. Please refer to Page 340 of the USB 3.0 Specification to understand this better. The link to the same is given below:

https://www.usb3.com/whitepapers/USB%203%200%20(11132008)-final.pdf

Best Regards,

Jayakrishna

Best Regards,
Jayakrishna