Skip to main content
Visitor II
July 17, 2024
Question

32F072BDISCOVERY Serial Print

  • July 17, 2024
  • 1 reply
  • 1073 views

Hi Community,

I am getting started with STM32 chips and I recently acquired the 32F072BDISCOVERY dev kit (https://www.st.com/en/evaluation-tools/32f072bdiscovery.html#overview). I downloaded the STM32CubeIDE and have been able to write,compile, and program simple code to blink one of the LEDs in the board. I was wondering how to set up a com port to serially print data? When I plug in the board to my computer through either of the USB ports (USB USER or USB ST-LINK), I do not see a COM port come up in my device manager, I am assuming it is because I have to set it up. If anyone has any guidance on how to do this, I would greatly appreciate it! 

 

Best regards,

Kevin 

    This topic has been closed for replies.

    1 reply

    Super User
    July 17, 2024

    Hi,

    you could setup a USB-device-CDC  , using Cube, gen. code, flash ;

    then get serial over USB , on USB user port you get it then by your program working.

    +

    Or you try to update the st-link, to V2.1 with CDC serial - if possible, you see it in the update window, to choose : 

    just st-link, or st-link + VCP  (virtual com port). If possible to select, do it, then after update you should see it in PC system.

    On F072 board, then check connection:

    AScha3_0-1721246255232.png

    SB11 + 12 , to connect to usart1 of F072 ; then send on usart1 -> st-link/VCP -> PC (terminal or console in IDE).

    kfc-engAuthor
    Visitor II
    July 18, 2024

    Hi, 

     

    I tried closing those jumpers and enabling the USART1 Interface:

    kfceng_0-1721325866641.png

    However, i still do not see the COM port come up. When you mention updae the st-link, is there an external tool I can use to do that. I tried to "upgrade" but it does not let me select a version called 2.1, see below: 

    kfceng_1-1721325982202.png

    I haven't tried to print anything yet, but I do not see a COM port come up when I plug in the discovery kit. I only see the st-link 

    kfceng_2-1721326042301.png

     

    Best,

    Kevin 

    Super User
    July 18, 2024

    Ok, (i put the j-link debug on my F072-disco ), so i cannot try now.

    But if you stay on V2.0 , no option to V2.1 - then no VCP option there.

    (And i could ask STM, why connect uart1 to st-link, if no option to use it -- =

    Did you try : open in update mode ? If cannot set V2.1 , with VCP , no serial there.

    Try..

    +

    If no way, only make "your" CDC by software; 

    setup a USB-device-CDC  , using Cube, gen. code, flash ;

    then get serial over USB , on USB user port you get it then by your program working.

    + VCP on user USB then, not on st-link usb.

    +

    just look on your board: if st-link has STM32F103C8T6 - it could never work, because not enough flash ;

    afaik st-link V2.1 needs an STM32F103CB , 128KB flash.

     

    btw

    on other board, like STM32F3DISCOVERY

    you see:

    AScha3_0-1721326855034.png