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.

Looking for a skeleton for Host MSC, Device MSC for the USB OTG controller

Hi,

I am working TM4C series based controller. As I have an example code for OTG HID class for DK-TM4C129X. I have the two individual implementation for Host MSC and Device MSC. Based on the HID class example I am able to detect the switching between Host (Pendrive connection) and Device (PC communication). Please find the attached rar file. When I plug in the Pen Drive to the micro, the application is waiting forever in USBHMSCDriveReady state.

Thank you,

Best Regards,

Kiran Kumar

usb_otg_mouse_tm4c127.rar

  • Hello Kiran,

    Can you first check the board with the following example to weed out any hardware or connection issue, before proceeding for software checks?

    D:\ti\TivaWare_C_Series-2.1.1.71\examples\boards\dk-tm4c129x\usb_host_msc

    Regards
    Amit
  • Hi Amit,

    I did not enable uDMA controller for the MSC.
    Thanks for the reply.

    Thanks
    Kiran
  • Hello Kiran,

    I did not get what you meant by did not enabled UDMA!!!

    Regards
    Amit
  • Hi Amit,

    To implement the OTG - MSC class for TM4C, I was using OTG - HID class implementation which is provided in C:\ti\TivaWare_C_Series-2.0.1.11577\examples\boards\dk-tm4c129x\usb_otg_mouse. In this HID class example uDMA is not under use. As per the MSC class documentation DMA is needed. For that I've added these following

    #pragma DATA_ALIGN(g_sDMAControlTable, 1024)
    tDMAControlTable g_sDMAControlTable[6];

    SysCtlPeripheralEnable(SYSCTL_PERIPH_UDMA);
    uDMAEnable();
    uDMAControlBaseSet(g_sDMAControlTable);

    Thank you,
    Best Regards,
    Kiran
  • Hello Kiran

    Thanks for the confirmation and follow up post

    Regards
    Amit