Question
STM32L1 - USB Connection / Disconnection not provided by API
Posted on August 27, 2015 at 12:18
Hello there,
Trying to handle USB connection / disconnection event I realize that in stm32l1 usb api, there are no call to HAL_PCD_ConnectCallback neither HAL_PCD_DisconnectCallback as there are in STM32F4 !The session start/stop only works with HAL_PCD_ResumeCallback/HAL_PCD_SuspendCallback.These callbacks are called from HAL_PCD_IRQHandler(PCD_HandleTypeDef *hpcd) in stm32l1xx_hal_pcd.c which manage PCD IRQ.At the moment, it seems there's no USB_ISTR register flag for detecting connection / disconnection.Do someone find a clean solution for handling these events, especialy regarding power management and safety of use ?Thx. #stm32l1 #connection #usb