AnsweredAssumed Answered

Slow in USB Mass Storage Detection

Question asked by PRAMOD K. G. on Mar 5, 2015
Latest reply on Mar 25, 2015 by soledad

Hi All,

I am woroking with K70 on a custom board.I have modified the USB Mass storage example code SD card and working fine. The change I made is

From

case USB_MSC_DEVICE_READ_REQUEST :         
    lba_data_ptr = (PTR_LBA_APP_STRUCT)val;
    #if RAM_DISK_APP
        USB_mem_copy(g_disk.storage_disk + lba_data_ptr->offset,
                lba_data_ptr->buff_ptr,
                lba_data_ptr->size);
    #endif        
    break;
case USB_MSC_DEVICE_WRITE_REQUEST :
    lba_data_ptr = (PTR_LBA_APP_STRUCT)val;
    #if RAM_DISK_APP
    USB_mem_copy(lba_data_ptr->buff_ptr,
                    g_disk.storage_disk + lba_data_ptr->offset,
                    lba_data_ptr->size);
    #endif                         
    break;

TO

case USB_MSC_DEVICE_READ_REQUEST :   

    lba_data_ptr = (PTR_LBA_APP_STRUCT)val;

    fread(lba_data_ptr->buff_ptr, 1, 1, filesystem_handle);

    break;

case USB_MSC_DEVICE_WRITE_REQUEST :

    lba_data_ptr = (PTR_LBA_APP_STRUCT)val;

    fwrite(lba_data_ptr->buff_ptr, 1, 1, filesystem_hanlde);

    break;

 

The problem I am facing is it very slow for USB detection and data transfer with PC. Please let me know what I can do for speed transfer, currently it is 100kbps.

 

Thanks,

Pramod.

Outcomes