This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
The USB driver works great until I have to send large packets of data to the USB device I am developing. It will get a random number of large packets successfully, and then halfway through one of the large packets, the interrupts will stop firing, and I cannot recover. I need to get to the bottom of why this is happening and I am having a heck of a time.
I will attach a picture showing that data reception randomly stops. On the top, you can see the full packet that our PC tool sent, the bottom left is our custom buffer for the data and on the right is the buffer supplied to the USB device when we set up the USB CDC object. You can see that where it is highlighted is where it breaks down. The disconnect seems to happen between the wire, and the USB device Rx buffer (g_pi8USBRxBuffer); data acquisition appears to stall because interrupts stopped.
It used to hang all the time when we sent data over the USB. After your update it rarely hangs, but it still seems to do it from time to time. I am interested to see if you guys do any further updates to the library.
Hello, I'm interested too for an update of the usb library.
I'm working with a Delfino TMS320F28337D and I've found the same problem with the USB communication.
I'm working with the example USB_dev_serial CDC. When I send more than 64 bytes through the USB,
seems interrupts to be disabled and USB communications does not recover.
Dani.
Regards.
Thank you for your quick answer,
I've implemented this solution but I will test it tomorrow because I don't have the device now.
I have a question about this implementation.
You create a variable ui32EPStaus to pass its address to the functions, MAP_USBIntStatus() and USBDeviceIntHandlerInternal().
what address contains this variable?
Regards.
Dani
HI Sal,
I am working on Hid Hsb communication for Piccolo F28069. I am using driver’s v141 where I have triggered the same bug. After workaround from you post, usb communication works better (longer without error) but still I can trigger an error but now only on Tx transition. Before workaround, usb communication “hanging” on Rx transmit (most of the cases) -> eEP0State = USB_STATE_RX and eHIDRxState = HID_STATE_WAIT_DATA.
Now stop on the Tx transmit -> eEP0State = USB_STATE_STATUS and eHIDTxState = HID_STATE_WAIT_DATA, moreover sometimes communication stops, where even g_ulUSBSOFCount do not count, and another time SOFCount count the incoming frames but communication doesn’t work (USBTXIS is always 0).
Have you found also that bug? In addition, when is plan the next release of the drivers without this bugs?
Thanks
Darek
Hi Darek,
Have you used the updated USBIntStatus that was implemented with a while loop in a previous post?
That implementation should have corrected the issue with reading and cleaing all usbis, usbrxis, and usbtxis registers so that the USBINT would reset in order that it could again be triggered and trigger the PIE.
We are in the process of aligning the F2806x library and drivers with F2837xD. We will have a controlSUITE release on June 17, 2015 that will update the USBLIB and usb examples in controlSUITE for F2806x so that it is consistent with the library and examples for the F2837xD.
Hope this helps, and please continue to let us know of any bugs you may find and ask us any questions you may have?
sal
Hi Darek,
Good to hear it is working.
I would not suggest using one variable to store all the information. USBRXIS and USBTXIS are 16 bit registers and hold the interrupt status for multiple endpoints. In your implementation you can easily loose data from USBTXIS that may be necessary. If you do not have any callback function when a transmit interrupt is fired, then it could work. But this would not work as a general solution for usb.c and the usblib.
Best Regards,
sal