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.

usb_host_msc USBHCDControlTransfer error

Hi,

I am trying to implement the usb_msc_host example (Starterware_1_20_03_03) on one of our custom boards. I can see that the Mass storage device is detected and connected, but return zero bytes in the setup phase of the control transaction (USBHCDControlTransfer). The SETUPPKT and TXPKTRDY bits are set and the data put on the endpoint0 FIFO is as expected but after sending the data, the HOST_CSR0 reads an ERROR(bit 4). According to the USB 2.0 user's guide, this means that the 'controller has tried to send the SETUP packet and the following data packet three times without getting any response which implies problem at the peripheral end of the connection'. I am using the same Mass storage device and the same USB mini adapter on the C6748LCDK and everything works fine. 

I am unable to figure out how to fix this and what is causing the peripheral end connection error. 

Regards,

Harsha

  • Hi Harsha

    Is your custom board using C6748? 

    Do you have any USB sniffer of the problem you're seeing? How far has the enumeration process gone?

    Regards,

    Thanh

  • Hi Thanh,

    Thanks for the reply. I found the reason for this problem, there was a capacitor connected to the data lines which made it work only in full speed modes. So I had to disable USB Highspeed mode in usbphyGS60.c and that did the job. I can see that the USB device is now enumerated.

    #ifdef USB_MODE_HS_DISABLE
    	HWREGB(USB0_BASE + USB_O_POWER) &= 0xdf;
    #endif /* USB_MODE_HS_DISABLE  */

    -- Harsha