source: ntrip/trunk/BNC/src/rinex/reqcanalyze.cpp@ 4696

Last change on this file since 4696 was 4696, checked in by mervart, 12 years ago
File size: 21.0 KB
Line 
1// Part of BNC, a utility for retrieving decoding and
2// converting GNSS data streams from NTRIP broadcasters.
3//
4// Copyright (C) 2007
5// German Federal Agency for Cartography and Geodesy (BKG)
6// http://www.bkg.bund.de
7// Czech Technical University Prague, Department of Geodesy
8// http://www.fsv.cvut.cz
9//
10// Email: euref-ip@bkg.bund.de
11//
12// This program is free software; you can redistribute it and/or
13// modify it under the terms of the GNU General Public License
14// as published by the Free Software Foundation, version 2.
15//
16// This program is distributed in the hope that it will be useful,
17// but WITHOUT ANY WARRANTY; without even the implied warranty of
18// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19// GNU General Public License for more details.
20//
21// You should have received a copy of the GNU General Public License
22// along with this program; if not, write to the Free Software
23// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24
25/* -------------------------------------------------------------------------
26 * BKG NTRIP Client
27 * -------------------------------------------------------------------------
28 *
29 * Class: t_reqcAnalyze
30 *
31 * Purpose: Analyze RINEX Files
32 *
33 * Author: L. Mervart
34 *
35 * Created: 11-Apr-2012
36 *
37 * Changes:
38 *
39 * -----------------------------------------------------------------------*/
40
41#include <iostream>
42#include <iomanip>
43#include <qwt_plot_renderer.h>
44
45#include "reqcanalyze.h"
46#include "bncapp.h"
47#include "bncsettings.h"
48#include "reqcedit.h"
49#include "bncutils.h"
50#include "bncpostprocess.h"
51#include "graphwin.h"
52#include "polarplot.h"
53#include "availplot.h"
54#include "eleplot.h"
55#include "dopplot.h"
56
57using namespace std;
58
59const double SLIPTRESH = 5.0; // cycle-slip threshold (meters)
60
61// Constructor
62////////////////////////////////////////////////////////////////////////////
63t_reqcAnalyze::t_reqcAnalyze(QObject* parent) : QThread(parent) {
64
65 bncSettings settings;
66
67 _logFileName = settings.value("reqcOutLogFile").toString(); expandEnvVar(_logFileName);
68 _logFile = 0;
69 _log = 0;
70 _obsFileNames = settings.value("reqcObsFile").toString().split(",", QString::SkipEmptyParts);
71 _navFileNames = settings.value("reqcNavFile").toString().split(",", QString::SkipEmptyParts);
72
73 _currEpo = 0;
74
75 connect(this, SIGNAL(dspSkyPlot(const QString&,
76 const QByteArray&,
77 QVector<t_polarPoint*>*,
78 const QByteArray&,
79 QVector<t_polarPoint*>*,
80 const QByteArray&, double)),
81 this, SLOT(slotDspSkyPlot(const QString&,
82 const QByteArray&,
83 QVector<t_polarPoint*>*,
84 const QByteArray&,
85 QVector<t_polarPoint*>*,
86 const QByteArray&, double)));
87
88 connect(this, SIGNAL(dspAvailPlot(const QString&, const QByteArray&)),
89 this, SLOT(slotDspAvailPlot(const QString&, const QByteArray&)));
90}
91
92// Destructor
93////////////////////////////////////////////////////////////////////////////
94t_reqcAnalyze::~t_reqcAnalyze() {
95 for (int ii = 0; ii < _rnxObsFiles.size(); ii++) {
96 delete _rnxObsFiles[ii];
97 }
98 for (int ii = 0; ii < _ephs.size(); ii++) {
99 delete _ephs[ii];
100 }
101 delete _log; _log = 0;
102 delete _logFile; _logFile = 0;
103 bncApp* app = (bncApp*) qApp;
104 if ( app->mode() != bncApp::interactive) {
105 app->exit(0);
106 }
107}
108
109//
110////////////////////////////////////////////////////////////////////////////
111void t_reqcAnalyze::slotDspSkyPlot(const QString& fileName,
112 const QByteArray& title1,
113 QVector<t_polarPoint*>* data1,
114 const QByteArray& title2,
115 QVector<t_polarPoint*>* data2,
116 const QByteArray& scaleTitle,
117 double maxValue) {
118
119 bncApp* app = dynamic_cast<bncApp*>(qApp);
120 if (app->GUIenabled()) {
121
122 if (maxValue == 0.0) {
123 if (data1) {
124 for (int ii = 0; ii < data1->size(); ii++) {
125 double val = data1->at(ii)->_value;
126 if (maxValue < val) {
127 maxValue = val;
128 }
129 }
130 }
131 if (data2) {
132 for (int ii = 0; ii < data2->size(); ii++) {
133 double val = data2->at(ii)->_value;
134 if (maxValue < val) {
135 maxValue = val;
136 }
137 }
138 }
139 }
140
141 QwtInterval scaleInterval(0.0, maxValue);
142
143 QVector<QWidget*> plots;
144 if (data1) {
145 t_polarPlot* plot1 = new t_polarPlot(QwtText(title1), scaleInterval,
146 app->mainWindow());
147 plot1->addCurve(data1);
148 plots << plot1;
149 }
150 if (data2) {
151 t_polarPlot* plot2 = new t_polarPlot(QwtText(title2), scaleInterval,
152 app->mainWindow());
153 plot2->addCurve(data2);
154 plots << plot2;
155 }
156
157 t_graphWin* graphWin = new t_graphWin(0, fileName, plots,
158 &scaleTitle, &scaleInterval);
159
160 graphWin->show();
161
162 bncSettings settings;
163 QString dirName = settings.value("reqcPlotDir").toString();
164 if (!dirName.isEmpty()) {
165 QByteArray ext = scaleTitle.isEmpty() ? "_S.png" : "_M.png";
166 graphWin->savePNG(dirName, ext);
167 }
168 }
169}
170
171//
172////////////////////////////////////////////////////////////////////////////
173void t_reqcAnalyze::run() {
174
175 // Open Log File
176 // -------------
177 _logFile = new QFile(_logFileName);
178 if (_logFile->open(QIODevice::WriteOnly | QIODevice::Text)) {
179 _log = new QTextStream();
180 _log->setDevice(_logFile);
181 }
182
183 // Initialize RINEX Observation Files
184 // ----------------------------------
185 t_reqcEdit::initRnxObsFiles(_obsFileNames, _rnxObsFiles, _log);
186
187 // Read Ephemerides
188 // ----------------
189 t_reqcEdit::readEphemerides(_navFileNames, _ephs);
190
191 // Loop over all RINEX Files
192 // -------------------------
193 for (int ii = 0; ii < _rnxObsFiles.size(); ii++) {
194 analyzeFile(_rnxObsFiles[ii]);
195 }
196
197 // Exit
198 // ----
199 emit finished();
200 deleteLater();
201}
202
203//
204////////////////////////////////////////////////////////////////////////////
205void t_reqcAnalyze::analyzeFile(t_rnxObsFile* obsFile) {
206
207 if (_log) {
208 *_log << "\nAnalyze File\n"
209 << "------------\n"
210 << "File: " << obsFile->fileName().toAscii().data() << endl;
211 }
212
213 _allObsMap.clear();
214 _availDataMap.clear();
215
216 // A priori Coordinates
217 // --------------------
218 ColumnVector xyzSta = obsFile->xyz();
219
220 // Loop over all Epochs
221 // --------------------
222 try {
223 unsigned iEpo = 0;
224 while ( (_currEpo = obsFile->nextEpoch()) != 0) {
225
226 if (iEpo == 0) {
227 _obsStat._startTime = _currEpo->tt;
228 _obsStat._antennaName = obsFile->antennaName();
229 _obsStat._markerName = obsFile->markerName();
230 _obsStat._receiverType = obsFile->receiverType();
231 _obsStat._interval = obsFile->interval();
232 }
233 _obsStat._endTime = _currEpo->tt;
234
235 // Loop over all satellites
236 // ------------------------
237 for (unsigned iObs = 0; iObs < _currEpo->rnxSat.size(); iObs++) {
238 const t_rnxObsFile::t_rnxSat& rnxSat = _currEpo->rnxSat[iObs];
239 t_obs obs;
240 t_postProcessing::setObsFromRnx(obsFile, _currEpo, rnxSat, obs);
241
242 if (obs.satSys == 'R') {
243 // TODO: set channel number
244 }
245
246 QString prn = QString("%1%2").arg(obs.satSys)
247 .arg(obs.satNum, 2, 10, QChar('0'));
248
249 t_irc irc = _allObsMap[prn].addObs(obs);
250
251 if (irc == success) {
252 const t_oneObs* newObs = _allObsMap[prn]._oneObsVec.last();
253 if (newObs->_hasL1 && newObs->_hasL2) {
254 _obsStat._prnStat[prn]._numObs += 1;
255 }
256 if (newObs->_slipL1 && newObs->_slipL2) {
257 _obsStat._prnStat[prn]._numSlips += 1;
258 }
259 }
260 }
261
262 prepareObsStat(iEpo, obsFile->interval(), xyzSta);
263 iEpo++;
264
265 } // while (_currEpo)
266 }
267 catch (QString str) {
268 if (_log) {
269 *_log << "Exception " << str << endl;
270 }
271 else {
272 qDebug() << str;
273 }
274 return;
275 }
276
277 // Analyze the Multipath
278 // ---------------------
279 QVector<t_polarPoint*>* dataMP1 = new QVector<t_polarPoint*>;
280 QVector<t_polarPoint*>* dataMP2 = new QVector<t_polarPoint*>;
281 QVector<t_polarPoint*>* dataSNR1 = new QVector<t_polarPoint*>;
282 QVector<t_polarPoint*>* dataSNR2 = new QVector<t_polarPoint*>;
283
284 QMutableMapIterator<QString, t_allObs> it(_allObsMap);
285 while (it.hasNext()) {
286 it.next();
287 QString prn = it.key();
288 preparePlotData(prn, xyzSta, obsFile->interval(),
289 dataMP1, dataMP2, dataSNR1, dataSNR2);
290 }
291
292 emit dspSkyPlot(obsFile->fileName(), "MP1", dataMP1, "MP2", dataMP2,
293 "Meters", 2.0);
294
295 emit dspSkyPlot(obsFile->fileName(), "SNR1", dataSNR1, "SNR2", dataSNR2,
296 "", 9.0);
297
298 QFileInfo fileInfo(obsFile->fileName());
299 QByteArray title = fileInfo.fileName().toAscii();
300
301 emit dspAvailPlot(obsFile->fileName(), title);
302
303 printReport(dataMP1, dataMP2, dataSNR1, dataSNR2);
304}
305
306//
307////////////////////////////////////////////////////////////////////////////
308t_irc t_reqcAnalyze::t_allObs::addObs(const t_obs& obs) {
309
310 t_oneObs* newObs = new t_oneObs(obs.GPSWeek, obs.GPSWeeks);
311 bool okFlag = false;
312
313 // Availability and Slip Flags
314 // ---------------------------
315 double L1 = obs.measdata("L1", 3.0);
316 if (L1 != 0) {
317 newObs->_hasL1 = true;
318 }
319 double L2 = obs.measdata("L2", 3.0);
320 if (L2 != 0) {
321 newObs->_hasL2 = true;
322 }
323 if (obs.slipL1) {
324 newObs->_slipL1 = true;
325 }
326 if (obs.slipL2) {
327 newObs->_slipL2 = true;
328 }
329
330 // Compute the Multipath
331 // ----------------------
332 if (L1 != 0.0 && L2 != 0.0) {
333 double f1 = t_CST::f1(obs.satSys, obs.slotNum);
334 double f2 = t_CST::f2(obs.satSys, obs.slotNum);
335
336 L1 = L1 * t_CST::c / f1;
337 L2 = L2 * t_CST::c / f2;
338
339 double P1 = obs.measdata("C1", 3.0);
340 if (P1 != 0.0) {
341 newObs->_MP1 = P1 - L1 - 2.0*f2*f2/(f1*f1-f2*f2) * (L1 - L2);
342 okFlag = true;
343 }
344 double P2 = obs.measdata("C2", 3.0);
345 if (P2 != 0.0) {
346 newObs->_MP2 = P2 - L2 - 2.0*f1*f1/(f1*f1-f2*f2) * (L1 - L2);
347 okFlag = true;
348 }
349 }
350
351 // Signal-to-Noise
352 // ---------------
353 double S1 = obs.measdata("S1", 3.0);
354 if (S1 != 0.0) {
355 newObs->_SNR1 = floor(S1/6);
356 if (newObs->_SNR1 > 9.0) {
357 newObs->_SNR1 = 9.0;
358 }
359 if (newObs->_SNR1 < 1.0) {
360 newObs->_SNR1 = 1.0;
361 }
362 okFlag = true;
363 }
364 else {
365 if (obs.snrL1 > 0) {
366 newObs->_SNR1 = obs.snrL1;
367 okFlag = true;
368 }
369 }
370 double S2 = obs.measdata("S2", 3.0);
371 if (S2 != 0.0) {
372 newObs->_SNR2 = floor(S2/6);
373 if (newObs->_SNR2 > 9.0) {
374 newObs->_SNR2 = 9.0;
375 }
376 if (newObs->_SNR2 < 1.0) {
377 newObs->_SNR2 = 1.0;
378 }
379 okFlag = true;
380 }
381 else {
382 if (obs.snrL2 > 0) {
383 newObs->_SNR2 = obs.snrL2;
384 okFlag = true;
385 }
386 }
387
388 // Remember the Observation
389 // ------------------------
390 if (okFlag) {
391 _oneObsVec << newObs;
392 return success;
393 }
394 else {
395 delete newObs;
396 return failure;
397 }
398}
399
400//
401////////////////////////////////////////////////////////////////////////////
402void t_reqcAnalyze::prepareObsStat(unsigned iEpo, double obsInterval,
403 const ColumnVector& xyzSta) {
404 const int sampl = int(30.0 / obsInterval);
405 if (iEpo % sampl == 0) {
406 double mjdX24 = _currEpo->tt.mjddec() * 24.0;
407 if (iEpo != 0) {
408 _obsStat._mjdX24 << mjdX24;
409 _obsStat._numSat << _obsStat._numSat.last();
410 _obsStat._PDOP << _obsStat._PDOP.last();
411 }
412 _obsStat._mjdX24 << mjdX24;
413 _obsStat._numSat << _currEpo->rnxSat.size();
414 _obsStat._PDOP << cmpDOP(xyzSta);
415 }
416}
417
418//
419////////////////////////////////////////////////////////////////////////////
420void t_reqcAnalyze::preparePlotData(const QString& prn,
421 const ColumnVector& xyzSta,
422 double obsInterval,
423 QVector<t_polarPoint*>* dataMP1,
424 QVector<t_polarPoint*>* dataMP2,
425 QVector<t_polarPoint*>* dataSNR1,
426 QVector<t_polarPoint*>* dataSNR2) {
427
428 const int chunkStep = int( 30.0 / obsInterval); // chunk step (30 sec)
429 const int numEpo = int(600.0 / obsInterval); // # epochs in one chunk (10 min)
430
431 t_allObs& allObs = _allObsMap[prn];
432
433 // Loop over all Chunks of Data
434 // ----------------------------
435 for (int chunkStart = 0; chunkStart + numEpo < allObs._oneObsVec.size();
436 chunkStart += chunkStep) {
437
438 // Chunk-Specific Variables
439 // ------------------------
440 bncTime currTime;
441 bncTime prevTime;
442 bncTime chunkStartTime;
443 double mjdX24 = 0.0;
444 bool availL1 = false;
445 bool availL2 = false;
446 bool gapL1 = false;
447 bool gapL2 = false;
448 bool slipL1 = false;
449 bool slipL2 = false;
450 bool slipMP = false;
451 double meanMP1 = 0.0;
452 double meanMP2 = 0.0;
453 double minSNR1 = 0.0;
454 double minSNR2 = 0.0;
455 double aziDeg = 0.0;
456 double zenDeg = 0.0;
457 bool zenFlag = false;
458
459 // Loop over all Epochs within one Chunk of Data
460 // ---------------------------------------------
461 for (int ii = 0; ii < numEpo; ii++) {
462 int iEpo = chunkStart + ii;
463 const t_oneObs* oneObs = allObs._oneObsVec[iEpo];
464
465 currTime.set(oneObs->_GPSWeek, oneObs->_GPSWeeks);
466
467 // Compute the Azimuth and Zenith Distance
468 // ---------------------------------------
469 if (ii == 0) {
470 chunkStartTime = currTime;
471 mjdX24 = chunkStartTime.mjddec() * 24.0;
472
473 if (xyzSta.size()) {
474 t_eph* eph = 0;
475 for (int ie = 0; ie < _ephs.size(); ie++) {
476 if (_ephs[ie]->prn() == prn) {
477 eph = _ephs[ie];
478 break;
479 }
480 }
481
482 if (eph) {
483 double xSat, ySat, zSat, clkSat;
484 eph->position(oneObs->_GPSWeek, oneObs->_GPSWeeks,
485 xSat, ySat, zSat, clkSat);
486
487 double rho, eleSat, azSat;
488 topos(xyzSta(1), xyzSta(2), xyzSta(3),
489 xSat, ySat, zSat, rho, eleSat, azSat);
490
491 aziDeg = azSat * 180.0/M_PI;
492 zenDeg = 90.0 - eleSat * 180.0/M_PI;
493 zenFlag = true;
494 }
495 }
496 }
497
498 // Check Interval
499 // --------------
500 if (prevTime.valid()) {
501 double dt = currTime - prevTime;
502 if (dt != obsInterval) {
503 gapL1 = true;
504 gapL2 = true;
505 }
506 }
507 prevTime = currTime;
508
509 // Check L1 and L2 availability
510 // ----------------------------
511 if (oneObs->_hasL1) {
512 availL1 = true;
513 }
514 else {
515 gapL1 = true;
516 }
517 if (oneObs->_hasL2) {
518 availL2 = true;
519 }
520 else {
521 gapL2 = true;
522 }
523
524 // Check Minimal Signal-to-Noise Ratio
525 // -----------------------------------
526 if ( oneObs->_SNR1 > 0 && (minSNR1 == 0 || minSNR1 > oneObs->_SNR1) ) {
527 minSNR1 = oneObs->_SNR1;
528 }
529 if ( oneObs->_SNR2 > 0 && (minSNR2 == 0 || minSNR2 > oneObs->_SNR2) ) {
530 minSNR2 = oneObs->_SNR2;
531 }
532
533 // Check Slip Flags
534 // ----------------
535 if (oneObs->_slipL1) {
536 slipL1 = true;
537 }
538 if (oneObs->_slipL2) {
539 slipL2 = true;
540 }
541
542 // Check Slip Threshold
543 // --------------------
544 if (ii > 0) {
545 double diff1 = oneObs->_MP1 - allObs._oneObsVec[iEpo-1]->_MP1;
546 double diff2 = oneObs->_MP2 - allObs._oneObsVec[iEpo-1]->_MP2;
547 if (fabs(diff1) > SLIPTRESH || fabs(diff2) > SLIPTRESH) {
548 slipMP = true;
549 }
550 }
551
552 meanMP1 += oneObs->_MP1;
553 meanMP2 += oneObs->_MP2;
554 }
555
556 // Availability Plot Data
557 // ----------------------
558 if (availL1) {
559 if (slipL1) {
560 _availDataMap[prn]._L1slip << mjdX24;
561 }
562 else if (gapL1) {
563 _availDataMap[prn]._L1gap << mjdX24;
564 }
565 else {
566 _availDataMap[prn]._L1ok << mjdX24;
567 }
568 }
569 if (availL2) {
570 if (slipL2) {
571 _availDataMap[prn]._L2slip << mjdX24;
572 }
573 else if (gapL2) {
574 _availDataMap[prn]._L2gap << mjdX24;
575 }
576 else {
577 _availDataMap[prn]._L2ok << mjdX24;
578 }
579 }
580 if (zenFlag) {
581 _availDataMap[prn]._eleTim << mjdX24;
582 _availDataMap[prn]._eleDeg << 90.0 - zenDeg;
583 }
584
585 // Signal-to-Noise Ration Plot Data
586 // --------------------------------
587 (*dataSNR1) << (new t_polarPoint(aziDeg, zenDeg, minSNR1));
588 (*dataSNR2) << (new t_polarPoint(aziDeg, zenDeg, minSNR2));
589
590 // Compute the Multipath
591 // ---------------------
592 if (!slipMP) {
593 meanMP1 /= numEpo;
594 meanMP2 /= numEpo;
595 double MP1 = 0.0;
596 double MP2 = 0.0;
597 for (int ii = 0; ii < numEpo; ii++) {
598 int iEpo = chunkStart + ii;
599 const t_oneObs* oneObs = allObs._oneObsVec[iEpo];
600 double diff1 = oneObs->_MP1 - meanMP1;
601 double diff2 = oneObs->_MP2 - meanMP2;
602 MP1 += diff1 * diff1;
603 MP2 += diff2 * diff2;
604 }
605 MP1 = sqrt(MP1 / (numEpo-1));
606 MP2 = sqrt(MP2 / (numEpo-1));
607 (*dataMP1) << (new t_polarPoint(aziDeg, zenDeg, MP1));
608 (*dataMP2) << (new t_polarPoint(aziDeg, zenDeg, MP2));
609 }
610 }
611}
612
613//
614////////////////////////////////////////////////////////////////////////////
615void t_reqcAnalyze::slotDspAvailPlot(const QString& fileName,
616 const QByteArray& title) {
617
618 if (dynamic_cast<bncApp*>(qApp)->GUIenabled()) {
619
620 t_availPlot* plotA = new t_availPlot(0, &_availDataMap);
621 plotA->setTitle(title);
622
623 t_elePlot* plotZ = new t_elePlot(0, &_availDataMap);
624
625 t_dopPlot* plotD = new t_dopPlot(0, &_obsStat);
626
627 QVector<QWidget*> plots;
628 plots << plotA << plotZ << plotD;
629 t_graphWin* graphWin = new t_graphWin(0, fileName, plots, 0, 0);
630
631 int ww = QFontMetrics(graphWin->font()).width('w');
632 graphWin->setMinimumSize(120*ww, 40*ww);
633
634 graphWin->show();
635
636 bncSettings settings;
637 QString dirName = settings.value("reqcPlotDir").toString();
638 if (!dirName.isEmpty()) {
639 QByteArray ext = "_A.png";
640 graphWin->savePNG(dirName, ext);
641 }
642 }
643}
644
645// Compute Dilution of Precision
646////////////////////////////////////////////////////////////////////////////
647double t_reqcAnalyze::cmpDOP(const ColumnVector& xyzSta) const {
648
649 if (xyzSta.size() != 3) {
650 return 0.0;
651 }
652
653 unsigned nSat = _currEpo->rnxSat.size();
654
655 if (nSat < 4) {
656 return 0.0;
657 }
658
659 Matrix AA(nSat, 4);
660
661 unsigned nSatUsed = 0;
662 for (unsigned iSat = 0; iSat < nSat; iSat++) {
663
664 const t_rnxObsFile::t_rnxSat& rnxSat = _currEpo->rnxSat[iSat];
665
666 QString prn = QString("%1%2").arg(rnxSat.satSys)
667 .arg(rnxSat.satNum, 2, 10, QChar('0'));
668
669 t_eph* eph = 0;
670 for (int ie = 0; ie < _ephs.size(); ie++) {
671 if (_ephs[ie]->prn() == prn) {
672 eph = _ephs[ie];
673 break;
674 }
675 }
676 if (eph) {
677 ++nSatUsed;
678 ColumnVector xSat(3);
679 double clkSat;
680 eph->position(_currEpo->tt.gpsw(), _currEpo->tt.gpssec(),
681 xSat(1), xSat(2), xSat(3), clkSat);
682 ColumnVector dx = xSat - xyzSta;
683 double rho = dx.norm_Frobenius();
684 AA(nSatUsed,1) = dx(1) / rho;
685 AA(nSatUsed,2) = dx(2) / rho;
686 AA(nSatUsed,3) = dx(3) / rho;
687 AA(nSatUsed,4) = 1.0;
688 }
689 }
690
691 if (nSatUsed < 4) {
692 return 0.0;
693 }
694
695 AA = AA.Rows(1, nSatUsed);
696
697 SymmetricMatrix QQ;
698 QQ << AA.t() * AA;
699 QQ = QQ.i();
700
701 return sqrt(QQ.trace());
702}
703
704// Finish the report
705////////////////////////////////////////////////////////////////////////////
706void t_reqcAnalyze::printReport(QVector<t_polarPoint*>* dataMP1,
707 QVector<t_polarPoint*>* dataMP2,
708 QVector<t_polarPoint*>* dataSNR1,
709 QVector<t_polarPoint*>* dataSNR2) {
710 if (!_log) {
711 return;
712 }
713
714 *_log << "Marker name: " << _obsStat._markerName << endl
715 << "Receiver: " << _obsStat._receiverType << endl
716 << "Antenna: " << _obsStat._antennaName << endl
717 << "Start time: " << _obsStat._startTime.datestr().c_str() << ' '
718 << _obsStat._startTime.timestr().c_str() << endl
719 << "End time: " << _obsStat._endTime.datestr().c_str() << ' '
720 << _obsStat._endTime.timestr().c_str() << endl
721 << "Interval: " << _obsStat._interval << endl
722 << "# Sat.: " << _obsStat._prnStat.size() << endl;
723
724 int numObs = 0;
725 int numSlips = 0;
726 QMapIterator<QString, t_prnStat> it(_obsStat._prnStat);
727 while (it.hasNext()) {
728 it.next();
729 const t_prnStat& prnStat = it.value();
730 numObs += prnStat._numObs;
731 numSlips += prnStat._numSlips;
732 }
733 *_log << "# Obs.: " << numObs << endl
734 << "# Slips: " << numSlips << endl;
735
736 _log->flush();
737}
Note: See TracBrowser for help on using the repository browser.