Skip to main content
ferhatyol-23
Senior
June 12, 2017
Solved

How to Set SYSCLK up to 72Mhz

  • June 12, 2017
  • 2 replies
  • 1477 views
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
This topic has been closed for replies.
Best answer by ferhatyol-23
Posted on June 13, 2017 at 09:49

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

Thanks

2 replies

Tesla DeLorean
Guru
June 12, 2017
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 VenmoUp vote any posts that you find helpful, it shows what's working..
ferhatyol-23
Senior
June 12, 2017
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?

ferhatyol-23
ferhatyol-23AuthorBest answer
Senior
June 13, 2017
Posted on June 13, 2017 at 09:49

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

Thanks