Changeset 9021 in ntrip for branches


Ignore:
Timestamp:
Aug 18, 2020, 10:20:02 PM (4 years ago)
Author:
stuerze
Message:

revert last changes

Location:
branches/BNC_2.12/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/BNC_2.12/src/bnccaster.cpp

    r9018 r9021  
    164164    obs._staID = staID.data();
    165165
    166     // Update/Set Slip Counters
    167     // ------------------------
    168     setSlipCounters(obs);
    169    
    170166    // Output into the socket
    171167    // ----------------------
     
    203199      _lastDumpTime = obs._time - 1.0;
    204200    }
    205    
     201
    206202    // An old observation - throw it away
    207203    // ----------------------------------
     
    564560                   .arg(_miscSockets->size()).toAscii(), true) );
    565561}
    566 
    567 // Set/Update Slip Counters
    568 ////////////////////////////////////////////////////////////////////////////
    569 void bncCaster::setSlipCounters(t_satObs& obs) {
    570 
    571   double minLockTime = -1.0;
    572   for (unsigned ii = 0; ii < obs._obs.size(); ii++) {
    573     const t_frqObs* frqObs = obs._obs[ii];
    574     if (frqObs->_lockTimeValid) {
    575       if (minLockTime == -1.0 || minLockTime < frqObs->_lockTime) {
    576         minLockTime = frqObs->_lockTime;
    577       }
    578     }
    579   }
    580 
    581   if (minLockTime == -1.0) {
    582     return;
    583   }
    584 
    585   QMap<t_prn, double>& hlpMap = _lockTimeMap[obs._staID];
    586   QMap<t_prn, double>::const_iterator it = hlpMap.find(obs._prn);
    587   if (it == hlpMap.end()) {
    588     hlpMap[obs._prn] = minLockTime;
    589     for (unsigned ii = 0; ii < obs._obs.size(); ii++) {
    590       t_frqObs* frqObs = obs._obs[ii];
    591       frqObs->_slipCounter = 0;
    592     }
    593   }
    594   else {
    595     if (hlpMap[obs._prn] < minLockTime) {
    596       hlpMap[obs._prn] = minLockTime;
    597       for (unsigned ii = 0; ii < obs._obs.size(); ii++) {
    598         t_frqObs* frqObs = obs._obs[ii];
    599         frqObs->_slipCounter += 1;
    600         if (frqObs->_slipCounter > 9999) {
    601           frqObs->_slipCounter = 0;
    602         }
    603       }
    604     }
    605   }
    606 }
  • branches/BNC_2.12/src/bnccaster.h

    r9018 r9021  
    6464   static int myWrite(QTcpSocket* sock, const char* buf, int bufLen);
    6565   void reopenOutFile();
    66    void setSlipCounters(t_satObs& obs);
    6766
    6867   QFile*                          _outFile;
     
    8584   QTcpServer*                     _miscServer;
    8685   QList<QTcpSocket*>*             _miscSockets;
    87    QMap<std::string, QMap<t_prn, double> > _lockTimeMap;
    8886};
    8987
Note: See TracChangeset for help on using the changeset viewer.