I'm having a problem and I cannot find the solution.
As a first I made for test an USB+SDcard reader project (with fatfs) and I flashed it on the launchpad.
Windows takes in detecting the new device around 5s, and it works perfect.
Then I used the same project on my own board.
Windows takes in detecting the new device around 30s, and it works perfect.
It is not a hardware problem, because it's the same to the launchpad.
Any hint?
My init code is:
void USB_MSC_Initialize(void) { USBIntRegister(USB0_BASE, USB0DeviceIntHandler); //USBIntEnableControl(USB0_BASE, USB_INTCTRL_ALL); //ROM_IntPrioritySet(USB0_BASE, 0x00); // // Set the USB stack mode to Device mode without VBUS monitoring. // USBStackModeSet(0, eUSBModeForceDevice, 0); // // Pass our device information to the USB library and place the device // on the bus. // USBDMSCInit(0, (tUSBDMSCDevice*)&g_sMSCDevice); } void USB_MSC_Config(void) { // // Configure and enable uDMA // ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_UDMA); ROM_SysCtlDelay(10); ROM_uDMAControlBaseSet(&sDMAControlTable[0]); ROM_uDMAEnable(); // // Enable Peripheral Clocks // ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_USB0); ROM_SysCtlUSBPLLEnable(); ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD); ROM_SysCtlDelay(10); // // Enable pin PD5 for USB0 USB0DP // ROM_GPIOPinTypeUSBAnalog(GPIO_PORTD_BASE, GPIO_PIN_5); // // Enable pin PD4 for USB0 USB0DM // ROM_GPIOPinTypeUSBAnalog(GPIO_PORTD_BASE, GPIO_PIN_4); }
int main(void)
{
//
// Set the clocking to run from the PLL at 50MHz
//
ROM_SysCtlClockSet(SYSCTL_SYSDIV_3 | SYSCTL_USE_PLL | SYSCTL_OSC_MAIN | SYSCTL_XTAL_16MHZ);
USB_MSC_Config();
USB_MSC_Initialize();
while(1)
{
}
}