cancel
Showing results for 
Search instead for 
Did you mean: 

Overclocking experiment - proved how large margins are in STM32G0

WojtekP1
Associate III

I tried to overclock STM32G030. I didn't need more speed and such operations should never be used in final product - only for curiosity.

But it's 64MHz according to specs. I ended at 160Mhz. Room temperature, 3.3V power supply

Tested with rather simple program but one acccessed RAM, FLASH and used UART to output result of quite simple calculations. At 160MHz it still worked. It felt cool to touch.

What that means is that it CERTAINLY will run at 64MHz at highest or lowest allowed temperature, lowest allowed voltage and still with some margin.

4 REPLIES 4

For the longest time ARM wanted CM0(+) parts running slowly, say max 24-32 MHz so that they didn't erode the market for CM3/CM4F parts.

I think there was an NXP part that ran one at 100 or 200 MHz as a slave processor, entirely from RAM. The CM0 has no caching , or ART prefetch/cache in front of the FLASH. The STM32F0, etc, were effectively crippled by FLASH, which is perhaps rated at 24-27 MHz operation, so running at 32 MHz added a wait state, and didn't allow the code to run much faster than it would at slower speeds with no-wait states.

I've got some CM3 implementations on my desk than run at 384 MHz, no-wait states, running code entirely from a large SRAM, 768KB fetched and decrypted from a SPI FLASH by a ROM based loader.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Ben3
Associate

I have been able to push the G030F6P6TR to 240 MHz. Stable on 3.3V is somewhere around 216-220Mhz. Cooling never seems to be an issue, even on 240MHz. I have also found a few interesting facts. Setting  RCC_OscInitStruct.HSICalibrationValue = 0U; enables higher clocks. 

if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_0) != HAL_OK)
{ }

Needs the error handler removed to achieve higher clocks.

The internal OSC seems to be better for stability than external ones.

RCC_OscInitStruct.PLL.PLLM = RCC_PLLM_DIV3;
RCC_OscInitStruct.PLL.PLLN = *SECRET SAUCE*;
RCC_OscInitStruct.PLL.PLLP = RCC_PLLP_DIV2;

PLLP shouldn't to be not above /2 and you can go higher than the maximum multiplier in CUBEMX. The limit is somewhere around ~120. 

90% of chips can reach 216MHz without an issue, and TR variants seem to be more stable. (Sample size 100)

Anyways I really hope I can reach 300MHz someday. As far as I know I already hold the world record as of now but when I get bored at work I would like to push even further. I even got a new oscilloscope, so now I have the potential to measure until 1GHz.

The next step is to rewrite hal rcc and pwr and see what I can do running on 4 Volts with a completely custom solution. Also maybe larger package M0+ have more potential. I am sure I missed some tricks to get higher clocks, so I am always open for others to enter my race to get to 300MHz.

 

Danish1
Lead II

St have Application Note an5337-stm32h7-series-lifetime-estimates.pdf which suggests that if you have an symH743 or similar, and run it at the data-sheet maximum core voltage (which the data-sheet says is needed for reliable operation at the highest speeds and minimum number of wait-states), operation at high temperatures might reduce the device lifetime to just Two Years!

I don't know if their two-year estimate is an average, and that many devices will have started misbehaving well before that, or if it represents a recommended replacement interval i.e. point at which something like 1% of devices might start to show frequent soft-errors.

ST do say that you'll generally be fine provided you spend a lot of time at reduced voltage, (when you've less urgent processing to do).

They don't mention what the failure mode would be, nor its symptoms - whether things just get less reliable at the top speeds but continue to work fine at lower speeds.

I suppose all I'm saying is that "Overclocking worked fine today even at extreme temperature" doesn't mean it will reliably continue to do so.

I have had lifetimes of a few minutes just to about 30 mins with high clocks. But then again I am also pushing the MCU to a few times the maximum clock. Then again if a single MCU is 0.4$, I don't really care them dying. I think the advertised speed of 64MHz is the most I would be willing to run for a product. Also messing around the way I did is just ends with all peripherals being unusable, due to the timing being so far off. The highest possible speed without losing all of the functionality is around ~180MHz would be my guess.