2017-05-03 07:29 AM
Hi,
We are using STM32F072C8 device and we are using USB CDC Interface when communicating with PC.
When USB bus traffic is low everything is working fine.
But when
USB bus traffic is heavy we observed during USB CDC Write the Tx state showing always busy.
Not get recovering from here due to USB Write is Blocking and our application gets hanging.
We are using the USB CDC drivers generated by STM32CUBE app.
uint8_t CDC_Transmit_FS(uint8_t *buf,uint8_t Length)
{ uint8_t result = USBD_OK; unsigned int l_len; USBD_CDC_HandleTypeDef *hcdc = (USBD_CDC_HandleTypeDef*)hUsbDevice_0->pClassData; // if USB is busy then return if(hcdc->TxState != 0) { return USBD_BUSY;//It is hanging here. }Please can you suggest what to we check and what to do..
2017-12-20 09:29 PM
Hello,
We are also facing the similar problem. code getting stuck in hcdc->TxState state in CDC_Transmit_FS function.
We are trying to send data from USB CDC to PC. Any help would be appreciated.