Skip to main content
Maxim Petrenko
Visitor II
July 14, 2017
Question

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

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
This topic has been closed for replies.

1 reply

Vangelis Fortounas
Associate II
July 14, 2017
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.