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

Last change on this file since 6273 was 6273, checked in by mervart, 9 years ago
File size: 3.9 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 "ephemeris.h"
32#include "satObs.h"
33
34class t_polarPoint;
35
36class t_plotData {
37 public:
38 QVector<double> _mjdX24;
39 QVector<double> _numSat;
40 QVector<double> _PDOP;
41 QVector<double> _L1ok;
42 QVector<double> _L2ok;
43 QVector<double> _L1slip;
44 QVector<double> _L2slip;
45 QVector<double> _L1gap;
46 QVector<double> _L2gap;
47 QVector<double> _eleDeg;
48};
49
50class t_qcObs {
51 public:
52 t_qcObs() {
53 _hasL1 = false;
54 _hasL2 = false;
55 _slipL1 = false;
56 _slipL2 = false;
57 _gapL1 = false;
58 _gapL2 = false;
59 _slotSet = false;
60 _slotNum = 0;
61 _MP1 = 0.0;
62 _MP2 = 0.0;
63 _SNR1 = 0.0;
64 _SNR2 = 0.0;
65 }
66 t_irc set(const t_satObs& obs);
67 double _eleDeg;
68 double _azDeg;
69 bool _hasL1;
70 bool _hasL2;
71 bool _slipL1;
72 bool _slipL2;
73 bool _gapL1;
74 bool _gapL2;
75 bool _slotSet;
76 int _slotNum;
77 double _MP1;
78 double _MP2;
79 double _SNR1;
80 double _SNR2;
81};
82
83class t_qcEpo {
84 public:
85 bncTime _epoTime;
86 double _PDOP;
87 QMap<t_prn, t_qcObs> _qcObs;
88};
89
90class t_qcSat {
91 public:
92 t_qcSat() {
93 _numObs = 0;
94 _numSlipsFlagged = 0;
95 _numSlipsFound = 0;
96 _numGaps = 0;
97 }
98 int _numObs;
99 int _numSlipsFlagged;
100 int _numSlipsFound;
101 int _numGaps;
102};
103
104class t_qcFile {
105 public:
106 t_qcFile() {clear();}
107 void clear() {_qcSat.clear(); _qcEpo.clear();}
108 bncTime _startTime;
109 bncTime _endTime;
110 QString _antennaName;
111 QString _markerName;
112 QString _receiverType;
113 double _interval;
114 QMap<t_prn, t_qcSat> _qcSat;
115 QVector<t_qcEpo> _qcEpo;
116 QVector<t_qcEpo> _qcEpoSampled;
117};
118
119class t_reqcAnalyze : public QThread {
120Q_OBJECT
121
122 public:
123 t_reqcAnalyze(QObject* parent);
124 virtual void run();
125
126 protected:
127 ~t_reqcAnalyze();
128
129 signals:
130 void finished();
131
132 private:
133 void analyzeFile(t_rnxObsFile* obsFile);
134
135 void updateQcSat(const t_qcObs& qcObs, t_qcSat& qcSat);
136
137 t_irc setQcObs(const t_satObs& satObs, t_qcObs& qcObs);
138
139 void preparePlotData(const t_rnxObsFile* obsFile);
140
141 double cmpDOP(const ColumnVector& xyzSta) const;
142
143 void dspSkyPlot(const QString& fileName, const QByteArray& title1,
144 QVector<t_polarPoint*>* data1, const QByteArray& title2,
145 QVector<t_polarPoint*>* data2, const QByteArray& scaleTitle, double maxValue);
146
147 void dspAvailPlot(const QString& fileName, const QByteArray& title);
148
149 void printReport();
150
151 QString _logFileName;
152 QFile* _logFile;
153 QTextStream* _log;
154 QStringList _obsFileNames;
155 QVector<t_rnxObsFile*> _rnxObsFiles;
156 QStringList _navFileNames;
157 QVector<t_eph*> _ephs;
158 t_rnxObsFile::t_rnxEpo* _currEpo;
159 t_qcFile _qcFile;
160 QMutex _mutex;
161};
162
163#endif
Note: See TracBrowser for help on using the repository browser.