2020-05-16 10:08 AM
Hi have the use a USB aplication with STM32L151CBT6ATR, but this uC have not a dedicated pin for VBUS sensing, how is the way to resolve that situation ?
I readed AN4879 and usb_20.pdf specification and not are cleare for me.
Much apreciate any solution
2020-05-16 10:22 AM
You can use any GPIO pin and ensure the voltage is sufficient before enabling USB, and trigger an interrupt when the voltage drops below a given amount to disable USB.
2020-05-16 10:37 AM
An this solution have a direct support for USB FS library code generated for STM32CubeMX ?
2020-05-16 11:12 AM
Not sure, probably not.
2020-05-16 12:36 PM
Thanks you for your answer