Dear TI team,
we're trying to change the frequency of our OSPI reference clock within our application (still using SDK 06.03).
retval = Sciclient_pmSetModuleClkFreq(248U, 0U, ospiRecClk, TISCI_MSG_FLAG_CLOCK_ALLOW_FREQ_CHANGE, SCICLIENT_SERVICE_WAIT_FOREVER); retval = Sciclient_pmGetModuleClkFreq(248U, 0U, &ospiFunClk, SCICLIENT_SERVICE_WAIT_FOREVER);
The Sciclient returns "success" but is still returning the previous frequency when we query the clock.
We found out that changing the clock works if we first manually unlock the PLL registers by writing to the kick/lock registers:
*(volatile uint32_t *) (CSL_MCU_PLL0_CFG_BASE + CSL_MCU_PLL_MMR_CFG_PLL0_KICK0) = KICK0_UNLOCK_VAL; *(volatile uint32_t *) (CSL_MCU_PLL0_CFG_BASE + CSL_MCU_PLL_MMR_CFG_PLL0_KICK1) = KICK1_UNLOCK_VAL;
It seems that the Sciclient doesn't unlock the PLL registers.
- I guess it is not intentional that this works only if I unlock the PLL registers first?
- has this been fixed in the newer SDK 7.0? I haven't found a reference to this issue in the release notes.
- What is the intended way to modify clocks?
Regards,
Dominic