Skip to main content
R??zt
Associate
August 5, 2018
Question

STM32f429i-Disc1 USB-CDC PC won't see virtual com port. Any idea what to do?

  • August 5, 2018
  • 3 replies
  • 901 views

Hello, I have a STM32f429i-Disc1 board and trying to run a simple usb-cdc code. I've watched many videos on youtube and looked over many examples but I couldn't make it work. board won't appear as virtual com port on device tree. I downloaded stsw-stm32102 and installed vcp drivers. On CubeMX, I activated USB-OTG-FS, activated virtual communication device from middliware USB, configured clocks and then generated codes. On Keil in main.c, I'm inserting following codes to necessary lines.

/* USER CODE BEGIN Includes */
#include "usbd_cdc_if.h"
#include "string.h"
/* USER CODE END Includes */
.
.
 /* USER CODE BEGIN 1 */
	uint8_t Buff1[]="Hop \r\n\r\n";
 /* USER CODE END 1 */
.
.
CDC_Transmit_FS(Buff1, strlen((char *)Buff1));
HAL_Delay(2500);

Both USB (mini and micro) are connected, drivers are installed, codes are prepared as I mentioned but it is as if USB is not initializing and won't appear on pc. By the way, I tried keil examples and both USB-HID and winUSB examples are worked without problem.

So, any idea what am I missing?

    This topic has been closed for replies.

    3 replies

    Tesla DeLorean
    Guru
    August 5, 2018

    Doesn't it use the OTG_HS pins?

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    Pavel A.
    August 5, 2018

    Enable debug prints from the USB modules and see where enumeration stops or fails.

    --pa

    R??zt
    R??ztAuthor
    Associate
    August 5, 2018

    You are right @Community member​ micro usb uses "USB_OTG_HS/Internal Fs Phy" didn't check datasheet and worked over stm32f4-disc examples then I missed this. But I also needed to change heap size to 0x0000 0400, VCP didn't work properly otherwise. Now it is working without problem. Thanks for help.