Changeset 540 in ntrip


Ignore:
Timestamp:
Oct 23, 2007, 9:11:39 AM (17 years ago)
Author:
mervart
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/bncrinex.cpp

    r539 r540  
    470470
    471471  double sec = double(datTim.time().second()) + fmod(fObs->GPSWeeks,1.0);
    472   _out << datTim.toString(" yy MM dd hh mm ").toAscii().data()
    473        << setw(10) << setprecision(7) << sec
    474        << "  " << 0 << setw(3)  << dumpList.size();
    475 
    476   QSettings settings;
    477 
    478   QListIterator<Observation*> it(dumpList); int iSat = 0;
    479   while (it.hasNext()) {
    480     iSat++;
    481     Observation* ob = it.next();
    482     _out << ob->satSys << setw(2) << ob->satNum;
    483     if (iSat == 12 && it.hasNext()) {
    484       _out << endl << "                                ";
    485       iSat = 0;
    486     }
    487   }
    488   _out << endl;
    489 
    490   it.toFront();
    491   while (it.hasNext()) {
    492     Observation* ob = it.next();
    493 
    494     char lli = ' ';
    495     char snr = ' ';
    496     _out << setw(14) << setprecision(3) << ob->C1 << lli << snr;
    497     _out << setw(14) << setprecision(3) << ob->C2 << lli << snr;
    498     _out << setw(14) << setprecision(3) << ob->P1 << lli << snr;
    499     _out << setw(14) << setprecision(3) << ob->P2 << lli << snr;
    500     _out << setw(14) << setprecision(3) << ob->L1 << lli
    501          << setw(1) << ob->SNR1 << endl;
    502     _out << setw(14) << setprecision(3) << ob->L2 << lli
    503          << setw(1) << ob->SNR2;
    504     _out << setw(14) << setprecision(3) << ob->S1 ;
    505     _out << setw(16) << setprecision(3) << ob->S2 ;
     472
     473  // RINEX Version 3
     474  // ---------------
     475  if (_rinexVers == 3) {
     476    _out << datTim.toString("> yyyy MM dd hh mm ").toAscii().data()
     477         << setw(10) << setprecision(7) << sec
     478         << "  " << 0 << setw(3)  << dumpList.size() << endl;
     479
     480    QListIterator<Observation*> it(dumpList);
     481    while (it.hasNext()) {
     482      Observation* ob = it.next();
     483      _out << ob->satSys << setw(2) << ob->satNum << "  "
     484           << setw(14) << setprecision(3) << ob->P1
     485           << setw(14) << setprecision(3) << ob->L1
     486           << setw(14) << setprecision(3) << ob->S1
     487           << setw(14) << setprecision(3) << ob->P2
     488           << setw(14) << setprecision(3) << ob->L2
     489           << setw(14) << setprecision(3) << ob->S2
     490           << endl;
     491      delete ob;
     492    }
     493  }
     494
     495  // RINEX Version 2
     496  // ---------------
     497  else {
     498    _out << datTim.toString(" yy MM dd hh mm ").toAscii().data()
     499         << setw(10) << setprecision(7) << sec
     500         << "  " << 0 << setw(3)  << dumpList.size();
     501   
     502    QListIterator<Observation*> it(dumpList); int iSat = 0;
     503    while (it.hasNext()) {
     504      iSat++;
     505      Observation* ob = it.next();
     506      _out << ob->satSys << setw(2) << ob->satNum;
     507      if (iSat == 12 && it.hasNext()) {
     508        _out << endl << "                                ";
     509        iSat = 0;
     510      }
     511    }
    506512    _out << endl;
    507 
    508     delete ob;
     513   
     514    it.toFront();
     515    while (it.hasNext()) {
     516      Observation* ob = it.next();
     517   
     518      char lli = ' ';
     519      char snr = ' ';
     520      _out << setw(14) << setprecision(3) << ob->C1 << lli << snr;
     521      _out << setw(14) << setprecision(3) << ob->C2 << lli << snr;
     522      _out << setw(14) << setprecision(3) << ob->P1 << lli << snr;
     523      _out << setw(14) << setprecision(3) << ob->P2 << lli << snr;
     524      _out << setw(14) << setprecision(3) << ob->L1 << lli
     525           << setw(1) << ob->SNR1 << endl;
     526      _out << setw(14) << setprecision(3) << ob->L2 << lli
     527           << setw(1) << ob->SNR2;
     528      _out << setw(14) << setprecision(3) << ob->S1 ;
     529      _out << setw(16) << setprecision(3) << ob->S2 ;
     530      _out << endl;
     531   
     532      delete ob;
     533    }
    509534  }
    510535
Note: See TracChangeset for help on using the changeset viewer.