Skip to main content
Graduate
October 6, 2024
Solved

STM32F7 USB Device Not Recognized as Virtual COM Port (VCP)

  • October 6, 2024
  • 3 replies
  • 4035 views

Hello everyone,

I’m working on an STM32F7 project where I’m trying to establish USB communication between my STM32F746 Discovery board and a PC. I am really new at this really first time. I have configured the board for USB_OTG_FS in STM32CubeMX, and I’m trying to use it as a Virtual COM Port (VCP). However, when I connect the board to the PC using the USB_FS port, it’s not being recognized as a COM port or any device at all in the Device Manager.

The only time I see a COM port is when I connect the ST-Link USB, which shows up as a Virtual COM Port. I have already:

  1. Enabled the USB_DEVICE in STM32CubeMX and selected the CDC class.
  2. Generated the code and set up the USB_DEVICE middleware.
  3. Tried with different USB cables to rule out a cable issue.
  4. Checked the board configuration, and the USB pins are correctly assigned.

Additionally, I configured the board to flash an LED to confirm it’s functioning, which works fine. My goal is to transfer files between the app I am currently developing and the STM32 board through USB.

I would really appreciate any suggestions or guidance on:

  1. Getting the board to show up as a VCP in the Device Manager.
  2. Troubleshooting USB enumeration issues.

Thanks in advance!

    This topic has been closed for replies.

    3 replies

    Super User
    October 6, 2024

    Start from some ready example in the ST Cube package. Do not trust CubeMX to generate a working project automatically.

    RlakosAuthor
    Graduate
    October 6, 2024

    Thanks, but so far, I could not find any ready example using USB_DEVICE as a VCP, which is the one I need since the board is going to be communicating and receiving files from the app. Do you know of any examples?

    FBLAnswer
    Technical Moderator
    October 7, 2024
    Super User
    October 21, 2024

    What's the primary clock source?

    If internal bootloader is run (using BOOT0 pin), does the board connect as DFU?

    JW

    Visitor II
    May 14, 2025

    I am using STM32F407G-DISC1 board am i am facing the same problem

    Technical Moderator
    May 15, 2025

    Hi @Sanyam_07 

     

    Given that your hardware setup differs from the existing discussion, I recommend starting a new thread where you can clearly outline the issue you're facing. If possible to attach your failing project to narrow down the issue.