cancel
Showing results for 
Search instead for 
Did you mean: 

How to Set SYSCLK up to 72Mhz

ferhatyol-23
Senior
Posted on June 12, 2017 at 17:51

Hi

I created new STM32F103C8 project. I'm using STD Periph library. STM32F103 works with 8Mhz HSE oscillator. But I did not get 72 Mhz. I'm measuirng PLLCLK frequency with MCO.

  RCC_MCOConfig(RCC_MCO_PLLCLK_Div2); 

I was only 4 Mhz with the MCO. So PLLCLK is 8Mhz

How to increase the SYSCLK frequency to 72Mhz?

I attached the project file. Thanks

#frequency #stm32f103 #72mhz #sysclk
1 ACCEPTED SOLUTION

Accepted Solutions
Posted on June 13, 2017 at 09:49

The 72Mhz problem has been resolved. HSE is not working properly. 

Thanks

View solution in original post

3 REPLIES 3
Posted on June 12, 2017 at 19:34

Project seems to be a bit of a dogs breakfast... Lots of code pulled from different incoherent sources. 

Look at the SPL project templates for Keil for a cleaner abstraction.

Why call SystemInit() from main(), shouldn't this already be called from startup_stm32f10x_ld.s? Same with SCB->VTOR setting

PLL and HSE initialization code is in system_stm32f10x.c, you should have a project unique copy of this in your own project directory rather than the library. Check defines for CPU and code compiled into project.

Does the HSE start properly? Try stepping through SystemInit(); Turn off 'run to main' debugger options so you can step into it from the Reset Handler.

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
ferhatyol-23
Senior
Posted on June 12, 2017 at 21:24

Hi Clive

Thank you for the reply, I just made the following definitions for the start of the HSE oscillator.

USE_STDPERIPH_DRIVER,STM32F10_MD,HSE_VALUE=8000000 

These definitions did not change the result.

But even if the HSE oscillator works, it does not increase to 72 MHZ. I gave up calling the SystemInit function.

What else can I do?

Posted on June 13, 2017 at 09:49

The 72Mhz problem has been resolved. HSE is not working properly. 

Thanks