USB ReEnumeration

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

cross mob
Anonymous
Not applicable

Hello,

   

For one of our projects, we are building a custom solution (hardware and software) based on a FPGA and a FX3 USB 3.0 controller.

   

When powering up our custom board, the FX3 enumerate itself with these parameters: VID=0x04B4, PID = 0x0053. After uploading a firmware in the RAM (via Control Center for example), the device re-enumerate itself with the new tuple (VID, PID) on both Windows and Linux.

   

Right now, we have developed a custom python script with libusb to upload firmware in the FX3 RAM. The transfer works flawlessly. For example, if  we write a firmware with a blinking led, the default bootloader and after program jump entry USB command, the led blink. So far so good, but if we look at the USB enumeration process, we can see, via dmesg, that the device is not re-enumerated and disconnected. 

   

According to Cypress datasheet, this behaviour is totally normal, however this is not the one we want. Is this possible to force the USB to re-enumerate itself and be seen by the linux machine after  program jump entry command ?

   

Best regards,

   

Christophe FAUVEL

   

 

   

PS: The observations described below have been made on a CYUSB3KIT-003 board also.

0 Likes
2 Replies
Anonymous
Not applicable

Hi,

   

In your new custom firmware, After you call the CyU3PConnectState (CyTrue, CyTrue); , force a USB Disconnection by calling CyU3PConnectState (CyFalse, CyFalse); and then again call CyU3PConnectState (CyTrue, CyTrue); 

   

Hope this helps.

   

Regards,

   

-Madhu Sudhan

0 Likes
Anonymous
Not applicable

Hello,

   

Finally, I was able to make it works ! Part of the problem was the python script which upload only some bytes in some sections (overflow of an uint16 vs uint32). Some events where also not handled in the firmware. Now it works without any issue.

   

Thank you for your help,

   

Best regards,

   

Christophe FAUVEL

0 Likes