Changeset 2312 in ntrip


Ignore:
Timestamp:
Feb 19, 2010, 4:01:08 PM (14 years ago)
Author:
mervart
Message:

* empty log message *

Location:
trunk/BNC
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/bnccaster.cpp

    r2311 r2312  
    303303// Dump Complete Epochs
    304304////////////////////////////////////////////////////////////////////////////
    305 void bncCaster::dumpEpochs(long minTime, long maxTime) {
     305void bncCaster::dumpEpochs(long minTimeXrate, long maxTimeXrate) {
    306306
    307307  const char begEpoch[] = "BEGEPOCH";
     
    311311  const int endEpochNBytes = sizeof(endEpoch) - 1;
    312312
    313   for (long sec = minTime; sec <= maxTime; sec++) {
     313  for (long secXrate = minTimeXrate; secXrate <= maxTimeXrate; ++secXrate) {
    314314
    315315    bool first = true;
    316     QList<p_obs> allObs = _epochs->values(sec);
     316    QList<p_obs> allObs = _epochs->values(secXrate);
    317317
    318318    QListIterator<p_obs> it(allObs);
     
    320320      p_obs obs = it.next();
    321321
    322       if (_samplingRate == 0 || sec % _samplingRate == 0) {
     322      if (_samplingRate == 0 || (secXrate/_maxRate) % _samplingRate == 0) {
    323323
    324324        if (first) {
     
    401401
    402402      delete obs;
    403       _epochs->remove(sec);
     403      _epochs->remove(secXrate);
    404404      first = false;
    405405    }
     
    415415  // Reread several options
    416416  // ----------------------
    417   _maxRate = settings.value("maxRate").toInt();
    418   if (_maxRate < 1) {
    419     _maxRate = 1;
    420   }
     417  _maxRate = 20;
     418
    421419  _samplingRate  = settings.value("binSampl").toInt();
    422420  _waitTimeXrate = settings.value("waitTime").toInt() * _maxRate;
  • trunk/BNC/bnccaster.h

    r2311 r2312  
    6060
    6161 private:
    62    void dumpEpochs(long minTime, long maxTime);
     62   void dumpEpochs(long minTimeXrate, long maxTimeXrate);
    6363   static int myWrite(QTcpSocket* sock, const char* buf, int bufLen);
    6464
Note: See TracChangeset for help on using the changeset viewer.