Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

USB Host Enumeration problem

Status
Not open for further replies.

Prakash Rajolli

Newbie level 6
Joined
Jul 16, 2010
Messages
13
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
Bangalore
Activity points
1,416
Hello,

I've never done a USB Host interface before, now I am trying to
enumerate USB Host using NXP's USBHostLite example using LPC1768
controller.

It stuck at "while (!HOST_RhscIntr);"

I got a short serial output followed by flashing

----------------------------
Initializing Host Stack
Host Initialized
Connect a Mass Storage device
-----------------------------

Can anybody tell me why

"LPC_USB->OTGStCtrl = 0x3;" statement is using. And if I use
"LPC_USB->OTGStCtrl = 0x203;" this statement then serial output is
followed as

------------------------------------
Initializing Host Stack
Host Initialized
Connect a Mass Storage device
ERROR: In Host_EnumDev at Line 358 - rc = -1
---------------------------------------------

The line (Line 358 in usbhost_lpc17xx.c) is this block of code:

rc = HOST_GET_DESCRIPTOR(USB_DESCRIPTOR_TYPE_DEVICE, 0, TDBuffer, 8);
if (rc != OK) {
PRINT_Err(rc);
return (rc);
}

Could it be an issue with my USB drive or hardware?

The schematic for usb host I have attached.


I have ensured that PORT_FUNC in OTGStCtrl register is 0x3, PWRD, PPWR, POVRCR, USB-D+ and USB-D- are set correctly for USB host in PINSELx.

Further observations are as follow,

1. It stuck at "while (!HOST_RhscIntr) ;" and If I not initialize UART, then get rc = -1 at
------------ --------- --------- --------- --------- --------- --------- ---
rc = HOST_GET_DESCRIPTOR (USB_DESCRIPTOR_ TYPE_DEVICE, 0, TDBuffer, 8);
if (rc != OK) {
PRINT_Err(rc) ;
return (rc);
}
------------ --------- --------- --------- --------- ----

because HOST_TDControlStatu s = 5.

2. Before setting of global power bit in OHCI RHStatus,
HcRhStatus = OR_RH_STATUS_ LPSC; /* Set Global Power */
voltage at PWRD pin is 4.68v and after setting of global power
PWRD = 0.8V
is it correct?

Many thanks in advance,

-Prakash
9886545216
 

Hello! I have same problem in my board with LPC2478 from EmbeddedArtists. Interrupt Host_Isr do not occur. I don't know why. Do you solve your problem?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top