Changeset 668 in ntrip for trunk/BNC/bncgetthread.cpp


Ignore:
Timestamp:
Jan 30, 2008, 5:32:02 PM (17 years ago)
Author:
weber
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/bncgetthread.cpp

    r659 r668  
    107107  // ----------------
    108108  _inspSegm = settings.value("inspSegm").toInt();
    109   _noticeFail = settings.value("noticeFail").toInt();
    110   _noticeReco = settings.value("noticeReco").toInt();
    111   _noticeScript = settings.value("noticeScript").toString();
    112   expandEnvVar(_noticeScript);
     109  _adviseFail = settings.value("adviseFail").toInt();
     110  _adviseReco = settings.value("adviseReco").toInt();
     111  _adviseScript = settings.value("adviseScript").toString();
     112  expandEnvVar(_adviseScript);
    113113
    114114  // RINEX writer
     
    395395    initPause = _inspSegm;
    396396  }
    397   if ( _noticeFail < 1 && _noticeReco < 1 ) {
     397  if ( _adviseFail < 1 && _adviseReco < 1 ) {
    398398    initPause = 0;
    399399  }
     
    448448            if (numSucc>0) {
    449449              secSucc += _inspSegm;
    450               if (secSucc > _noticeReco * 60) {
    451                 secSucc = _noticeReco * 60 + 1;
     450              if (secSucc > _adviseReco * 60) {
     451                secSucc = _adviseReco * 60 + 1;
    452452              }
    453453              numSucc = 0;
     
    459459              secFail += _inspSegm;
    460460              secSucc = 0;
    461               if (secFail > _noticeFail * 60) {
    462                 secFail = _noticeFail * 60 + 1;
     461              if (secFail > _adviseFail * 60) {
     462                secFail = _adviseFail * 60 + 1;
    463463              }
    464464              if (!_decodePause.isValid()) {
     
    478478            // End corrupt threshold
    479479            // ---------------------
    480             if ( begCorrupt && !endCorrupt && secSucc > _noticeReco * 60 ) {
     480            if ( begCorrupt && !endCorrupt && secSucc > _adviseReco * 60 ) {
    481481              emit(newMessage(_staID + ": End_Corrupted, Recovery threshold exceeded"));
    482482              callScript("End_Corrupted");
     
    489489              // Begin corrupt threshold
    490490              // -----------------------
    491               if ( !begCorrupt && secFail > _noticeFail * 60 ) {
     491              if ( !begCorrupt && secFail > _adviseFail * 60 ) {
    492492                emit(newMessage(_staID + ": Begin_Corrupted, Failure threshold exceeded"));
    493493                callScript("Begin_Corrupted");
     
    505505      // End outage threshold
    506506      // --------------------
    507       if ( _decodeStart.isValid() && _decodeStart.secsTo(QDateTime::currentDateTime()) > _noticeReco * 60 ) {
     507      if ( _decodeStart.isValid() && _decodeStart.secsTo(QDateTime::currentDateTime()) > _adviseReco * 60 ) {
    508508        _decodeStart.setDate(QDate());
    509509        _decodeStart.setTime(QTime());
     
    610610      // Begin outage threshold
    611611      // ----------------------
    612       if ( _decodeStop.isValid() && _decodeStop.secsTo(QDateTime::currentDateTime()) > _noticeFail * 60 ) {
     612      if ( _decodeStop.isValid() && _decodeStop.secsTo(QDateTime::currentDateTime()) > _adviseFail * 60 ) {
    613613        _decodeStop.setDate(QDate());
    614614        _decodeStop.setTime(QTime());
     
    626626}
    627627
    628 // Call notice advisory script   
     628// Call advisory notice script   
    629629////////////////////////////////////////////////////////////////////////////
    630630void bncGetThread::callScript(const char* _comment) {
    631   if (!_noticeScript.isEmpty()) {
     631  if (!_adviseScript.isEmpty()) {
    632632#ifdef WIN32
    633     QProcess::startDetached(_noticeScript, QStringList() << _staID << _comment) ;
     633    QProcess::startDetached(_adviseScript, QStringList() << _staID << _comment) ;
    634634#else
    635     QProcess::startDetached("nohup", QStringList() << _noticeScript << _staID << _comment) ;
     635    QProcess::startDetached("nohup", QStringList() << _adviseScript << _staID << _comment) ;
    636636#endif
    637637  }
Note: See TracChangeset for help on using the changeset viewer.