Changeset 9789 in ntrip


Ignore:
Timestamp:
Jul 13, 2022, 2:24:35 PM (22 months ago)
Author:
stuerze
Message:

some more changes to consider RINEX Version 4 nav file (EPH key only)

Location:
trunk/BNC/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/ephemeris.cpp

    r9788 r9789  
    20652065      }
    20662066      else if (navType() == t_eph::CNV3) {
     2067        double health;
    20672068        if ( readDbl(line, pos[0], fieldLen, _SISMAI        ) ||
    2068              readDbl(line, pos[1], fieldLen, _health        ) ||
     2069             readDbl(line, pos[1], fieldLen,  health        ) ||
    20692070             readDbl(line, pos[2], fieldLen, _INTEGRITYF_B2b) ||
    20702071             readDbl(line, pos[3], fieldLen, _TGD_B2bI)     )  {
     
    20722073          return;
    20732074        }
     2075        _health = int(health);
    20742076      }
    20752077      else { // D1, D2 or undefined
     
    20902092    // =====================
    20912093    else if ( iLine == 8 ) {
    2092 
     2094      double health;
    20932095      if      (navType() == t_eph::CNV1) {
    20942096        if ( readDbl(line, pos[0], fieldLen, _SISMAI        ) ||
    2095              readDbl(line, pos[1], fieldLen, _health        ) ||
     2097             readDbl(line, pos[1], fieldLen,  health        ) ||
    20962098             readDbl(line, pos[2], fieldLen, _INTEGRITYF_B1C) ||
    20972099             readDbl(line, pos[3], fieldLen, _IODC)     )  {
     
    20992101          return;
    21002102        }
     2103        _health = int(health);
    21012104      }
    21022105      else if (navType() == t_eph::CNV2) {
    21032106        if ( readDbl(line, pos[0], fieldLen, _SISMAI           ) ||
    2104              readDbl(line, pos[1], fieldLen, _health           ) ||
     2107             readDbl(line, pos[1], fieldLen,  health           ) ||
    21052108             readDbl(line, pos[2], fieldLen, _INTEGRITYF_B2aB1C) ||
    21062109             readDbl(line, pos[3], fieldLen, _IODC)            )  {
     
    21082111          return;
    21092112        }
     2113        _health = int(health);
    21102114      }
    21112115      else if (navType() == t_eph::CNV3) {
     
    23132317}
    23142318
     2319
     2320// Health status of SBAS Ephemeris (virtual)
     2321////////////////////////////////////////////////////////////////////////////
     2322unsigned int t_ephBDS::isUnhealthy() const {
     2323
     2324  if (navType() == t_eph::CNV1 ||
     2325      navType() == t_eph::CNV2 ||
     2326      navType() == t_eph::CNV3) {
     2327    return static_cast<unsigned int>(_health);
     2328  }
     2329
     2330  return static_cast<unsigned int>(_SatH1);
     2331
     2332}
     2333
     2334
    23152335// RINEX Format String
    23162336//////////////////////////////////////////////////////////////////////////////
     
    24182438    out << QString(fmt)
    24192439      .arg(_SISMAI,         19, 'e', 12)
    2420       .arg(_health,        19, 'e', 12)
     2440      .arg(double(_health), 19, 'e', 12)
    24212441      .arg(_INTEGRITYF_B2b, 19, 'e', 12)
    24222442      .arg(_TGD_B2bI,       19, 'e', 12);
     
    24432463    out << QString(fmt)
    24442464      .arg(_SISMAI,         19, 'e', 12)
    2445       .arg(_health,        19, 'e', 12)
     2465      .arg(double(_health), 19, 'e', 12)
    24462466      .arg(_INTEGRITYF_B1C, 19, 'e', 12)
    24472467      .arg(_IODC,           19, 'e', 12);
     
    24502470    out << QString(fmt)
    24512471      .arg(_SISMAI,            19, 'e', 12)
    2452       .arg(_health,            19, 'e', 12)
     2472      .arg(double(_health),    19, 'e', 12)
    24532473      .arg(_INTEGRITYF_B2aB1C, 19, 'e', 12)
    24542474      .arg(_IODC,              19, 'e', 12);
  • trunk/BNC/src/ephemeris.h

    r9788 r9789  
    7575 public:
    7676  t_ephGPS() {
    77     _clock_bias       = 0.0;
    78     _clock_drift      = 0.0;
    79     _clock_driftrate  = 0.0;
    80     _IODE             = 0.0;
    81     _Crs              = 0.0;
    82     _Delta_n          = 0.0;
    83     _M0               = 0.0;
    84     _Cuc              = 0.0;
    85     _e                = 0.0;
    86     _Cus              = 0.0;
    87     _sqrt_A           = 0.0;
    88     _TOEsec           = 0.0;
    89     _Cic              = 0.0;
    90     _OMEGA0           = 0.0;
    91     _Cis              = 0.0;
    92     _i0               = 0.0;
    93     _Crc              = 0.0;
    94     _omega            = 0.0;
    95     _OMEGADOT         = 0.0;
    96     _IDOT             = 0.0;
    97     _L2Codes          = 0.0;
    98     _TOEweek          = 0.0;
    99     _L2PFlag          = 0.0;
    100     _ura              = 0.0;
    101     _health           = 0.0;
    102     _TGD              = 0.0;
    103     _IODC             = 0.0;
    104     _TOT              = 0.0;
    105     _fitInterval      = 0.0;
    106     _ADOT             = 0.0;
    107     _top              = 0.0;
    108     _Delta_n_dot      = 0.0;
    109     _URAI_NED0        = 0.0;
    110     _URAI_NED1        = 0.0;
    111     _URAI_NED2        = 0.0;
    112     _URAI_ED          = 0.0;
    113     _ISC_L1CA         = 0.0;
    114     _ISC_L2C          = 0.0;
    115     _ISC_L5I5         = 0.0;
    116     _ISC_L5Q5         = 0.0;
    117     _ISC_L1Cd         = 0.0;
    118     _ISC_L1Cp         = 0.0;
    119     _receptStaID      = "";
     77    _clock_bias      = 0.0;
     78    _clock_drift     = 0.0;
     79    _clock_driftrate = 0.0;
     80    _IODE            = 0.0;
     81    _Crs             = 0.0;
     82    _Delta_n         = 0.0;
     83    _M0              = 0.0;
     84    _Cuc             = 0.0;
     85    _e               = 0.0;
     86    _Cus             = 0.0;
     87    _sqrt_A          = 0.0;
     88    _TOEsec          = 0.0;
     89    _Cic             = 0.0;
     90    _OMEGA0          = 0.0;
     91    _Cis             = 0.0;
     92    _i0              = 0.0;
     93    _Crc             = 0.0;
     94    _omega           = 0.0;
     95    _OMEGADOT        = 0.0;
     96    _IDOT            = 0.0;
     97    _L2Codes         = 0.0;
     98    _TOEweek         = 0.0;
     99    _L2PFlag         = 0.0;
     100    _ura             = 0.0;
     101    _health          = 0.0;
     102    _TGD             = 0.0;
     103    _IODC            = 0.0;
     104    _TOT             = 0.0;
     105    _fitInterval     = 0.0;
     106    _ADOT            = 0.0;
     107    _top             = 0.0;
     108    _Delta_n_dot     = 0.0;
     109   _URAI_NED0        = 0.0;
     110   _URAI_NED1        = 0.0;
     111   _URAI_NED2        = 0.0;
     112   _URAI_ED          = 0.0;
     113   _ISC_L1CA         = 0.0;
     114   _ISC_L2C          = 0.0;
     115   _ISC_L5I5         = 0.0;
     116   _ISC_L5Q5         = 0.0;
     117   _ISC_L1Cd         = 0.0;
     118   _ISC_L1Cp         = 0.0;
     119   _wnop             = 0.0;
     120    _receptStaID     = "";
    120121  }
    121122  t_ephGPS(double rnxVersion, const QStringList& lines);
     
    450451 public:
    451452 t_ephBDS() {
    452    _TOT             = 0.0;
    453    _AODE            = 0;
    454    _AODC            = 0;
    455    _URAI            = 0;
    456    _URA             = 0.0;
    457    _clock_bias      = 0.0;
    458    _clock_drift     = 0.0;
    459    _clock_driftrate = 0.0;
    460    _Crs             = 0.0;
    461    _Delta_n         = 0.0;
    462    _M0              = 0.0;
    463    _Cuc             = 0.0;
    464    _e               = 0.0;
    465    _Cus             = 0.0;
    466    _sqrt_A          = 0.0;
    467    _Cic             = 0.0;
    468    _OMEGA0          = 0.0;
    469    _Cis             = 0.0;
    470    _i0              = 0.0;
    471    _Crc             = 0.0;
    472    _omega           = 0.0;
    473    _OMEGADOT        = 0.0;
    474    _IDOT            = 0.0;
    475    _TGD1            = 0.0;
    476    _TGD2            = 0.0;
    477    _SatH1           = 0.0;
    478    _TOEsec          = 0.0;
    479    _BDTweek         = 0.0;
    480    _receptStaID     = "";
     453   _TOT               = 0.0;
     454   _AODE              = 0;
     455   _AODC              = 0;
     456   _URAI              = 0;
     457   _URA               = 0.0;
     458   _clock_bias        = 0.0;
     459   _clock_drift       = 0.0;
     460   _clock_driftrate   = 0.0;
     461   _Crs               = 0.0;
     462   _Delta_n           = 0.0;
     463   _M0                = 0.0;
     464   _Cuc               = 0.0;
     465   _e                 = 0.0;
     466   _Cus               = 0.0;
     467   _sqrt_A            = 0.0;
     468   _Cic               = 0.0;
     469   _OMEGA0            = 0.0;
     470   _Cis               = 0.0;
     471   _i0                = 0.0;
     472   _Crc               = 0.0;
     473   _omega             = 0.0;
     474   _OMEGADOT          = 0.0;
     475   _IDOT              = 0.0;
     476   _TOEsec            = 0.0;
     477   _BDTweek           = 0.0;
     478   _Delta_n_dot       = 0.0;
     479   _satType           = 0.0;
     480   _top               = 0.0;
     481   _SISAI_oe          = 0.0;
     482   _SISAI_ocb         = 0.0;
     483   _SISAI_oc1         = 0.0;
     484   _SISAI_oc2         = 0.0;
     485   _ISC_B1Cd          = 0.0;
     486   _ISC_B2ad          = 0.0;
     487   _TGD1              = 0.0;
     488   _TGD2              = 0.0;
     489   _TGD_B1Cp          = 0.0;
     490   _TGD_B2ap          = 0.0;
     491   _TGD_B2bI          = 0.0;
     492   _SISMAI            = 0.0;
     493   _SatH1             = 0;
     494   _health            = 0;
     495   _INTEGRITYF_B1C    = 0.0;
     496   _INTEGRITYF_B2aB1C = 0.0;
     497   _INTEGRITYF_B2b    = 0.0;
     498   _IODC              = 0.0;
     499   _IODE              = 0.0;
     500   _receptStaID       = "";
    481501 }
    482502 t_ephBDS(double rnxVersion, const QStringList& lines);
     
    485505  virtual e_type  type() const {return t_eph::BDS;}
    486506  virtual unsigned int IOD() const;
    487   virtual unsigned int  isUnhealthy() const {return static_cast<unsigned int>(_SatH1);}
     507  virtual unsigned int isUnhealthy() const;
    488508  virtual QString toString(double version) const;
    489509
     
    539559
    540560  int     _SatH1;            //
    541   double  _health;           //
     561  int     _health;           //
    542562
    543563  double  _INTEGRITYF_B1C;   // 3 bits word from sf 3
Note: See TracChangeset for help on using the changeset viewer.