Skip to main content
Explorer
July 27, 2024
Solved

STM32G4 and MCO pin

  • July 27, 2024
  • 2 replies
  • 1520 views

I am using STM32G431cbtx and enabling RCC_MCO. Since the STM32G4 supports two pins, PA8 and PG10, PA8 is being used for another function, and I am using PG10 for RCC_MCO. However, when measuring the voltage on pin PG10, it is always high.

Can anyone explain it to me?

    This topic has been closed for replies.
    Best answer by AScha.3

    Ok,

    so:

    AScha3_0-1722241090978.png

    AScha3_1-1722241140628.png

    Did you set option bytes -> pg10 = not nrst, but alternate function (mco) ?

    2 replies

    Super User
    July 27, 2024

    Show, what you set in Cube ...

    +

    What frequency you want at mco ?

    Set pin speed high ?

    Scope probe at 10:1 ?

    Explorer
    July 29, 2024

    Locnvselex_vn_0-1722220590818.pngLocnvselex_vn_1-1722220704520.png

    I have tested RCC_MCO on pin PA8 and it was successful. But when I tested it on PG10 (Reset Pin), it was always high

     

    AScha.3Answer
    Super User
    July 29, 2024

    Ok,

    so:

    AScha3_0-1722241090978.png

    AScha3_1-1722241140628.png

    Did you set option bytes -> pg10 = not nrst, but alternate function (mco) ?

    Explorer
    July 30, 2024

    That's correct. However, the RCC_MCO signal still cannot be measured on PG10 pin!