mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-12 21:07:13 +02:00
moench server: sync increases when other clocks do
This commit is contained in:
@ -1418,21 +1418,25 @@ void configureSyncFrequency(enum CLKINDEX ind) {
|
||||
|
||||
int configure = 0;
|
||||
|
||||
// sync is greater than current
|
||||
// find the smallest frequency
|
||||
int min = (aFreq < bFreq) ? aFreq : bFreq;
|
||||
min = (retval < min) ? retval : min;
|
||||
|
||||
// sync is greater than min
|
||||
if (syncFreq > retval) {
|
||||
FILE_LOG(logINFO, ("\t--Configuring Sync Clock\n"));
|
||||
configure = 1;
|
||||
}
|
||||
|
||||
// the others are both greater than current
|
||||
else if ((aFreq > retval && bFreq > retval)) {
|
||||
// sync is smaller than min
|
||||
else if (syncFreq < min) {
|
||||
FILE_LOG(logINFO, ("\t++Configuring Sync Clock\n"));
|
||||
configure = 1;
|
||||
}
|
||||
|
||||
// configure sync to current
|
||||
if (configure)
|
||||
configureFrequency(SYNC_CLK, retval);
|
||||
configureFrequency(SYNC_CLK, min);
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user