2020-01-27 05:56 AM
My hid device is numbered and receives/transmit data from/to Win10 hid driver.
The D5: Remote Wakeup descriptor is set to 1
Unfortunately, I looked through the analyzer and saw that there were no changes of D+ D signals when installing the RWUSIG bit.
I execute the following code when WIN10 sleeps and does not send SOF packets
HAL_PCD_ActivateRemoteWakeup(&hpcd_USB_OTG_FS);
HAL_Delay(10);
HAL_PCD_DeActivateRemoteWakeup(&hpcd_USB_OTG_FS);
The RWUSIG bit is installed, but it does not give anything on the bus.
2020-07-24 10:06 PM
Have a look at the suspend callback code, you see that the USB PHY clock is getting gated. You must ungate before issuing the RWUSIG:
/* Ungate PHY clock */
__HAL_PCD_UNGATE_PHYCLOCK((&hpcd));
/* Activate Remote wakeup */
HAL_PCD_ActivateRemoteWakeup((&hpcd));