Hello,
I am working on writing a driver for the peripheral side of the USB:
* I am not using Linux
* Using Full Speed
* I am not using DMA
* I am able to enumerate the device, show it in Windows as CDC Serial, open terminal (PuTTY) and receive data from the device (Bulk IN transfer working OK), this is a constant behavior, it works every time.
* I am using different endpoints for OUT and IN transfers.
My problem is with Bulk OUT transfers.
I am configuring the endpoints after a reset is detected (just as the Bulk IN EP), I'm setting the RXMAXP to 64, RXFIFOSZ to 3, RXFIFOADDR 8 (it's EP1), checking FULLFIFO bit and if it is set, then I FLUSHFIFO. I am doing this in the order shown in the Datasheet.
When I send one character from the PC, I get the interrupt for EP1, I read the RXCOUNT (after setting INDEX to 1 or the corresponding EP number) and it gives me a very big number.
I have tried switching enpoints (trying in EP2 and EP3 and configuring RXFIFOADD accordingly) and same problem, I am able to transmit data no matter what EP for IN transfer I am using but not able to receive data.
Can someone point me to the right direction to get Bulk OUT transfers working?
Thanks in advance,
- Esaias