Changeset 10603 in ntrip for trunk/BNC/src


Ignore:
Timestamp:
Feb 4, 2025, 4:46:08 PM (3 days ago)
Author:
stuerze
Message:

minor changes

Location:
trunk/BNC/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/PPP/pppFilter.cpp

    r10602 r10603  
    266266      }
    267267      if (par) {
    268         if (par->ambResetCandidate()) {
    269           resetAmb(obs->prn(), obsVector, maxOutlierLC, &QSav, &xSav);
    270         } else {
    271           par->setAmbResetCandidate();
    272           obs->setOutlier();
    273         }
     268        resetAmb(obs->prn(), obsVector, maxOutlierLC, &QSav, &xSav);
    274269      }
    275270      else {
  • trunk/BNC/src/ephemeris.cpp

    r10599 r10603  
    106106  return success;
    107107}
     108
     109//
     110//////////////////////////////////////////////////////////////////////////////
     111void t_eph::setType(QString typeStr) {
     112
     113  if (typeStr == "LNAV") {
     114    _type = t_eph::LNAV;
     115  } else if (typeStr == "FDMA") {
     116    _type = t_eph::FDMA;
     117  } else if (typeStr == "FNAV") {
     118    _type = t_eph::FNAV;
     119  } else if (typeStr == "INAV") {
     120    _type = t_eph::INAV;
     121  } else if (typeStr == "D1") {
     122    _type = t_eph::D1;
     123  } else if (typeStr == "D2") {
     124    _type = t_eph::D2;
     125  } else if (typeStr == "SBAS") {
     126    _type = t_eph::SBASL1;
     127  } else if (typeStr == "CNAV") {
     128    _type = t_eph::CNAV;
     129  } else if (typeStr == "CNV1") {
     130    _type = t_eph::CNV1;
     131  } else if (typeStr == "CNV2") {
     132    _type = t_eph::CNV2;
     133  } else if (typeStr == "CNV3") {
     134    _type = t_eph::CNV3;
     135  } else if (typeStr == "L1NV") {
     136    _type = t_eph::L1NV;
     137  } else if (typeStr == "L1OC") {
     138    _type = t_eph::L1OC;
     139  } else if (typeStr == "L3OC") {
     140    _type = t_eph::L3OC;
     141  } else {
     142    _type = t_eph::undefined;
     143  }
     144
     145}
     146
    108147
    109148//
     
    226265// Constructor
    227266//////////////////////////////////////////////////////////////////////////////
    228 t_ephGPS::t_ephGPS(double rnxVersion, const QStringList &lines) {
    229 
     267t_ephGPS::t_ephGPS(double rnxVersion, const QStringList &lines, QString typeStr) {
     268 
     269  setType(typeStr);
     270 
    230271  int nLines = 8; // LNAV
    231 
    232272  // Source RINEX version < 4
    233273  if (type() == t_eph::undefined) {
     
    10091049// Constructor
    10101050//////////////////////////////////////////////////////////////////////////////
    1011 t_ephGlo::t_ephGlo(double rnxVersion, const QStringList &lines) {
     1051t_ephGlo::t_ephGlo(double rnxVersion, const QStringList &lines, const QString typeStr) {
     1052
     1053  setType(typeStr);
    10121054
    10131055  int nLines = 4;
     
    16511693// Constructor
    16521694//////////////////////////////////////////////////////////////////////////////
    1653 t_ephGal::t_ephGal(double rnxVersion, const QStringList &lines) {
     1695t_ephGal::t_ephGal(double rnxVersion, const QStringList &lines, const QString typeStr) {
     1696
     1697  setType(typeStr);
    16541698
    16551699  const int nLines = 8;
     
    21052149// Constructor
    21062150//////////////////////////////////////////////////////////////////////////////
    2107 t_ephSBAS::t_ephSBAS(double rnxVersion, const QStringList &lines) {
     2151t_ephSBAS::t_ephSBAS(double rnxVersion, const QStringList &lines, const QString typeStr) {
     2152
     2153  setType(typeStr);
    21082154
    21092155  const int nLines = 4;
     
    23472393// Constructor
    23482394//////////////////////////////////////////////////////////////////////////////
    2349 t_ephBDS::t_ephBDS(double rnxVersion, const QStringList &lines) {
     2395t_ephBDS::t_ephBDS(double rnxVersion, const QStringList &lines, const QString typeStr) {
     2396
     2397  setType(typeStr);
    23502398
    23512399  int nLines = 8;
  • trunk/BNC/src/ephemeris.h

    r10599 r10603  
    4343  }
    4444  e_type type() const {return _type;}
     45  void setType(QString typeStr);
    4546  t_prn  prn()  const {return _prn;}
    4647  t_irc getCrd(const bncTime& tt, ColumnVector& xc, ColumnVector& vv, bool useCorr) const;
     
    127128    _receptStaID     = "";
    128129  }
    129   t_ephGPS(double rnxVersion, const QStringList& lines);
     130  t_ephGPS(double rnxVersion, const QStringList& lines, const QString typeStr);
    130131  virtual ~t_ephGPS() {}
    131132
     
    282283
    283284  }
    284   t_ephGlo(double rnxVersion, const QStringList& lines);
     285  t_ephGlo(double rnxVersion, const QStringList& lines, const QString typeStr);
    285286  virtual ~t_ephGlo() {}
    286287
     
    411412    _receptStaID     = "";
    412413  };
    413   t_ephGal(double rnxVersion, const QStringList& lines);
     414  t_ephGal(double rnxVersion, const QStringList& lines, const QString typeStr);
    414415  virtual ~t_ephGal() {}
    415416
     
    487488    _receptStaID = "";
    488489  }
    489   t_ephSBAS(double rnxVersion, const QStringList& lines);
     490  t_ephSBAS(double rnxVersion, const QStringList& lines, const QString typeStr);
    490491  virtual ~t_ephSBAS() {}
    491492
     
    573574   _receptStaID       = "";
    574575 }
    575  t_ephBDS(double rnxVersion, const QStringList& lines);
     576 t_ephBDS(double rnxVersion, const QStringList& lines, const QString typeStr);
    576577  virtual ~t_ephBDS() {}
    577578
  • trunk/BNC/src/rinex/reqcedit.cpp

    r10587 r10603  
    724724
    725725    if (isNew) {
    726       if      (eph->system() == t_eph::GPS) {
     726      if      (eph->system() == t_eph::GPS &&
     727               eph->type()   == t_eph::LNAV) {
    727728        ephs.append(new t_ephGPS(*dynamic_cast<t_ephGPS*>(eph)));
    728729      }
    729       else if (eph->system() == t_eph::GLONASS) {
     730      else if (eph->system() == t_eph::GLONASS &&
     731               eph->type()   == t_eph::FDMA_M) {
    730732        ephs.append(new t_ephGlo(*dynamic_cast<t_ephGlo*>(eph)));
    731733      }
    732       else if (eph->system() == t_eph::Galileo) {
     734      else if (eph->system() == t_eph::Galileo &&
     735               eph->type()   ==  t_eph::INAV) {
    733736        ephs.append(new t_ephGal(*dynamic_cast<t_ephGal*>(eph)));
    734737      }
    735       else if (eph->system() == t_eph::QZSS) {
     738      else if (eph->system() == t_eph::QZSS &&
     739               eph->type()   == t_eph::LNAV) {
    736740        ephs.append(new t_ephGPS(*dynamic_cast<t_ephGPS*>(eph)));
    737741      }
    738       else if (eph->system() == t_eph::SBAS) {
     742      else if (eph->system() == t_eph::SBAS &&
     743               eph->type()   == t_eph::SBASL1) {
    739744        ephs.append(new t_ephSBAS(*dynamic_cast<t_ephSBAS*>(eph)));
    740745      }
    741       else if (eph->system() == t_eph::BDS) {
     746      else if (eph->system() == t_eph::BDS &&
     747               (eph->type()  == t_eph::D1 ||
     748                eph->type()  == t_eph::D2)) {
    742749        ephs.append(new t_ephBDS(*dynamic_cast<t_ephBDS*>(eph)));
    743750      }
    744       else if (eph->system() == t_eph::IRNSS) {
     751      else if (eph->system() == t_eph::IRNSS &&
     752               eph->type()   == t_eph::LNAV) {
    745753        ephs.append(new t_ephGPS(*dynamic_cast<t_ephGPS*>(eph)));
    746754      }
  • trunk/BNC/src/rinex/rnxnavfile.cpp

    r10599 r10603  
    149149////////////////////////////////////////////////////////////////////////////
    150150void t_rnxNavFile::read(QTextStream* stream) {
     151  QString navType;
     152  QString prn;
    151153
    152154  while (stream->status() == QTextStream::Ok && !stream->atEnd()) {
    153 
     155    char sys;
    154156    QString line = stream->readLine();
    155157    if (line.isEmpty()) {
    156158      continue;
    157159    }
    158     QString navType;
     160
    159161    QStringList hlp = line.split(QRegExp("\\s+"), Qt::SkipEmptyParts);
    160     QString prn;
    161     char sys;
    162162    QString firstStr = hlp.at(0);
    163163
     
    210210      }
    211211      if (lines2skip) {
    212         for (int ii = 1; ii <= lines2skip; ii++) {
     212        for (int ii = 0; ii < lines2skip; ii++) {
    213213          stream->readLine();
    214214        }
     
    240240        lines << stream->readLine();
    241241      }
    242       eph = new t_ephGPS(version(), lines);
     242      eph = new t_ephGPS(version(), lines, navType);
    243243    }
    244244    else if (sys == 'R') {
     
    250250        lines << stream->readLine();
    251251      }
    252       eph = new t_ephGlo(version(), lines);
     252      eph = new t_ephGlo(version(), lines, navType);
    253253    }
    254254    else if (sys == 'E') {
     
    256256        lines << stream->readLine();
    257257      }
    258       eph = new t_ephGal(version(), lines);
     258      eph = new t_ephGal(version(), lines, navType);
    259259    }
    260260    else if (sys == 'J') {
     
    269269        lines << stream->readLine();
    270270      }
    271       eph = new t_ephGPS(version(), lines);
     271      eph = new t_ephGPS(version(), lines, navType);
    272272    }
    273273    else if (sys== 'S') {
     
    275275        lines << stream->readLine();
    276276      }
    277       eph = new t_ephSBAS(version(), lines);
     277      eph = new t_ephSBAS(version(), lines, navType);
    278278    }
    279279    else if (sys == 'C') {
     
    289289        lines << stream->readLine();
    290290      }
    291       eph = new t_ephBDS(version(), lines);
     291      eph = new t_ephBDS(version(), lines, navType);
    292292    }
    293293    else if (sys == 'I') {
     
    299299        lines << stream->readLine();
    300300      }
    301       eph = new t_ephGPS(version(), lines);
     301      eph = new t_ephGPS(version(), lines, navType);
    302302    }
    303303
Note: See TracChangeset for help on using the changeset viewer.