mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-21 00:58:01 +02:00
ctb server: pll reset to keep the phase after setting clock
This commit is contained in:
@ -225,6 +225,9 @@ int ALTERA_PLL_SetOuputFrequency (int clkIndex, int pllVCOFreqMhz, int value) {
|
|||||||
// write frequency (post-scale output counter C)
|
// write frequency (post-scale output counter C)
|
||||||
ALTERA_PLL_SetPllReconfigReg(ALTERA_PLL_C_COUNTER_REG, val);
|
ALTERA_PLL_SetPllReconfigReg(ALTERA_PLL_C_COUNTER_REG, val);
|
||||||
|
|
||||||
|
// reset required to keep the phase
|
||||||
|
ALTERA_PLL_ResetPLL ();
|
||||||
|
|
||||||
/*double temp = ((double)pllVCOFreqMhz / (double)(low_count + high_count));
|
/*double temp = ((double)pllVCOFreqMhz / (double)(low_count + high_count));
|
||||||
if ((temp - (int)temp) > 0.0001) {
|
if ((temp - (int)temp) > 0.0001) {
|
||||||
temp += 0.5;
|
temp += 0.5;
|
||||||
|
Reference in New Issue
Block a user