cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F103 when powered from USB - not seen as Virtual COM Port

Maxim Petrenko
Associate
Posted on July 14, 2017 at 07:58

I am trying to use F103c8t6 with USB in virtual COM port mode, using CubeMX tools. If the device is powered from an external source before USB connecting - when connect USB cable it is recognized by Windows normally. But when I try to power it from USB only, it is seen as an unknown device when connect USB cable. Code has been generated with 'SELF_POWERED' option in CubeMX switched off.

#usb #virtual-comport-stm32
1 REPLY 1
Posted on July 14, 2017 at 08:33

Hello ...   Try to establish a few ms delay after power on to stabilize power and after give the  'MX_USB_DEVICE_Init();'

You can  check if usb is configured  'if(hyourusbdevice.dev_state == USBD_STATE_CONFIGURED)...  ' after initialization   and / or  wait.