STM32WB5 USB CDC not working after STOP mode
Hello,
I am trying to use the USB virtual com port on an STM32WB5MMG. After trying to go into any of the stop modes, I cannot get the virtual com port to work again. (I am using the RTC alarm to wake up the MCU from stop mode and it wakes up fine)
I have tried these commands to get it to restart:
USBD_DeInit(&hUsbDeviceFS);
HAL_Delay(100);
MX_USB_Device_Init();
HAL_Delay(100);I have also tried:
-Before the sleep:
USBD_Stop(&hUsbDeviceFS);-After the sleep:
USBD_Start(&hUsbDeviceFS);
I tried the 2 above method with standby mode on a previous project on this MCU but I can't seem to get it going again.
Also, how I go into stop mode:
HAL_SuspendTick();
HAL_PWR_EnterSTOPMode(PWR_LOWPOWERREGULATOR_ON, PWR_STOPENTRY_WFI);
HAL_ResumeTick();
Does anyone have some suggestions on what it might be?
