}
}
#if defined(STA_NANO) && NTP_API == 4
- if (pll_control && kern_enable && sys_tai == 0) {
+ if (pll_control && kern_enable && clock_max > 0 &&
+ sys_tai == 0) {
memset(&ntv, 0, sizeof(ntv));
ntv.modes = MOD_TAI;
ntv.constant = i + TAI_1972 - 1;
* lead to overflow problems. This might occur if some misguided
* lad set the step threshold to something ridiculous.
*/
- if (pll_control && kern_enable && clock_max < 0.5 &&
- clock_max > 0) {
+ if (pll_control && kern_enable && clock_max > 0 &&
+ clock_max < .5) {
/*
* We initialize the structure for the ntp_adjtime()
* is zero to cancel any previous nonsense. If you don't
* want this initialization, remove the ntp.drift file.
*/
- if (pll_control && kern_enable) {
+ if (pll_control && kern_enable && clock_max > 0) {
memset((char *)&ntv, 0, sizeof(ntv));
ntv.modes = MOD_FREQUENCY;
ntv.freq = (int32)(drift_comp * 65536e6);
#define SUBFLD 10 /* bits per frame */
#define FIELD 100 /* bits per second */
#define MINTC 2 /* min PLL time constant */
-#define MAXTC 20 /* max PLL time constant max */
+#define MAXTC 10 /* max PLL time constant max */
#define MAXAMP 5000. /* maximum signal amplitude */
#define MINAMP 4000. /* minimum signal amplitude */
#define DRPOUT 100. /* dropout signal amplitude */