source: ntrip/trunk/BNC/bncgetthread.h@ 709

Last change on this file since 709 was 709, checked in by weber, 16 years ago

* empty log message *

File size: 3.0 KB
RevLine 
[280]1// Part of BNC, a utility for retrieving decoding and
[464]2// converting GNSS data streams from NTRIP broadcasters.
[280]3//
[464]4// Copyright (C) 2007
[280]5// German Federal Agency for Cartography and Geodesy (BKG)
6// http://www.bkg.bund.de
[464]7// Czech Technical University Prague, Department of Geodesy
[280]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.
[35]24
25#ifndef BNCGETTHREAD_H
26#define BNCGETTHREAD_H
27
28#include <QThread>
29#include <QtNetwork>
[651]30#include <QDateTime>
[35]31
32#include "RTCM/GPSDecoder.h"
[138]33#include "bncconst.h"
[35]34
[408]35class bncRinex;
36
[35]37class bncGetThread : public QThread {
38 Q_OBJECT
39
40 public:
[278]41 bncGetThread(const QUrl& mountPoint,
[366]42 const QByteArray& format,
43 const QByteArray& latitude,
44 const QByteArray& longitude,
45 const QByteArray& nmea, int iMount);
[35]46 ~bncGetThread();
47
[366]48 static QTcpSocket* request(const QUrl& mountPoint, QByteArray& latitude, QByteArray& longitude,
49 QByteArray& nmea, int timeOut, QString& msg);
[88]50
51 QByteArray staID() const {return _staID;}
52
[35]53 signals:
[628]54 void newBytes(QByteArray staID, double nbyte);
55 void newObs(QByteArray staID, bool firstObs, p_obs obs);
56 void error(QByteArray staID);
57 void newMessage(QByteArray msg);
[35]58
59 protected:
60 virtual void run();
[138]61
[35]62 private:
[138]63 t_irc initRun();
64 void message(const QString&);
65 void exit(int exitCode = 0);
66 void tryReconnect();
[658]67 void callScript(const char* _comment);
[136]68 GPSDecoder* _decoder;
[35]69 QTcpSocket* _socket;
[88]70 QUrl _mountPoint;
71 QByteArray _staID;
[255]72 QByteArray _staID_orig;
[59]73 QByteArray _format;
[366]74 QByteArray _latitude;
75 QByteArray _longitude;
76 QByteArray _nmea;
[668]77 QString _adviseScript;
[696]78 QString _begDateCor;
79 QString _begTimeCor;
80 QString _begDateOut;
81 QString _begTimeOut;
82 QString _endDateCor;
83 QString _endTimeCor;
84 QString _endDateOut;
85 QString _endTimeOut;
[686]86 int _obsRate;
[658]87 int _inspSegm;
[668]88 int _adviseFail;
89 int _adviseReco;
[709]90 int _latIntr;
[136]91 int _timeOut;
[138]92 int _nextSleep;
[278]93 int _iMount;
[408]94 int _samplingRate;
95 bncRinex* _rnx;
[651]96 QDateTime _decodeFailure;
[658]97 QDateTime _decodeStart;
98 QDateTime _decodeStop;
99 QDateTime _decodePause;
100 QDateTime _decodeTime;
[699]101 QDateTime _decodeSucc;
[672]102 QMutex _mutex;
[35]103};
104
105#endif
Note: See TracBrowser for help on using the repository browser.