Skip to main content
Explorer
July 21, 2023
Solved

USB FS Data Traffic Suspend And Resume

  • July 21, 2023
  • 1 reply
  • 1351 views

Hi,

I configured USB FS on my STM32WB55 NUCLEO Board and it works as I expected (configured as CDC). I can send and receive data to/from Host (my PC) but now I have the need to suspend temporarly Data Flow and then reprise it.
My goal is to collect some data, elaborate them and then get some other data from host. To do so, I need to "suspend" USB communication end then "Resume" it. 
I tried to use USBD_LL_Suspend() and USBD_LL_Resume() but it seems like to get communication stuck.
In particular, when I call USBD_LL_Suspend(), Host does not send data any longer and calling USBD_LL_Resume() seems like to have no effect.
Any idea/suggestion?

Thanks a lot in advance!

Simo.

This topic has been closed for replies.
Best answer by ABOUA

Hello FuzzySimo,

Device could not suspend itself suspend/resume requests should come from host side

to stop communication from device side you could just delay preparing the next transfer and while you are still processing the received data the device NAK the host data requests

Regards

 

1 reply

ABOUA
ABOUABest answer
ST Employee
August 10, 2023

Hello FuzzySimo,

Device could not suspend itself suspend/resume requests should come from host side

to stop communication from device side you could just delay preparing the next transfer and while you are still processing the received data the device NAK the host data requests

Regards