Changeset 5810 in ntrip
- Timestamp:
- Aug 6, 2014, 11:34:36 AM (11 years ago)
- Location:
- trunk/BNC/src/PPP
- Files:
-
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/PPP/pppClient.cpp
r5802 r5810 49 49 50 50 #include "pppClient.h" 51 #include " ephpool.h"52 #include " obspool.h"53 #include " satbias.h"51 #include "pppEphPool.h" 52 #include "pppObsPool.h" 53 #include "pppSatBias.h" 54 54 #include "bncconst.h" 55 55 #include "bncutils.h" 56 #include " station.h"56 #include "pppStation.h" 57 57 #include "bncantex.h" 58 #include " filter.h"58 #include "pppFilter.h" 59 59 60 60 using namespace BNC; … … 73 73 // Constructor 74 74 ////////////////////////////////////////////////////////////////////////////// 75 t_pppClient::t_pppClient(const t_ options* opt) {75 t_pppClient::t_pppClient(const t_pppOptions* opt) { 76 76 _output = 0; 77 _opt = new t_ options(*opt);77 _opt = new t_pppOptions(*opt); 78 78 _log = new ostringstream(); 79 _ephPool = new t_ ephPool();80 _obsPool = new t_ obsPool();81 _staRover = new t_ station();82 _filter = new t_ filter();79 _ephPool = new t_pppEphPool(); 80 _obsPool = new t_pppObsPool(); 81 _staRover = new t_pppStation(); 82 _filter = new t_pppFilter(); 83 83 _tides = new t_tides(); 84 84 … … 359 359 // 360 360 ////////////////////////////////////////////////////////////////////////////// 361 t_irc t_pppClient::cmpModel(t_ station* station, const ColumnVector& xyzc,361 t_irc t_pppClient::cmpModel(t_pppStation* station, const ColumnVector& xyzc, 362 362 vector<t_satObs*>& obsVector) { 363 363 -
trunk/BNC/src/PPP/pppClient.h
r5802 r5810 4 4 #include <sstream> 5 5 #include <vector> 6 #include "ppp .h"6 #include "pppInclude.h" 7 7 #include "ephemeris.h" 8 #include " options.h"8 #include "pppOptions.h" 9 9 #include "pppModel.h" 10 10 … … 13 13 namespace BNC { 14 14 15 class t_ ephPool;16 class t_ obsPool;15 class t_pppEphPool; 16 class t_pppObsPool; 17 17 class t_satObs; 18 class t_ station;19 class t_ filter;18 class t_pppStation; 19 class t_pppFilter; 20 20 21 21 class t_pppClient { 22 22 public: 23 t_pppClient(const t_ options* opt);23 t_pppClient(const t_pppOptions* opt); 24 24 ~t_pppClient(); 25 25 … … 30 30 void processEpoch(const std::vector<t_pppSatObs*>& pppSatObs, t_output* output); 31 31 32 const t_ ephPool* ephPool() const {return _ephPool;}33 const t_ obsPool* obsPool() const {return _obsPool;}32 const t_pppEphPool* ephPool() const {return _ephPool;} 33 const t_pppObsPool* obsPool() const {return _obsPool;} 34 34 const bncAntex* antex() const {return _antex;} 35 const t_ station* staRover() const {return _staRover;}35 const t_pppStation* staRover() const {return _staRover;} 36 36 double offGG() const {return _offGG;} 37 37 38 38 std::ostringstream& log() {return *_log;} 39 const t_ options* opt() const {return _opt;}39 const t_pppOptions* opt() const {return _opt;} 40 40 41 41 static void bancroft(const Matrix& BBpass, ColumnVector& pos); … … 49 49 t_irc prepareObs(const std::vector<t_pppSatObs*>& pppSatObs, 50 50 std::vector<t_satObs*>& obsVector, bncTime& epoTime); 51 t_irc cmpModel(t_ station* station, const ColumnVector& xyzc,51 t_irc cmpModel(t_pppStation* station, const ColumnVector& xyzc, 52 52 std::vector<t_satObs*>& obsVector); 53 53 t_irc cmpBancroft(const bncTime& epoTime, std::vector<t_satObs*>& obsVector, … … 56 56 57 57 t_output* _output; 58 t_ ephPool* _ephPool;59 t_ obsPool* _obsPool;58 t_pppEphPool* _ephPool; 59 t_pppObsPool* _obsPool; 60 60 bncTime _epoTimeRover; 61 t_ station* _staRover;61 t_pppStation* _staRover; 62 62 bncAntex* _antex; 63 t_ filter* _filter;63 t_pppFilter* _filter; 64 64 double _offGG; 65 65 std::vector<t_satObs*> _obsRover; 66 66 std::ostringstream* _log; 67 t_ options* _opt;67 t_pppOptions* _opt; 68 68 t_tides* _tides; 69 69 }; -
trunk/BNC/src/PPP/pppEphPool.cpp
r5809 r5810 40 40 41 41 #include <iostream> 42 #include " ephpool.h"43 #include "ppp .h"42 #include "pppEphPool.h" 43 #include "pppInclude.h" 44 44 #include "pppClient.h" 45 45 … … 49 49 // 50 50 ///////////////////////////////////////////////////////////////////////////// 51 void t_ ephPool::putEphemeris(t_eph* eph) {51 void t_pppEphPool::putEphemeris(t_eph* eph) { 52 52 if (eph && eph->ok()) { 53 53 _satEphPool[eph->prn().toInt()].putEphemeris(_maxQueueSize, eph); … … 60 60 // 61 61 ///////////////////////////////////////////////////////////////////////////// 62 void t_ ephPool::putOrbCorrection(t_orbCorr* corr) {62 void t_pppEphPool::putOrbCorrection(t_orbCorr* corr) { 63 63 if (corr) { 64 64 _satEphPool[corr->prn().toInt()].putOrbCorrection(corr); … … 68 68 // 69 69 ///////////////////////////////////////////////////////////////////////////// 70 void t_ ephPool::putClkCorrection(t_clkCorr* corr) {70 void t_pppEphPool::putClkCorrection(t_clkCorr* corr) { 71 71 if (corr) { 72 72 _satEphPool[corr->prn().toInt()].putClkCorrection(corr); … … 76 76 // 77 77 ///////////////////////////////////////////////////////////////////////////// 78 t_irc t_ ephPool::getCrd(const t_prn& prn, const bncTime& tt,78 t_irc t_pppEphPool::getCrd(const t_prn& prn, const bncTime& tt, 79 79 ColumnVector& xc, ColumnVector& vv) const { 80 80 return _satEphPool[prn.toInt()].getCrd(tt, xc, vv); … … 83 83 // 84 84 ///////////////////////////////////////////////////////////////////////////// 85 int t_ ephPool::getChannel(const t_prn& prn) const {85 int t_pppEphPool::getChannel(const t_prn& prn) const { 86 86 return _satEphPool[prn.toInt()].getChannel(); 87 87 } … … 89 89 // 90 90 ///////////////////////////////////////////////////////////////////////////// 91 void t_ ephPool::t_satEphPool::putEphemeris(unsigned maxQueueSize, t_eph* eph) {91 void t_pppEphPool::t_satEphPool::putEphemeris(unsigned maxQueueSize, t_eph* eph) { 92 92 if (_ephs.empty() || eph->isNewerThan(_ephs.front())) { 93 93 _ephs.push_front(eph); … … 104 104 // 105 105 ///////////////////////////////////////////////////////////////////////////// 106 void t_ ephPool::t_satEphPool::putOrbCorrection(t_orbCorr* corr) {106 void t_pppEphPool::t_satEphPool::putOrbCorrection(t_orbCorr* corr) { 107 107 for (unsigned ii = 0; ii < _ephs.size(); ii++) { 108 108 t_eph* eph = _ephs[ii]; … … 117 117 // 118 118 ///////////////////////////////////////////////////////////////////////////// 119 void t_ ephPool::t_satEphPool::putClkCorrection(t_clkCorr* corr) {119 void t_pppEphPool::t_satEphPool::putClkCorrection(t_clkCorr* corr) { 120 120 for (unsigned ii = 0; ii < _ephs.size(); ii++) { 121 121 t_eph* eph = _ephs[ii]; … … 129 129 // 130 130 ///////////////////////////////////////////////////////////////////////////// 131 t_irc t_ ephPool::t_satEphPool::getCrd(const bncTime& tt, ColumnVector& xc,131 t_irc t_pppEphPool::t_satEphPool::getCrd(const bncTime& tt, ColumnVector& xc, 132 132 ColumnVector& vv) const { 133 133 for (unsigned ii = 0; ii < _ephs.size(); ii++) { … … 149 149 // 150 150 ///////////////////////////////////////////////////////////////////////////// 151 int t_ ephPool::t_satEphPool::getChannel() const {151 int t_pppEphPool::t_satEphPool::getChannel() const { 152 152 if (_ephs.size() > 0) { 153 153 return _ephs[0]->slotNum(); -
trunk/BNC/src/PPP/pppEphPool.h
r5809 r5810 3 3 4 4 #include <deque> 5 #include "ppp .h"5 #include "pppInclude.h" 6 6 #include "bnctime.h" 7 7 #include "ephemeris.h" … … 9 9 namespace BNC { 10 10 11 class t_ ephPool {11 class t_pppEphPool { 12 12 public: 13 t_ ephPool(unsigned maxQueueSize = 3) {13 t_pppEphPool(unsigned maxQueueSize = 3) { 14 14 _maxQueueSize = maxQueueSize; 15 15 } 16 ~t_ ephPool() {};16 ~t_pppEphPool() {}; 17 17 18 18 void putEphemeris(t_eph* eph); -
trunk/BNC/src/PPP/pppFilter.cpp
r5809 r5810 6 6 #include <newmatap.h> 7 7 8 #include " filter.h"8 #include "pppFilter.h" 9 9 #include "bncutils.h" 10 #include "p arlist.h"11 #include " obspool.h"12 #include " station.h"10 #include "pppParlist.h" 11 #include "pppObsPool.h" 12 #include "pppStation.h" 13 13 #include "pppClient.h" 14 14 … … 18 18 // Constructor 19 19 //////////////////////////////////////////////////////////////////////////// 20 t_ filter::t_filter() {20 t_pppFilter::t_pppFilter() { 21 21 _parlist = 0; 22 22 } … … 24 24 // Destructor 25 25 //////////////////////////////////////////////////////////////////////////// 26 t_ filter::~t_filter() {26 t_pppFilter::~t_pppFilter() { 27 27 delete _parlist; 28 28 } … … 30 30 // Process Single Epoch 31 31 //////////////////////////////////////////////////////////////////////////// 32 t_irc t_ filter::processEpoch(t_obsPool* obsPool) {32 t_irc t_pppFilter::processEpoch(t_pppObsPool* obsPool) { 33 33 34 34 _numSat = 0; 35 35 36 36 if (!_parlist) { 37 _parlist = new t_p arlist();37 _parlist = new t_pppParlist(); 38 38 } 39 39 40 40 // Vector of all Observations 41 41 // -------------------------- 42 t_ obsPool::t_epoch* epoch = obsPool->lastEpoch();42 t_pppObsPool::t_epoch* epoch = obsPool->lastEpoch(); 43 43 if (!epoch) { 44 44 return failure; … … 76 76 // -------------- 77 77 _parlist->set(_epoTime, ambLCs, obsVector); 78 const vector<t_p aram*>& params = _parlist->params();78 const vector<t_pppParam*>& params = _parlist->params(); 79 79 80 80 // Status Vector, Variance-Covariance Matrix … … 88 88 89 89 for (unsigned ii = 0; ii < params.size(); ii++) { 90 const t_p aram* par1 = params[ii];90 const t_pppParam* par1 = params[ii]; 91 91 92 92 _x0[ii] = par1->x0(); … … 100 100 _xFlt[ii] = xFltOld[iOld]; 101 101 for (unsigned jj = 0; jj < ii; jj++) { 102 const t_p aram* par2 = params[jj];102 const t_pppParam* par2 = params[jj]; 103 103 int jOld = par2->indexOld(); 104 104 if (jOld >= 0) { … … 127 127 // Process Selected LCs 128 128 //////////////////////////////////////////////////////////////////////////// 129 t_irc t_ filter::processLC(const vector<t_lc::type>& LCs,129 t_irc t_pppFilter::processLC(const vector<t_lc::type>& LCs, 130 130 vector<t_satObs*>& obsVector) { 131 131 … … 141 141 SymmetricMatrix QSav = _QFlt; 142 142 string epoTimeStr = string(_epoTime); 143 const vector<t_p aram*>& params = _parlist->params();143 const vector<t_pppParam*>& params = _parlist->params(); 144 144 unsigned maxObs = obsVector.size() * LCs.size(); 145 145 … … 172 172 usedTypes.push_back(tLC); 173 173 for (unsigned iPar = 0; iPar < params.size(); iPar++) { 174 const t_p aram* par = params[iPar];174 const t_pppParam* par = params[iPar]; 175 175 AA[iObs][iPar] = par->partial(_epoTime, obs, tLC); 176 176 } … … 238 238 if (maxOutlierIndex > -1) { 239 239 t_satObs* obs = usedObs[maxOutlierIndex]; 240 t_p aram* par = 0;240 t_pppParam* par = 0; 241 241 LOG << epoTimeStr << " Outlier " << t_lc::toString(maxOutlierLC) << ' ' 242 242 << obs->prn().toString() << ' ' 243 243 << setw(8) << setprecision(4) << maxOutlier << endl; 244 244 for (unsigned iPar = 0; iPar < params.size(); iPar++) { 245 t_p aram* hlp = params[iPar];246 if (hlp->type() == t_p aram::amb && hlp->prn() == obs->prn() &&245 t_pppParam* hlp = params[iPar]; 246 if (hlp->type() == t_pppParam::amb && hlp->prn() == obs->prn() && 247 247 hlp->tLC() == usedTypes[maxOutlierIndex]) { 248 248 par = hlp; … … 289 289 // Cycle-Slip Detection 290 290 //////////////////////////////////////////////////////////////////////////// 291 t_irc t_ filter::detectCycleSlips(const vector<t_lc::type>& LCs,291 t_irc t_pppFilter::detectCycleSlips(const vector<t_lc::type>& LCs, 292 292 const vector<t_satObs*>& obsVector) { 293 293 294 294 const double SLIP = 20.0; // slip threshold 295 295 string epoTimeStr = string(_epoTime); 296 const vector<t_p aram*>& params = _parlist->params();296 const vector<t_pppParam*>& params = _parlist->params(); 297 297 298 298 for (unsigned ii = 0; ii < LCs.size(); ii++) { … … 336 336 ColumnVector AA(params.size()); 337 337 for (unsigned iPar = 0; iPar < params.size(); iPar++) { 338 const t_p aram* par = params[iPar];338 const t_pppParam* par = params[iPar]; 339 339 AA[iPar] = par->partial(_epoTime, obs, tLC); 340 340 } … … 358 358 // Reset Ambiguity Parameter (cycle slip) 359 359 //////////////////////////////////////////////////////////////////////////// 360 t_irc t_ filter::resetAmb(t_prn prn, const vector<t_satObs*>& obsVector,360 t_irc t_pppFilter::resetAmb(t_prn prn, const vector<t_satObs*>& obsVector, 361 361 SymmetricMatrix* QSav, ColumnVector* xSav) { 362 362 t_irc irc = failure; 363 vector<t_p aram*>& params = _parlist->params();363 vector<t_pppParam*>& params = _parlist->params(); 364 364 for (unsigned iPar = 0; iPar < params.size(); iPar++) { 365 t_p aram* par = params[iPar];366 if (par->type() == t_p aram::amb && par->prn() == prn) {365 t_pppParam* par = params[iPar]; 366 if (par->type() == t_pppParam::amb && par->prn() == prn) { 367 367 int ind = par->indexNew(); 368 368 t_lc::type tLC = par->tLC(); 369 369 LOG << string(_epoTime) << " RESET " << par->toString() << endl; 370 delete par; par = new t_p aram(t_param::amb, prn, tLC, &obsVector);370 delete par; par = new t_pppParam(t_pppParam::amb, prn, tLC, &obsVector); 371 371 par->setIndex(ind); 372 372 params[iPar] = par; … … 395 395 // Compute various DOP Values 396 396 //////////////////////////////////////////////////////////////////////////// 397 void t_ filter::cmpDOP(const std::vector<t_lc::type>& LCs, const Matrix& AA) {397 void t_pppFilter::cmpDOP(const std::vector<t_lc::type>& LCs, const Matrix& AA) { 398 398 399 399 _dop.reset(); -
trunk/BNC/src/PPP/pppFilter.h
r5809 r5810 4 4 #include <vector> 5 5 #include <newmat.h> 6 #include "ppp .h"7 #include "p arlist.h"6 #include "pppInclude.h" 7 #include "pppParlist.h" 8 8 #include "bnctime.h" 9 9 #include "t_prn.h" … … 11 11 namespace BNC { 12 12 13 class t_p arlist;14 class t_ obsPool;13 class t_pppParlist; 14 class t_pppObsPool; 15 15 class t_satObs; 16 16 17 class t_ filter {17 class t_pppFilter { 18 18 public: 19 t_ filter();20 ~t_ filter();19 t_pppFilter(); 20 ~t_pppFilter(); 21 21 22 t_irc processEpoch(t_ obsPool* obsPool);22 t_irc processEpoch(t_pppObsPool* obsPool); 23 23 24 24 const ColumnVector& x() const {return _xFlt;} … … 61 61 62 62 bncTime _epoTime; 63 t_p arlist* _parlist;63 t_pppParlist* _parlist; 64 64 SymmetricMatrix _QFlt; 65 65 ColumnVector _xFlt; -
trunk/BNC/src/PPP/pppMain.cpp
r5795 r5810 70 70 readOptions(); 71 71 72 QListIterator<t_ options*> iOpt(_options);72 QListIterator<t_pppOptions*> iOpt(_options); 73 73 while (iOpt.hasNext()) { 74 const t_ options* opt = iOpt.next();75 t_ppp Thread* pppThread = new t_pppThread(opt);76 ppp Thread->start();77 _ppp Threads << pppThread;74 const t_pppOptions* opt = iOpt.next(); 75 t_pppInclude.hread* pppInclude.hread = new t_pppInclude.hread(opt); 76 pppInclude.hread->start(); 77 _pppInclude.hreads << pppInclude.hread; 78 78 _running = true; 79 79 } … … 92 92 } 93 93 94 QListIterator<t_ppp Thread*> it(_pppThreads);94 QListIterator<t_pppInclude.hread*> it(_pppInclude.hreads); 95 95 while (it.hasNext()) { 96 t_ppp Thread* pppThread = it.next();97 ppp Thread->exit();98 } 99 _ppp Threads.clear();100 101 QListIterator<t_ options*> iOpt(_options);96 t_pppInclude.hread* pppInclude.hread = it.next(); 97 pppInclude.hread->exit(); 98 } 99 _pppInclude.hreads.clear(); 100 101 QListIterator<t_pppOptions*> iOpt(_options); 102 102 while (iOpt.hasNext()) { 103 103 delete iOpt.next(); … … 112 112 void t_pppMain::readOptions() { 113 113 114 QListIterator<t_ options*> iOpt(_options);114 QListIterator<t_pppOptions*> iOpt(_options); 115 115 while (iOpt.hasNext()) { 116 116 delete iOpt.next(); … … 143 143 } 144 144 145 t_ options* opt = new t_options();145 t_pppOptions* opt = new t_pppOptions(); 146 146 147 147 opt->_realTime = realTime; -
trunk/BNC/src/PPP/pppMain.h
r5736 r5810 3 3 4 4 #include <QtCore> 5 #include " options.h"6 #include "ppp Thread.h"5 #include "pppOptions.h" 6 #include "pppInclude.hread.h" 7 7 8 8 namespace BNC { … … 18 18 void readOptions(); 19 19 20 QList<t_ options*> _options;21 QList<t_ppp Thread*> _pppThreads;20 QList<t_pppOptions*> _options; 21 QList<t_pppInclude.hread*> _pppInclude.hreads; 22 22 QString _logFile; 23 23 QString _nmeaFile; -
trunk/BNC/src/PPP/pppObsPool.cpp
r5809 r5810 39 39 * -----------------------------------------------------------------------*/ 40 40 41 #include " obspool.h"41 #include "pppObsPool.h" 42 42 43 43 using namespace BNC; … … 46 46 // Constructor 47 47 ///////////////////////////////////////////////////////////////////////////// 48 t_ obsPool::t_epoch::t_epoch(const bncTime& epoTime, vector<t_satObs*>& obsVector) {48 t_pppObsPool::t_epoch::t_epoch(const bncTime& epoTime, vector<t_satObs*>& obsVector) { 49 49 _epoTime = epoTime; 50 50 for (unsigned ii = 0; ii < obsVector.size(); ii++) { … … 56 56 // Destructor 57 57 ///////////////////////////////////////////////////////////////////////////// 58 t_ obsPool::t_epoch::~t_epoch() {58 t_pppObsPool::t_epoch::~t_epoch() { 59 59 for (unsigned ii = 0; ii < _obsVector.size(); ii++) { 60 60 delete _obsVector[ii]; … … 64 64 // Constructor 65 65 ///////////////////////////////////////////////////////////////////////////// 66 t_ obsPool::t_obsPool() {66 t_pppObsPool::t_pppObsPool() { 67 67 for (unsigned ii = 0; ii <= t_prn::MAXPRN; ii++) { 68 68 _satBiases[ii] = 0; … … 72 72 // Destructor 73 73 ///////////////////////////////////////////////////////////////////////////// 74 t_ obsPool::~t_obsPool() {74 t_pppObsPool::~t_pppObsPool() { 75 75 for (unsigned ii = 0; ii <= t_prn::MAXPRN; ii++) { 76 76 delete _satBiases[ii]; … … 84 84 // 85 85 ///////////////////////////////////////////////////////////////////////////// 86 void t_ obsPool::putBiases(t_satBias* satBias) {86 void t_pppObsPool::putBiases(t_satBias* satBias) { 87 87 int iPrn = satBias->prn().toInt(); 88 88 delete _satBiases[iPrn]; … … 92 92 // 93 93 ///////////////////////////////////////////////////////////////////////////// 94 void t_ obsPool::putEpoch(const bncTime& epoTime, vector<t_satObs*>& obsVector) {94 void t_pppObsPool::putEpoch(const bncTime& epoTime, vector<t_satObs*>& obsVector) { 95 95 const unsigned MAXSIZE = 2; 96 96 _epochs.push_back(new t_epoch(epoTime, obsVector)); -
trunk/BNC/src/PPP/pppObsPool.h
r5809 r5810 5 5 #include <deque> 6 6 #include "satobs.h" 7 #include " satbias.h"7 #include "pppSatBias.h" 8 8 #include "bnctime.h" 9 9 10 10 namespace BNC { 11 11 12 class t_ obsPool {12 class t_pppObsPool { 13 13 public: 14 14 … … 25 25 }; 26 26 27 t_ obsPool();28 ~t_ obsPool();27 t_pppObsPool(); 28 ~t_pppObsPool(); 29 29 void putBiases(t_satBias* satBias); 30 30 -
trunk/BNC/src/PPP/pppOptions.cpp
r5809 r5810 27 27 * ------------------------------------------------------------------------- 28 28 * 29 * Class: t_ options29 * Class: t_pppOptions 30 30 * 31 31 * Purpose: Options for PPP client … … 40 40 41 41 #include <newmatio.h> 42 #include " options.h"42 #include "pppOptions.h" 43 43 44 44 using namespace BNC; … … 47 47 // Constructor 48 48 ////////////////////////////////////////////////////////////////////////////// 49 t_ options::t_options() {49 t_pppOptions::t_pppOptions() { 50 50 _xyzAprRover.ReSize(3); _xyzAprRover = 0.0; 51 51 _ellAprRover.ReSize(3); _ellAprRover = 0.0; … … 55 55 // Destructor 56 56 ////////////////////////////////////////////////////////////////////////////// 57 t_ options::~t_options() {57 t_pppOptions::~t_pppOptions() { 58 58 } 59 59 60 60 // 61 61 ////////////////////////////////////////////////////////////////////////////// 62 bool t_ options::dualFreqRequired() const {62 bool t_pppOptions::dualFreqRequired() const { 63 63 return true; 64 64 } … … 66 66 // 67 67 ////////////////////////////////////////////////////////////////////////////// 68 bool t_ options::biasRequired() const {68 bool t_pppOptions::biasRequired() const { 69 69 return false; 70 70 } … … 72 72 // 73 73 ////////////////////////////////////////////////////////////////////////////// 74 bool t_ options::corrRequired() const {74 bool t_pppOptions::corrRequired() const { 75 75 return false; 76 76 } … … 78 78 // 79 79 ////////////////////////////////////////////////////////////////////////////// 80 bool t_ options::useGlonass() const {80 bool t_pppOptions::useGlonass() const { 81 81 return (_lcGLONASS.size() > 0); 82 82 } … … 84 84 // 85 85 ////////////////////////////////////////////////////////////////////////////// 86 bool t_ options::xyzAprRoverSet() const {86 bool t_pppOptions::xyzAprRoverSet() const { 87 87 return (_xyzAprRover[0] != 0.0 || _xyzAprRover[1] != 0.0 || _xyzAprRover[2] != 0.0); 88 88 } … … 90 90 // 91 91 ////////////////////////////////////////////////////////////////////////////// 92 bool t_ options::estTropo() const {92 bool t_pppOptions::estTropo() const { 93 93 return (_sigTropo > 0.0 || _noiseTropo > 0.0); 94 94 } … … 96 96 // 97 97 ////////////////////////////////////////////////////////////////////////////// 98 vector<t_lc::type> t_ options::LCs() const {98 vector<t_lc::type> t_pppOptions::LCs() const { 99 99 100 100 vector<t_lc::type> allLCs = _lcGPS; … … 131 131 // 132 132 ////////////////////////////////////////////////////////////////////////////// 133 double t_ options::maxRes(t_lc::type /* tLC */) const {133 double t_pppOptions::maxRes(t_lc::type /* tLC */) const { 134 134 return _maxResC1; 135 135 } -
trunk/BNC/src/PPP/pppOptions.h
r5809 r5810 5 5 #include <vector> 6 6 #include <newmat.h> 7 #include "ppp .h"7 #include "pppInclude.h" 8 8 9 9 namespace BNC { 10 10 11 class t_ options {11 class t_pppOptions { 12 12 public: 13 13 class t_optBias { … … 18 18 }; 19 19 20 t_ options();21 ~t_ options();20 t_pppOptions(); 21 ~t_pppOptions(); 22 22 bool dualFreqRequired() const; 23 23 bool biasRequired() const; -
trunk/BNC/src/PPP/pppParlist.cpp
r5809 r5810 5 5 #include <algorithm> 6 6 #include <newmatio.h> 7 #include "p arlist.h"7 #include "pppParlist.h" 8 8 #include "satobs.h" 9 9 10 #include " station.h"10 #include "pppStation.h" 11 11 #include "bncutils.h" 12 12 #include "bncconst.h" … … 18 18 // Constructor 19 19 //////////////////////////////////////////////////////////////////////////// 20 t_p aram::t_param(e_type type, const t_prn& prn, t_lc::type tLC,20 t_pppParam::t_pppParam(e_type type, const t_prn& prn, t_lc::type tLC, 21 21 const vector<t_satObs*>* obsVector) { 22 22 … … 84 84 // Destructor 85 85 //////////////////////////////////////////////////////////////////////////// 86 t_p aram::~t_param() {86 t_pppParam::~t_pppParam() { 87 87 delete _ambInfo; 88 88 } … … 90 90 // 91 91 //////////////////////////////////////////////////////////////////////////// 92 double t_p aram::partial(const bncTime& /* epoTime */, const t_satObs* obs,92 double t_pppParam::partial(const bncTime& /* epoTime */, const t_satObs* obs, 93 93 const t_lc::type& tLC) const { 94 94 … … 99 99 } 100 100 101 const t_ station* sta = PPP_CLIENT->staRover();101 const t_pppStation* sta = PPP_CLIENT->staRover(); 102 102 ColumnVector rhoV = sta->xyzApr() - obs->xc().Rows(1,3); 103 103 … … 149 149 // 150 150 //////////////////////////////////////////////////////////////////////////// 151 string t_p aram::toString() const {151 string t_pppParam::toString() const { 152 152 stringstream ss; 153 153 switch (_type) { … … 182 182 // Constructor 183 183 //////////////////////////////////////////////////////////////////////////// 184 t_p arlist::t_parlist() {184 t_pppParlist::t_pppParlist() { 185 185 } 186 186 187 187 // Destructor 188 188 //////////////////////////////////////////////////////////////////////////// 189 t_p arlist::~t_parlist() {189 t_pppParlist::~t_pppParlist() { 190 190 for (unsigned ii = 0; ii < _params.size(); ii++) { 191 191 delete _params[ii]; … … 195 195 // 196 196 //////////////////////////////////////////////////////////////////////////// 197 t_irc t_p arlist::set(const bncTime& epoTime, const vector<t_lc::type>& ambLCs,197 t_irc t_pppParlist::set(const bncTime& epoTime, const vector<t_lc::type>& ambLCs, 198 198 const vector<t_satObs*>& obsVector) { 199 199 200 200 // Remove some Parameters 201 201 // ---------------------- 202 vector<t_p aram*>::iterator it = _params.begin();202 vector<t_pppParam*>::iterator it = _params.begin(); 203 203 while (it != _params.end()) { 204 t_p aram* par = *it;204 t_pppParam* par = *it; 205 205 206 206 bool remove = false; … … 210 210 } 211 211 212 else if (par->type() == t_p aram::amb) {212 else if (par->type() == t_pppParam::amb) { 213 213 if (par->lastObsTime().valid() && (epoTime - par->lastObsTime() > 120.0)) { 214 214 remove = true; … … 216 216 } 217 217 218 else if (par->type() == t_p aram::amb) {218 else if (par->type() == t_pppParam::amb) { 219 219 if (par->lastObsTime().valid() && (epoTime - par->lastObsTime() > 3600.0)) { 220 220 remove = true; … … 234 234 // ------------------------------------------ 235 235 for (unsigned ii = 0; ii < _params.size(); ii++) { 236 t_p aram* par = _params[ii];236 t_pppParam* par = _params[ii]; 237 237 if (par->prn() == 0) { 238 238 par->setLastObsTime(epoTime); … … 257 257 // Required Set of Parameters 258 258 // -------------------------- 259 vector<t_p aram*> required;259 vector<t_pppParam*> required; 260 260 261 261 // Coordinates 262 262 // ----------- 263 required.push_back(new t_p aram(t_param::crdX, t_prn(), t_lc::dummy));264 required.push_back(new t_p aram(t_param::crdY, t_prn(), t_lc::dummy));265 required.push_back(new t_p aram(t_param::crdZ, t_prn(), t_lc::dummy));263 required.push_back(new t_pppParam(t_pppParam::crdX, t_prn(), t_lc::dummy)); 264 required.push_back(new t_pppParam(t_pppParam::crdY, t_prn(), t_lc::dummy)); 265 required.push_back(new t_pppParam(t_pppParam::crdZ, t_prn(), t_lc::dummy)); 266 266 267 267 // Receiver Clock 268 268 // -------------- 269 required.push_back(new t_p aram(t_param::clkR, t_prn(), t_lc::dummy));269 required.push_back(new t_pppParam(t_pppParam::clkR, t_prn(), t_lc::dummy)); 270 270 271 271 // GPS-Glonass Clock Offset 272 272 // ------------------------ 273 273 if (OPT->useGlonass()) { 274 required.push_back(new t_p aram(t_param::offGG, t_prn(), t_lc::dummy));274 required.push_back(new t_pppParam(t_pppParam::offGG, t_prn(), t_lc::dummy)); 275 275 } 276 276 … … 278 278 // --------------- 279 279 for (unsigned ii = 0; ii < OPT->_estBias.size(); ii++) { 280 const t_ options::t_optBias& optBias = OPT->_estBias[ii];281 required.push_back(new t_p aram(t_param::bias, t_prn(optBias._system, 1), optBias._tLC));280 const t_pppOptions::t_optBias& optBias = OPT->_estBias[ii]; 281 required.push_back(new t_pppParam(t_pppParam::bias, t_prn(optBias._system, 1), optBias._tLC)); 282 282 } 283 283 … … 285 285 // ----------- 286 286 if (OPT->estTropo()) { 287 required.push_back(new t_p aram(t_param::trp, t_prn(), t_lc::dummy));287 required.push_back(new t_pppParam(t_pppParam::trp, t_prn(), t_lc::dummy)); 288 288 } 289 289 … … 294 294 for (unsigned jj = 0; jj < obsVector.size(); jj++) { 295 295 const t_satObs* satObs = obsVector[jj]; 296 required.push_back(new t_p aram(t_param::amb, satObs->prn(), tLC, &obsVector));296 required.push_back(new t_pppParam(t_pppParam::amb, satObs->prn(), tLC, &obsVector)); 297 297 } 298 298 } … … 301 301 // -------------------------------------------- 302 302 for (unsigned ii = 0; ii < required.size(); ii++) { 303 t_p aram* parReq = required[ii];303 t_pppParam* parReq = required[ii]; 304 304 305 305 bool found = false; 306 306 for (unsigned jj = 0; jj < _params.size(); jj++) { 307 t_p aram* parOld = _params[jj];307 t_pppParam* parOld = _params[jj]; 308 308 if (parOld->isEqual(parReq)) { 309 309 found = true; … … 321 321 // Set Parameter Indices 322 322 // --------------------- 323 sort(_params.begin(), _params.end(), t_p aram::sortFunction);323 sort(_params.begin(), _params.end(), t_pppParam::sortFunction); 324 324 325 325 for (unsigned ii = 0; ii < _params.size(); ii++) { 326 t_p aram* par = _params[ii];326 t_pppParam* par = _params[ii]; 327 327 par->setIndex(ii); 328 328 for (unsigned jj = 0; jj < obsVector.size(); jj++) { … … 340 340 // 341 341 //////////////////////////////////////////////////////////////////////////// 342 void t_p arlist::printResult(const bncTime& epoTime, const SymmetricMatrix& QQ,342 void t_pppParlist::printResult(const bncTime& epoTime, const SymmetricMatrix& QQ, 343 343 const ColumnVector& xx, double ambFixRate) const { 344 344 … … 347 347 LOG << endl; 348 348 349 t_p aram* parX = 0;350 t_p aram* parY = 0;351 t_p aram* parZ = 0;349 t_pppParam* parX = 0; 350 t_pppParam* parY = 0; 351 t_pppParam* parZ = 0; 352 352 for (unsigned ii = 0; ii < _params.size(); ii++) { 353 t_p aram* par = _params[ii];354 if (par->type() == t_p aram::crdX) {353 t_pppParam* par = _params[ii]; 354 if (par->type() == t_pppParam::crdX) { 355 355 parX = par; 356 356 } 357 else if (par->type() == t_p aram::crdY) {357 else if (par->type() == t_pppParam::crdY) { 358 358 parY = par; 359 359 } 360 else if (par->type() == t_p aram::crdZ) {360 else if (par->type() == t_pppParam::crdZ) { 361 361 parZ = par; 362 362 } … … 367 367 << showpos << setw(10) << setprecision(4) << xx[ind] << noshowpos << " +- " 368 368 << setw(8) << setprecision(4) << sqrt(QQ[ind][ind]); 369 if (par->type() == t_p aram::amb) {369 if (par->type() == t_pppParam::amb) { 370 370 LOG << " el = " << setw(6) << setprecision(2) << par->ambEleSat() * 180.0 / M_PI 371 371 << " epo = " << setw(4) << par->ambNumEpo(); … … 376 376 377 377 if (parX && parY && parZ) { 378 const t_ station* sta = PPP_CLIENT->staRover();378 const t_pppStation* sta = PPP_CLIENT->staRover(); 379 379 380 380 ColumnVector xyz(3); -
trunk/BNC/src/PPP/pppParlist.h
r5809 r5810 4 4 #include <vector> 5 5 #include <string> 6 #include "ppp .h"6 #include "pppInclude.h" 7 7 #include "t_prn.h" 8 8 #include "bnctime.h" … … 12 12 class t_satObs; 13 13 14 class t_p aram {14 class t_pppParam { 15 15 public: 16 16 enum e_type {crdX, crdY, crdZ, clkR, amb, offGG, trp, bias}; 17 17 18 t_p aram(e_type type, const t_prn& prn, t_lc::type tLC,18 t_pppParam(e_type type, const t_prn& prn, t_lc::type tLC, 19 19 const std::vector<t_satObs*>* obsVector = 0); 20 20 21 ~t_p aram();21 ~t_pppParam(); 22 22 e_type type() const {return _type;} 23 23 double x0() const {return _x0;} … … 25 25 const t_lc::type& tLC) const; 26 26 bool epoSpec() const {return _epoSpec;} 27 bool isEqual(const t_p aram* par2) const {27 bool isEqual(const t_pppParam* par2) const { 28 28 return (_type == par2->_type && _prn == par2->_prn && _tLC == par2->_tLC); 29 29 } … … 52 52 void stepAmbNumEpo() {if (_ambInfo) _ambInfo->_numEpo += 1;} 53 53 54 static bool sortFunction(const t_p aram* p1, const t_param* p2) {54 static bool sortFunction(const t_pppParam* p1, const t_pppParam* p2) { 55 55 if (p1->_type != p2->_type) { 56 56 return p1->_type < p2->_type; … … 92 92 }; 93 93 94 class t_p arlist {94 class t_pppParlist { 95 95 public: 96 t_p arlist();97 ~t_p arlist();96 t_pppParlist(); 97 ~t_pppParlist(); 98 98 99 99 t_irc set(const bncTime& epoTime, const std::vector<t_lc::type>& ambLCs, … … 101 101 102 102 unsigned nPar() const {return _params.size();} 103 const std::vector<t_p aram*>& params() const {return _params;}104 std::vector<t_p aram*>& params() {return _params;}103 const std::vector<t_pppParam*>& params() const {return _params;} 104 std::vector<t_pppParam*>& params() {return _params;} 105 105 void printResult(const bncTime& epoTime, const SymmetricMatrix& QQ, 106 106 const ColumnVector& xx, double ambFixRate) const; 107 107 private: 108 std::vector<t_p aram*> _params;108 std::vector<t_pppParam*> _params; 109 109 }; 110 110 -
trunk/BNC/src/PPP/pppSatBias.cpp
r5809 r5810 39 39 * -----------------------------------------------------------------------*/ 40 40 41 #include " satbias.h"41 #include "pppSatBias.h" 42 42 43 43 using namespace BNC; -
trunk/BNC/src/PPP/pppSatBias.h
r5809 r5810 3 3 4 4 #include <map> 5 #include "ppp .h"5 #include "pppInclude.h" 6 6 #include "bnctime.h" 7 7 -
trunk/BNC/src/PPP/pppStation.cpp
r5809 r5810 27 27 * ------------------------------------------------------------------------- 28 28 * 29 * Class: t_ station29 * Class: t_pppStation 30 30 * 31 31 * Purpose: Processed station … … 39 39 * -----------------------------------------------------------------------*/ 40 40 41 #include " station.h"41 #include "pppStation.h" 42 42 #include "bncutils.h" 43 43 #include "pppModel.h" … … 48 48 // Constructor 49 49 ////////////////////////////////////////////////////////////////////////////// 50 t_ station::t_station() {50 t_pppStation::t_pppStation() { 51 51 _windUp = new t_windUp(); 52 52 } … … 54 54 // Destructor 55 55 ////////////////////////////////////////////////////////////////////////////// 56 t_ station::~t_station() {56 t_pppStation::~t_pppStation() { 57 57 delete _windUp; 58 58 } … … 60 60 // 61 61 ////////////////////////////////////////////////////////////////////////////// 62 void t_ station::setXyzApr(const ColumnVector& xyzApr) {62 void t_pppStation::setXyzApr(const ColumnVector& xyzApr) { 63 63 _xyzApr = xyzApr; 64 64 _ellApr.ReSize(3); … … 68 68 // 69 69 ////////////////////////////////////////////////////////////////////////////// 70 void t_ station::setNeuEcc(const ColumnVector& neuEcc) {70 void t_pppStation::setNeuEcc(const ColumnVector& neuEcc) { 71 71 _neuEcc = neuEcc; 72 72 _xyzEcc.ReSize(3); … … 76 76 // 77 77 ////////////////////////////////////////////////////////////////////////////// 78 double t_ station::windUp(const bncTime& time, t_prn prn,78 double t_pppStation::windUp(const bncTime& time, t_prn prn, 79 79 const ColumnVector& rSat) const { 80 80 return _windUp->value(time, _xyzApr, prn, rSat); -
trunk/BNC/src/PPP/pppStation.h
r5809 r5810 4 4 #include <string> 5 5 #include <newmat.h> 6 #include "ppp .h"6 #include "pppInclude.h" 7 7 #include "bnctime.h" 8 8 … … 11 11 class t_windUp; 12 12 13 class t_ station {13 class t_pppStation { 14 14 public: 15 t_ station();16 ~t_ station();15 t_pppStation(); 16 ~t_pppStation(); 17 17 void setName(std::string name) {_name = name;} 18 18 void setAntName(std::string antName) {_antName = antName;} -
trunk/BNC/src/PPP/pppThread.cpp
r5793 r5810 28 28 * ------------------------------------------------------------------------- 29 29 * 30 * Class: t_ppp Thread, t_pppRun30 * Class: t_pppInclude.hread, t_pppRun 31 31 * 32 32 * Purpose: Single PPP Client (running in its own thread) … … 46 46 #include <map> 47 47 48 #include "ppp Thread.h"48 #include "pppInclude.hread.h" 49 49 #include "bnccore.h" 50 50 … … 54 54 // Constructor 55 55 //////////////////////////////////////////////////////////////////////////// 56 t_ppp Thread::t_pppThread(const t_options* opt) : QThread(0) {56 t_pppInclude.hread::t_pppInclude.hread(const t_pppOptions* opt) : QThread(0) { 57 57 _opt = opt; 58 58 _pppRun = 0; … … 65 65 // Destructor 66 66 //////////////////////////////////////////////////////////////////////////// 67 t_ppp Thread::~t_pppThread() {67 t_pppInclude.hread::~t_pppInclude.hread() { 68 68 delete _pppRun; 69 69 } … … 71 71 // Run (virtual) 72 72 //////////////////////////////////////////////////////////////////////////// 73 void t_ppp Thread::run() {73 void t_pppInclude.hread::run() { 74 74 try { 75 75 _pppRun = new t_pppRun(_opt); … … 84 84 // Constructor 85 85 //////////////////////////////////////////////////////////////////////////// 86 t_pppRun::t_pppRun(const t_ options* opt) {86 t_pppRun::t_pppRun(const t_pppOptions* opt) { 87 87 _opt = opt; 88 88 connect(this, SIGNAL(newMessage(QByteArray,bool)), -
trunk/BNC/src/PPP/pppThread.h
r5791 r5810 7 7 8 8 #include "GPSDecoder.h" 9 #include " options.h"9 #include "pppOptions.h" 10 10 #include "pppClient.h" 11 11 … … 27 27 Q_OBJECT 28 28 public: 29 t_pppRun(const t_ options* opt);29 t_pppRun(const t_pppOptions* opt); 30 30 ~t_pppRun(); 31 31 … … 42 42 private: 43 43 QMutex _mutex; 44 const t_ options* _opt;44 const t_pppOptions* _opt; 45 45 t_pppClient* _pppClient; 46 46 std::deque<t_pppEpoData*> _pppEpochs; 47 47 }; 48 48 49 class t_ppp Thread : public QThread {49 class t_pppInclude.hread : public QThread { 50 50 Q_OBJECT 51 51 public: 52 t_ppp Thread(const t_options* opt);53 ~t_ppp Thread();52 t_pppInclude.hread(const t_pppOptions* opt); 53 ~t_pppInclude.hread(); 54 54 virtual void run(); 55 55 … … 58 58 59 59 private: 60 const t_ options* _opt;60 const t_pppOptions* _opt; 61 61 t_pppRun* _pppRun; 62 62 }; -
trunk/BNC/src/PPP/pppWidgets.cpp
r5809 r5810 41 41 #include <iostream> 42 42 43 #include "PPP/ppp widgets.h"43 #include "PPP/pppWidgets.h" 44 44 #include "qtfilechooser.h" 45 45 #include "bncsettings.h" -
trunk/BNC/src/PPP/satobs.cpp
r5808 r5810 45 45 #include "satobs.h" 46 46 #include "bncconst.h" 47 #include " ephpool.h"48 #include " station.h"47 #include "pppEphPool.h" 48 #include "pppStation.h" 49 49 #include "bncutils.h" 50 50 #include "bncantex.h" 51 #include " obspool.h"51 #include "pppObsPool.h" 52 52 #include "pppClient.h" 53 53 … … 174 174 // 175 175 //////////////////////////////////////////////////////////////////////////// 176 t_irc t_satObs::cmpModel(const t_ station* station) {176 t_irc t_satObs::cmpModel(const t_pppStation* station) { 177 177 178 178 // Reset all model values -
trunk/BNC/src/PPP/satobs.h
r5780 r5810 5 5 #include <map> 6 6 #include <newmat.h> 7 #include "ppp .h"7 #include "pppInclude.h" 8 8 #include "bnctime.h" 9 9 … … 12 12 typedef std::string t_obsType; 13 13 14 class t_ station;14 class t_pppStation; 15 15 16 16 class t_satObs { … … 23 23 const ColumnVector& xc() const {return _xcSat;} 24 24 const bncTime& time() const {return _time;} 25 t_irc cmpModel(const t_ station* station);25 t_irc cmpModel(const t_pppStation* station); 26 26 double obsValue(t_lc::type tLC) const; 27 27 double cmpValue(t_lc::type tLC) const;
Note:
See TracChangeset
for help on using the changeset viewer.