Changeset 8804 in ntrip


Ignore:
Timestamp:
Sep 20, 2019, 2:51:29 PM (5 years ago)
Author:
stuerze
Message:

small bug fixed with respect to GLONASS message frame time, written into RINEX files

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

Legend:

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

    r8701 r8804  
    442442    out << QString(fmt)
    443443      .arg(_IDOT,    19, 'e', 12)
    444       .arg("",       19, QChar(' '))
     444      .arg(0.0,      19, 'e', 12)
    445445      .arg(_TOEweek, 19, 'e', 12)
    446       .arg("",       19, QChar(' '));
     446      .arg(0.0,      19, 'e', 12);
    447447  }
    448448  else {
     
    459459      .arg(_health, 19, 'e', 12)
    460460      .arg(_TGD,    19, 'e', 12)
    461       .arg("",       19, QChar(' '));
     461      .arg(0.0,     19, 'e', 12);
    462462  }
    463463  else {
     
    476476    out << QString(fmt)
    477477      .arg(tot,          19, 'e', 12)
    478       .arg("",           19, QChar(' '))
     478      .arg(0.0,          19, 'e', 12)
    479479      .arg("",           19, QChar(' '))
    480480      .arg("",           19, QChar(' '));
     
    548548      _TOC.set(year, month, day, hour, min, sec);
    549549      _TOC  = _TOC + _gps_utc;
    550 
     550      int nd = int((_TOC.gpssec())) / (24.0*60.0*60.0);
    551551      if ( readDbl(line, pos[1], fieldLen, _tau  ) ||
    552552           readDbl(line, pos[2], fieldLen, _gamma) ||
     
    555555        return;
    556556      }
    557 
    558       _tau = -_tau;
     557      _tki -= nd * 86400.0;
     558      _tau  = -_tau;
    559559    }
    560560
     
    654654QString t_ephGlo::toString(double version) const {
    655655
    656   QString rnxStr = rinexDateStr(_TOC-_gps_utc, _prn, version);
    657 
     656  QString rnxStr = rinexDateStr(_TOC -_gps_utc, _prn, version);
     657  int nd = int((_TOC - _gps_utc).gpssec()) / (24.0*60.0*60.0);
    658658  QTextStream out(&rnxStr);
    659659
    660660  out << QString("%1%2%3\n")
    661     .arg(-_tau,  19, 'e', 12)
    662     .arg(_gamma, 19, 'e', 12)
    663     .arg(_tki 19, 'e', 12);
     661    .arg(-_tau,           19, 'e', 12)
     662    .arg(_gamma,          19, 'e', 12)
     663    .arg(_tki+nd*86400.0, 19, 'e', 12);
    664664
    665665  QString fmt = version < 3.0 ? "   %1%2%3%4\n" : "    %1%2%3%4\n";
  • branches/BNC_2.12/src/ephemeris.h

    r8496 r8804  
    4040  static QString rinexDateStr(const bncTime& tt, const QString& prnStr, double version);
    4141  static bool earlierTime(const t_eph* eph1, const t_eph* eph2) {return eph1->_TOC < eph2->_TOC;}
     42  static bool prnSort(const t_eph* eph1, const t_eph* eph2) {return eph1->prn() < eph2->prn();}
    4243
    4344 protected:
     
    134135  double  _L2Codes;         // Codes on L2 channel  (not valid for IRNSS)
    135136  double  _TOEweek;
    136   double  _L2PFlag;         // L2 P data flag (not valid for IRNSS)
     137  double  _L2PFlag;         // L2 P data flag (not valid for IRNSS and QZSS)
    137138
    138139  mutable double  _ura;     // SV accuracy
     
    141142  double  _IODC;            // (not valid for IRNSS)
    142143
    143   double  _TOT;             // Transmisstion time
     144  double  _TOT;             // Transmission time
    144145  double  _fitInterval;     // Fit interval (not valid for IRNSS)
    145146
Note: See TracChangeset for help on using the changeset viewer.