2019-11-27 01:55 AM
how to know it is a usb charger or PC connect to the stm32 USB device mass storage?
2019-11-27 02:44 AM
If it enumerates the device, it is a PC.
Else, to further detect the kind of charger, google for "USB charger detection". ST has a chip for this.
-- pa
2019-12-01 05:34 PM
>>If it enumerates the device, it is a PC.
means that i need to check the enumerates flag in stm32 usb driver?