How to change Synchronous Pre-Divider
I am using an F4 discovery board and trying to using the included 8MHz HSE crystal to drive the RTC. I am using CubeMX to configure everything and I have configured the RTC to generate the calibration 1Hz signal that I am watching on a scope.
Initially I was using the LSI but the frequency is not very reliable so I thought the HSE would be better. The problem I have is that when I swap to the HSE the frequency of the calibration signal is way too high (about 32Hz instead of 1Hz). When selecting the HSE as the input for the RTC in CubeMX there is a divide by 8 and I have changed the Asynch predivider to 124 and the synch predivider to 7999 which should result in a 1Hz output. When testing in the debugger I can see that the values have been set correctly in the RTC PRER register.
What I have found is that changing the synch predivider is having no effect on the calibration signal. The divide by 8 that happens when selecting HSE for the RTC is configurable and changing this changes the the calibration signal frequency as expected though I don't know exactly how that part of it works.
Looking at the user manual and the RTC guide I can see that the calibration signal comes from the output of the synch predivider so I am at a loss as to why changing this value has no effect on the signal even though it is properly set in the RTC PRER register.
Any help or ideas would be greatly appreciated.
