2024-07-31 12:39 AM
I am trying to run STM32H735 in 550 MHz, i had read the reference manual so write the following code.
FLASH_OPTKEYR = 0x08192A3B;
FLASH_OPTKEYR = 0x4C5D6E7F;
if (SYSTICK_FREQ > 450 * 1e6 && !(FLASH_OPTSR2_CUR &= FLASH_OPTSR2_CPUFREQ_BOOST)) {
FLASH_OPTSR2_PRG |= FLASH_OPTSR2_CPUFREQ_BOOST;
} else if (SYSTICK_FREQ <= 450 * 1e6 && (FLASH_OPTSR2_CUR &= FLASH_OPTSR2_CPUFREQ_BOOST)) {
FLASH_OPTSR2_PRG &= ~FLASH_OPTSR2_CPUFREQ_BOOST;
}
while (FLASH_SR &= FLASH_SR_BSY)
FLASH_OPTCR |= FLASH_OPTCR_OPTSTRT;
while (FLASH_SR &= FLASH_SR_BSY)
FLASH_OPTCR |= FLASH_OPTCR_OPTLOCK;
And print the log output to monitor the register status
LOGF("SYSCFG - CPU_BOOST : %d, FLASH - CPU_BOOST : %d\n", SYSCFG_UR(18) & 1, FLASH_OPTSR2_CUR);
Here is the result
SYSCFG - CPU_BOOST : 0, FLASH - CPU_BOOST : 4
I expected that SYSCFG18::CPU_FREQ_BOOST should be set to 1, but it not.
Is there any process wrong or less for enable CPU_FREQ_BOOST bit?
2024-07-31 01:52 AM
Problem solve,