USB Communications Device example

Sysprogs forums Forums VisualGDB USB Communications Device example

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #12034
    KonstantinL
    Participant

    Greetings,

    I have tried the example (USB Communications Device) but it seems no communication via USB (no breakpoint hits on the line VCP_write(“\r\nYou typed “, 12);).

    Could be the problem in USB 1.1 (not 2.0) cable?

    #12037
    support
    Keymaster

    Hi,

    Most likely your device is using a different clock frequency than the device used in the default USB communication sample. Please try locating a sample for your device/board in the ST samples folder and copying the SystemClock_Config() function from it.

    Another alternative would be to select “Use STM32CubeMX samples” when creating a new project. This will locate a matching ST sample for your board that should have the correct clock settings specified.

    #12054
    KonstantinL
    Participant

    Sorry,  this field is new for me.

    Do you mean this value?:

    /** @addtogroup STM32F4xx_System_Private_Variables

    */

    uint32_t SystemCoreClock = 16000000;

     

    The board in question:

    OLIMEX STM32-P405

    STM32F405RG

    Cortex-M4
    32bit
    168 Mhz

    Should I replace 16.000.000 with 168.000.000?

     

    #12080
    support
    Keymaster

    Hi,

    It’s actually a bit more complex. If you are not familiar with the STM32 clock settings, please try using the STM32CubeMX tool to specify them graphically (see this tutorial for details). You can also try contacting Olimex for examples that work with their board.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.