cancel
Showing results for 
Search instead for 
Did you mean: 

Trouble Obtaining Desired Clock Frequency on PLLQ and PLLP Pins via MCO Pin on STM32G0B0CET6

Madhumitha_Raja
Associate

                    I am using the STM32G0B0CET6 microcontroller and would like to measure the PLLP and PLLQ clocks using the MCO pin (PA8)  and configured my project using STM32CubeMX version 6.7.0. Initially, I set the RCC->HSE to 12 MHz and generated the clock through the PLL, resulting in a SYSCLK of 64 MHz and observed this clock using the MCO pin, I successfully obtained a signal of 64 MHz without any issues. However, when I tried to route the 48 MHz clock from the PLLQ and PLLP pins through the MCO pin, I did not receive the expected frequency output and I observed a low signal on the scope. I repeated the same process using the HSI RC clock set to 16 MHz, but still, I did not obtain the desired output frequency of 48 MHz on the PLLQ and PLLP pins. Below, I attached my clock configuration and some insight of my code.

I would greatly appreciate any assistance or hints regarding this issue.

 

stm32g0b0_Clock7.png

stm32g0b0_Clock6.png

stm32g0b0_Clock8.png

4 REPLIES 4

Read out and check/post/compare-to-working content of relevant RCC registers (mainly that which controls the MCO mux) and check in GPIO registers if given pin is still set as MCO (MODER is AF and proper AF selected in AFR[]).

JW

Madhumitha_Raja
Associate

JW, I have checked the RCC registers and GPIO registers related to the MCO configuration. Based on my findings, everything appears to be in order. The MCO is configured correctly with AF0 selected, and the pin is set to alternate function mode (MODER is AF) and  ensured that the MCO configuration is correct, I'm still not getting the expected output. It seems there might be another factor affecting the functionality. At this point, I would greatly appreciate any additional help or guidance you can provide to troubleshoot the issue further.

AScha.3
Chief II

just guessing...

you have nothing connected to use this 48M clock, so it is not active. connect something, that use this clock, then you see blue border around it in cube and mco should show this clock active.

AScha3_0-1687761800624.png

 

If you feel a post has answered your question, please click "Accept as Solution".

Hello,

sometimes the PLL’s can have issues to Lock. I recommend using an “Active Probe” to do measurements. If you do not have one, I recommend DIY passive Probe as an alternative. It is very important to avoid the clip-leads, be a short as possible.

The Term is “Capacity Isolation”, even with that “crappy setup”, you get a very good frequency response, the major downside is that the attenuation is odd.

I also recommend using “controlled return paths” for the oscillators, try to avoid spreading EMI all over the PCB and emissions. It also helps to avoid getting Groundloop-Currents coupled to the OSC-In via the capacitors.Best

Regards, Seppel

A wideband 1:21 1 kΩ DIY oscilloscope probe (jahonen.kapsi.fi)

DIY_Low_Cap_Probe.png

OSC_GND_Island.png