diff --git a/lib/hooks/dft.cpp b/lib/hooks/dft.cpp index 1388603b5..1f5c790c5 100644 --- a/lib/hooks/dft.cpp +++ b/lib/hooks/dft.cpp @@ -93,7 +93,6 @@ protected: int* signal_index;//a list of signal_index to do dft on uint signalCnt;//number of signal_index given by config file - public: DftHook(struct vpath *p, struct vnode *n, int fl, int prio, bool en = true) : Hook(p, n, fl, prio, en), @@ -124,7 +123,6 @@ public: phasorPhase = new Dumper("/tmp/plot/phasorPhase"); phasorAmpitude = new Dumper("/tmp/plot/phasorAmpitude"); phasorFreq = new Dumper("/tmp/plot/phasorFreq"); - } virtual ~DftHook() @@ -136,7 +134,6 @@ public: delete phasorPhase; delete phasorAmpitude; delete phasorFreq; - } virtual void prepare() @@ -174,7 +171,7 @@ public: smp_memory[i][j] = 0; } - window_multiplier = ceil(((double)sample_rate / window_size) / frequency_resolution);//calculate how much zero padding ist needed for a needed resolution + window_multiplier = ceil(((double)sample_rate / window_size) / frequency_resolution); //calculate how much zero padding ist needed for a needed resolution freq_count = ceil((end_freqency - start_freqency) / frequency_resolution) + 1; @@ -206,7 +203,6 @@ public: calcWindow(window_type); state = State::PREPARED; - } virtual void start() diff --git a/lib/hooks/pps_ts.cpp b/lib/hooks/pps_ts.cpp index 7baf3e8f8..75b043cdf 100644 --- a/lib/hooks/pps_ts.cpp +++ b/lib/hooks/pps_ts.cpp @@ -101,7 +101,7 @@ public: period = 1.0 / fSmps; - info("parsed config thresh=%f signal_index=%d nominal_period=%f", thresh, idx, period); + debug(LOG_HOOK | 5, "parsed config thresh=%f signal_index=%d nominal_period=%f", thresh, idx, period); state = State::PARSED; @@ -121,7 +121,6 @@ public: if (isEdge) { if (isSynced) { - //timeErr += 1.0 - (cntSmps * period); if(tsVirt.tv_nsec > 0.5e9) timeErr += 1.0 - (tsVirt.tv_nsec / 1.0e9); else @@ -133,7 +132,6 @@ public: unsigned int tmp = cntEdges < filtLen ? cntEdges : horizonEst; double cntSmpsAvg = (cntSmpsTotal - filtWin[(cntEdges - tmp) % filtLen]) / tmp; periodEst = 1.0 / cntSmpsAvg; - //info("cntSmpsAvg %f", cntSmpsAvg); periodErrComp = timeErr / (cntSmpsAvg * horizonComp); period = periodEst + periodErrComp; } @@ -147,7 +145,7 @@ public: cntSmps = 0; cntEdges++; - info("Time Error is: %f periodEst %f periodErrComp %f", timeErr, periodEst, periodErrComp); + debug(LOG_HOOK | 5, "Time Error is: %f periodEst %f periodErrComp %f", timeErr, periodEst, periodErrComp); } cntSmps++; diff --git a/lib/nodes/uldaq.cpp b/lib/nodes/uldaq.cpp index 178f824f9..b5724d609 100644 --- a/lib/nodes/uldaq.cpp +++ b/lib/nodes/uldaq.cpp @@ -671,7 +671,7 @@ int uldaq_start(struct vnode *n) /* Start the acquisition */ err = ulAInScan(u->device_handle, 0, 0, (AiInputMode) 0, (Range) 0, u->in.buffer_len / u->in.channel_count, &u->in.sample_rate, u->in.scan_options, u->in.flags, u->in.buffer); - + if (err != ERR_NO_ERROR) { ul_decode_error(err); warning("Failed to start acquisition on DAQ device for node '%s'", node_name(n)); @@ -768,8 +768,6 @@ int uldaq_read(struct vnode *n, struct sample *smps[], unsigned cnt, unsigned *r return cnt; } - - static struct plugin p; __attribute__((constructor(110)))