Showing results for 
Search instead for 
Did you mean: 

STOP Mode - USB HID Wakeup


hi all and  


USB - HID -Keyboard is working fine and keycode coming properly . 

Enter to STOP mode is successful by HAL_SuspendTick()HAL_PWR_EnterSTOPMode(PWR_LOWPOWERREGULATOR_ON, PWR_STOPENTRY_WFI);

Trying to wakeup from usb keyboard and couldn't catch the callback for adding this  SystemClock_Config (); HAL_ResumeTick(); . what is the exact callback name and where is it 

from existing thread  discussion on EXTI 17 line configuration and exactly  where is this   line   




ST Employee

checking in STM32CubeMX, to have in NVIC table OTG wake-up EXTI line available


You need to allow "Low power" in parameter setting of your USB_OTG_xS device setting


Please check this setting and already existing USB examples in F4 family repository, which will guide you which code you need to add.

Best regards,


cube ide current version


There is no low power option ? .

please suggest which F4 family repository USB examples ? 



ST Employee

I see in your configuration Host_only mode. USB suspend is available only for USB device in STM32CubeMX, I also don't see any example showing USB host suspend, as it's very rarely requested.


Device_Only Mode having low power option !!!!!!!  but as you said Host_Only  mode is suspend the low power option . even i have with checked Cube Mx separately and they also behave same condition . 

Kind Request : can you please confirm me HOST + HID low power option is there or not ? and HOST + HID STOP mode  wakeup is possible or not ?.


ST Employee

In OTG_xS peripheral hardware there is support for both USB host or device with low power support for both modes. But in STM32CubeMX configuration or library example only USB device low power support is covered. So you can manage also USB host low power functionality, but more coding effort is required.

hi , I do agree i need to manage this . it may be crazy but I try use Device_only low power code in HOST_only mode but some typedef are some functions are different for Host _only Mode .

this is just a request if share me small  code of Host_Only low power code  (like eclipse or some other c code )   then it's possible to  mange  for time being .

Hope i can expect HOST_Only low power and USB wakup configuration in coming or future Cube ide update version . 




hi , i need add few more points on this subject .

G Series ,H5 series, L5 Series , U5 Series  controller having low power option in host mode but there is NO USB wake up  interrupt call . these controller having Type C option as per cubemx .


USB HOST +HID +USB Keybord is amazing option for wake from sleep mode and it can performance can be computer wake up by keyboard like wise Stm32 MCU + keyboard + wakeup  can be mini computer . if you feel these findings are correct then please forward to Development Team