cancel
Showing results for 
Search instead for 
Did you mean: 

USBH_BulkReceiveData problem

mzennaro
Associate II
Posted on August 28, 2013 at 10:30

Hello all,

I am using an stm32f105rc as an usb host to manage a cp2102 with freertos and st host stack.

I found a problem with USBH_BulkReceiveData: sometimes it issues two bulk requests so I miss a byte.

The connections are: one uart from pc to stm32, one usb from stm32 to cp2102, one uart from cp2102 to pc. stm32 routes bytes from its uart to usb and back, so I can connect two terminals on the pc and send strings to each other.

I can sniff packets from stm32 to cp2102 and this is what I get:

0690X00000602peQAA.jpg

The green rectangle shows the correct behaviour USBH_BulkReceiveData issues one request and HCD_GetURB_State+HCD_GetXferCnt let me get the data.

The red rectangle shows the wrong case: one call to USBH_BulkReceiveData causes two requests but I can get only the second, so I miss the first byte.

Thank you for your help
0 REPLIES 0