cancel
Showing results for 
Search instead for 
Did you mean: 

Why is my MCO only outputting 8MHZ despite configuring for PLL?

Maaz1
Associate

Hi all

For some reason my MCO(PA8) only outputting 8MHz despite me configuring it for 60MHz

I am completely baffled because I have followed all the correct register settings(as far as I am aware) for the clock configuration, and have followed the clock diagram from the stm32cubeide

Maaz1_1-1752671416926.png

 

Maaz1_2-1752671449312.png

 

Maaz1_3-1752671702986.png

 

 

 

 

Maaz1_0-1752671327014.png

 

I'm working on an STM32U5G9x and its my first time working on such an advanced topic, so apologies beforehand. 

Kind regards

 

 

27 REPLIES 27

@mƎALLEm wrote:

@Maaz1 wrote:

I have attached my ioc file


I've generated a project based on your ioc file and tested it and I can see 60Mhz on PA8 


And the IOC file does, indeed, have MCO configured as 60MHz:

AndrewNeil_0-1752743286251.png

 

So back to @KnarfB's suggestion that the problem is with your measurement

You never did answer his question:

 


@KnarfB wrote:

Does your LA have enough sample frequency or do you see an alias frequency?


 

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.

My MCO is configured to PA8, and I'm using it to test my MCO

strangely, the code from the ioc is giivng me no results, wheras the one I wrote bare metal gives me an actual value(50MHz for now, but I can configure it!!)


@Maaz1 wrote:

strangely, the code from the ioc is giivng me no results, 


That doesn't make sense .. did you change somthing the the ioc file ? what board are you using?

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

I'm using the stm32u5g9 j-dk2. It has an LED screen on it and is blue in colour.

Are you sure you are probing MCO on Arduino connector CN6/pin 4:

mALLEm_0-1752745323047.png

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

Yeah I checked and it gave me a comfortable 60.1MHz, so eventually it worked out for me. I checked my firmware via STM32CUBEPROGRAMMER and for some reason my MCO was set to 8MHZ by default.

 

How would I check the multiplication and divider values on the hal file so i may try and fix my baremetal one, because it would be lighter then.


@Maaz1 wrote:

Yeah I checked and it gave me a comfortable 60.1MHz, so eventually it worked out for me..


If it worked for you need to accept the solution

 


@Maaz1 wrote:

I checked my firmware via STM32CUBEPROGRAMMER and for some reason my MCO was set to 8MHZ by default.


Sorry I didn't understand this statement. Maybe it will be handled in a separated thread..

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.