+ Post New Thread
Results 1 to 5 of 5
  1. #1
    Newbie level 3
    Points: 436, Level: 4

    Join Date
    Oct 2016
    Posts
    3
    Helped
    0 / 0
    Points
    436
    Level
    4

    Problem with VPC USB FS and STM32F103VET6 device.

    Hello Community,



    I purchased a Cortex-M3 STM32F103VET6 board and trying to implement USB FS on it. I'm using CubeMX to generate code, the version is up to date and i'm using the latest firmware libraries (FW_F1_V1.6.1). After compile USB device doesn't appear on the Device Manager.

    Are there somebody who can help me fix this problem.



    Thanks and BRs,

    •   AltAdvertisment

        
       

  2. #2
    Newbie level 5
    Points: 328, Level: 3

    Join Date
    Jul 2017
    Posts
    9
    Helped
    2 / 2
    Points
    328
    Level
    3

    Re: Problem with VPC USB FS and STM32F103VET6 device.

    Please check the application note and please post a circuit and code.

    Application note: AN4879: USB hardware and PCB guidelines using STM32 MCUs
    from https://www.st.com/en/microcontrollers/stm32f102r4.html



    •   AltAdvertisment

        
       

  3. #3
    Newbie level 3
    Points: 436, Level: 4

    Join Date
    Oct 2016
    Posts
    3
    Helped
    0 / 0
    Points
    436
    Level
    4

    Re: Problem with VPC USB FS and STM32F103VET6 device.

    I bought this evaluation board from the devicemart.co.kr website.

    https://imgur.com/a/pe8RdoY

    I created a STM32CubeMX project with some setting change like below:
    - RCC: HSE: Crystal/Ceramic Resonator
    - SYS: Debug: Serial Wire
    - USB: Turn on Device (FS)
    - USB Device: Communication Device Class (VPC)
    - Others: Default

    Then, I generate code and flash into this device. However, nothing appears in the Device Manager tree.

    I tried to increase the Minimum Heap Size to 0x1000 follow this link: https://community.st.com/s/article/F...not-recognized
    but its same phenomenon.



    •   AltAdvertisment

        
       

  4. #4
    Advanced Member level 3
    Points: 7,119, Level: 20

    Join Date
    Jan 2015
    Posts
    996
    Helped
    318 / 318
    Points
    7,119
    Level
    20

    Re: Problem with VPC USB FS and STM32F103VET6 device.

    Does your device actually have an 8MHz crystal connected to pins 12 and 13 on the MCU? Many of the ST-based development boards I've seen have the 32kHz crystal for the real time clock but rely on the internal oscillator for main system clock.
    The schematic does show the 8MHz crystal but also says that it is socketed - you may need to add it yourself.
    The alternative is to use the internal oscillator and the internal PLLs to get the correct frequency for the USB device. The clock tab in the STMCubeMX IDE will tell you when you have it right.
    One other way to tell is to start with something simpler such as the flash a LED, or even try to debug a simple bit if code - if the code runs at all then the system clock settings are OK (although the frequency may still be wrong).
    Susan



  5. #5
    Newbie level 3
    Points: 436, Level: 4

    Join Date
    Oct 2016
    Posts
    3
    Helped
    0 / 0
    Points
    436
    Level
    4

    Re: Problem with VPC USB FS and STM32F103VET6 device.

    Quote Originally Posted by Aussie Susan View Post
    Does your device actually have an 8MHz crystal connected to pins 12 and 13 on the MCU? Many of the ST-based development boards I've seen have the 32kHz crystal for the real time clock but rely on the internal oscillator for main system clock.
    The schematic does show the 8MHz crystal but also says that it is socketed - you may need to add it yourself.
    The alternative is to use the internal oscillator and the internal PLLs to get the correct frequency for the USB device. The clock tab in the STMCubeMX IDE will tell you when you have it right.
    One other way to tell is to start with something simpler such as the flash a LED, or even try to debug a simple bit if code - if the code runs at all then the system clock settings are OK (although the frequency may still be wrong).
    Susan
    Device has an 8MHz crystal connected to pins 12 and 13 on the MCU.
    I already tried to make some sample codes using I2C, SPI, Led blink and debug these source using ST-Link V2. It works normally.
    The remaining problem is the connecting problem with the computer using Micro-USB (USART1).



--[[ ]]--