cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H7RSxx + OEMuROT: updating clock settings

We have a board with an STM32H7S3, using STiROT and OEMuROT to run our own application. The application runs in place from external flash, and uses external RAM for data.

The process has proven extremely challenging, but we have been able to get the application to run...up to the point where it needs to initialise a peripheral which uses a PLL-dependent clock.

OEMuROT does some clock initialisation, but we need to change some of those settings, including turning on additional PLLs.

I've tried adding clock setup code to the app (originally generated by CubeMX), but it fails because you can’t change PLL settings while they’re running. So I added a call to the HAL function to reset the clocks first – but that also doesn’t work because we’re running from the external flash at this point, which relies on a PLL!

I then tried moving the clock setup code into the bootloader – in the code which runs at the end of proceedings, or at the start – but they also failed.

This code has to run from internal flash, but I wasn’t able to find a spot in the bootloader where this works.

So, how are we supposed to handle this?

0 REPLIES 0