source: ntrip/trunk/BNC/src/rinex/reqcanalyze.h@ 4672

Last change on this file since 4672 was 4672, checked in by mervart, 12 years ago
File size: 4.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#ifndef REQCANALYZE_H
26#define REQCANALYZE_H
27
28#include <QtCore>
29#include "rnxobsfile.h"
30#include "rnxnavfile.h"
31#include "RTCM/GPSDecoder.h"
32#include "RTCM3/ephemeris.h"
33
34class t_polarPoint;
35
36class t_availData {
37 public:
38 QVector<double> _L1ok;
39 QVector<double> _L2ok;
40 QVector<double> _L1slip;
41 QVector<double> _L2slip;
42 QVector<double> _L1gap;
43 QVector<double> _L2gap;
44 QVector<double> _eleDeg;
45 QVector<double> _eleTim;
46};
47
48class t_obsStat {
49 public:
50 QVector<double> _mjdX24;
51 QVector<double> _numSat;
52 QVector<double> _PDOP;
53 QVector<double> _GDOP;
54};
55
56class t_reqcAnalyze : public QThread {
57Q_OBJECT
58
59 public:
60 t_reqcAnalyze(QObject* parent);
61
62 protected:
63 ~t_reqcAnalyze();
64
65 signals:
66 void finished();
67 void dspSkyPlot(const QString&,
68 const QByteArray&,
69 QVector<t_polarPoint*>*,
70 const QByteArray&,
71 QVector<t_polarPoint*>*,
72 const QByteArray&, double);
73
74 void dspAvailPlot(const QString&, const QByteArray&);
75
76 private slots:
77 void slotDspSkyPlot(const QString& fileName,
78 const QByteArray& title1,
79 QVector<t_polarPoint*>* data1,
80 const QByteArray& title2,
81 QVector<t_polarPoint*>* data2,
82 const QByteArray& scaleTitle, double maxValue);
83
84 void slotDspAvailPlot(const QString& fileName, const QByteArray& title);
85
86 public:
87 virtual void run();
88
89 private:
90 class t_oneObs {
91 public:
92 t_oneObs(int GPSWeek, double GPSWeeks) {
93 _GPSWeek = GPSWeek;
94 _GPSWeeks = GPSWeeks;
95 _hasL1 = false;
96 _hasL2 = false;
97 _slipL1 = false;
98 _slipL2 = false;
99 _MP1 = 0.0;
100 _MP2 = 0.0;
101 _SNR1 = 0.0;
102 _SNR2 = 0.0;
103 }
104 int _GPSWeek;
105 double _GPSWeeks;
106 bool _hasL1;
107 bool _hasL2;
108 bool _slipL1;
109 bool _slipL2;
110 double _MP1;
111 double _MP2;
112 double _SNR1;
113 double _SNR2;
114 };
115
116 class t_allObs {
117 public:
118 t_allObs() {}
119 ~t_allObs() {
120 for (int ii = 0; ii < _oneObsVec.size(); ii++) {
121 delete _oneObsVec[ii];
122 }
123 }
124 void addObs(const t_obs& obs);
125 QVector<t_oneObs*> _oneObsVec;
126 };
127
128 void analyzeFile(t_rnxObsFile* obsFile);
129 void preparePlotData(const QString& prn, const ColumnVector& xyz,
130 double obsInterval,
131 QVector<t_polarPoint*>* dataMP1,
132 QVector<t_polarPoint*>* dataMP2,
133 QVector<t_polarPoint*>* dataSNR1,
134 QVector<t_polarPoint*>* dataSNR2);
135
136 QString _logFileName;
137 QFile* _logFile;
138 QTextStream* _log;
139 QStringList _obsFileNames;
140 QVector<t_rnxObsFile*> _rnxObsFiles;
141 QStringList _navFileNames;
142 QVector<t_eph*> _ephs;
143 t_rnxObsFile::t_rnxEpo* _currEpo;
144 QMap<QString, t_allObs> _allObsMap;
145 QMap<QString, t_availData> _availDataMap;
146 t_obsStat _obsStat;
147};
148
149#endif
Note: See TracBrowser for help on using the repository browser.