[2904] | 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 BNCEPHUSER_H
|
---|
| 26 | #define BNCEPHUSER_H
|
---|
| 27 |
|
---|
| 28 | #include <QtCore>
|
---|
| 29 | #include <newmat.h>
|
---|
| 30 |
|
---|
| 31 | #include "bncconst.h"
|
---|
| 32 | #include "bnctime.h"
|
---|
| 33 | #include "RTCM3/ephemeris.h"
|
---|
| 34 |
|
---|
[2911] | 35 | extern "C" {
|
---|
| 36 | #include "clock_orbit_rtcm.h"
|
---|
| 37 | }
|
---|
| 38 |
|
---|
[2904] | 39 | class t_corr {
|
---|
| 40 | public:
|
---|
| 41 | t_corr() {
|
---|
| 42 | raoSet = false;
|
---|
| 43 | dClkSet = false;
|
---|
| 44 | }
|
---|
| 45 | bool ready() {return raoSet && dClkSet;}
|
---|
[2911] | 46 |
|
---|
| 47 | static bool relevantMessageType(int msgType) {
|
---|
| 48 | return ( msgType == COTYPE_GPSCOMBINED ||
|
---|
| 49 | msgType == COTYPE_GLONASSCOMBINED ||
|
---|
| 50 | msgType == COTYPE_GPSORBIT ||
|
---|
| 51 | msgType == COTYPE_GPSCLOCK ||
|
---|
| 52 | msgType == COTYPE_GLONASSORBIT ||
|
---|
| 53 | msgType == COTYPE_GLONASSCLOCK );
|
---|
| 54 | }
|
---|
| 55 |
|
---|
[2912] | 56 | t_irc readLine(const QString& line);
|
---|
[2911] | 57 |
|
---|
[2914] | 58 | QString prn;
|
---|
[2904] | 59 | bncTime tt;
|
---|
| 60 | int iod;
|
---|
| 61 | double dClk;
|
---|
| 62 | double dotDClk;
|
---|
| 63 | double dotDotDClk;
|
---|
| 64 | ColumnVector rao;
|
---|
| 65 | ColumnVector dotRao;
|
---|
| 66 | ColumnVector dotDotRao;
|
---|
| 67 | bool raoSet;
|
---|
| 68 | bool dClkSet;
|
---|
| 69 | };
|
---|
| 70 |
|
---|
| 71 | class bncEphUser : public QObject {
|
---|
| 72 | Q_OBJECT
|
---|
| 73 |
|
---|
| 74 | public:
|
---|
| 75 | bncEphUser();
|
---|
| 76 | ~bncEphUser();
|
---|
| 77 |
|
---|
| 78 | public slots:
|
---|
| 79 | void slotNewEphGPS(gpsephemeris gpseph);
|
---|
| 80 | void slotNewEphGlonass(glonassephemeris gloeph);
|
---|
| 81 | void slotNewEphGalileo(galileoephemeris galeph);
|
---|
| 82 |
|
---|
[2905] | 83 | protected:
|
---|
[2904] | 84 |
|
---|
| 85 | class t_ephPair {
|
---|
| 86 | public:
|
---|
| 87 | t_ephPair() {
|
---|
| 88 | last = 0;
|
---|
| 89 | prev = 0;
|
---|
| 90 | }
|
---|
| 91 | ~t_ephPair() {
|
---|
| 92 | delete last;
|
---|
| 93 | delete prev;
|
---|
| 94 | }
|
---|
| 95 | t_eph* last;
|
---|
| 96 | t_eph* prev;
|
---|
| 97 | };
|
---|
| 98 |
|
---|
| 99 | QMutex _mutex;
|
---|
| 100 | QMap<QString, t_ephPair*> _eph;
|
---|
| 101 | };
|
---|
| 102 |
|
---|
| 103 | #endif
|
---|