Content originally posted in LPCWare by ezharkov on Mon Oct 21 15:49:35 MST 2013
I have a bit of USB Mass Storage Host code that is based on NXP's USBHostLite. It works, sort of, but only once. It looks that the original NXP'e example has the same problem.
The problem is that the HCI seems to ignore the first Bulk Input Transfer Descriptor.
Here are some more details. I plug a flash drive. Do something with it. Everything is fine. Unplug. Plug again. Try to do the same "something" again. No luck! I get stuck waiting for the completion of the first Bulk input. All the control trasactions preceding the bulk transaction work exactly like the first time.
What is the first bulk transaction? The TEST_UNIT_READY command. Sending the Command Block Wrapper completes fine. But I never get the Command Status Wrapper.
I assume that if something is not quite right with the device, the HCI seem to respond to me in some way? Or do I have to take care of timeouts myself somehow?
I'm on using LPC1788.
Eugene