AnsweredAssumed Answered

writing a usb stack for p2041rdb...

Question asked by Deniz Demiray on Oct 21, 2016

Hi There,

 

I need to develop a usb stack for a custom RTOS on Freescale P2041rdb.

 

So far, i followed the 'host controller initialization' procedure (as in
section 16.7.1 of the QorIQ P2040 reference manual).
I powered and enabled the ports on the host controller, and detected
the speed of an attached usb device through PORTSC register.

But i have some problems with the enumeration, i cannot get the device
descriptor. I prepared necessary structures, a queue head (H bit set, dtc bit
and overlay area cleared) and 3 transfer descriptors (first one pointing the
setup packet), and allocated enough physical memory for them (at the non-cachable
are of the memory, with proper alignment). I also performed proper byte swapping
to change endianness. ASYNCLISTADDR register holds the address of the queue
head.

 

After enabling the async list through USBCMD register, AS and RCL bits at the
USBSTS are set, and that's it. I do not observe any changes on the overlay area
of the queue head and the status field of the transfer descriptor remains active.

Please note that i do not use periodic schedule (PSE bit of the USBCMD and
PS bit of the USBSTS are cleared), C-mask and S-mask fiels of the queue head
are also cleared.

 

Any ideas?

 

deniz

Outcomes