Changeset 5772 in ntrip
- Timestamp:
- Aug 4, 2014, 9:52:05 AM (11 years ago)
- Location:
- trunk/BNC/src/PPP
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/PPP/pppClient.cpp
r5769 r5772 108 108 // 109 109 ////////////////////////////////////////////////////////////////////////////// 110 void t_pppClient::putGPSEphemeris(const t_ephGPS* eph) { 111 _ephPool->putEphemeris(new t_ephGPS(*eph)); 112 } 113 114 // 115 ////////////////////////////////////////////////////////////////////////////// 116 void t_pppClient::putGloEphemeris(const t_ephGlo* eph) { 117 _ephPool->putEphemeris(new t_ephGlo(*eph)); 118 } 119 120 // 121 ////////////////////////////////////////////////////////////////////////////// 122 void t_pppClient::putGalEphemeris(const t_ephGal* eph) { 123 _ephPool->putEphemeris(new t_ephGal(*eph)); 124 } 125 126 // 127 ////////////////////////////////////////////////////////////////////////////// 128 void t_pppClient::putOrbCorrections(int numCorr, const t_orbCorr* corr) { 129 for (int ii = 0; ii < numCorr; ii++) { 110 void t_pppClient::putEphemeris(const t_eph* eph) { 111 const t_ephGPS* ephGPS = dynamic_cast<const t_ephGPS*>(eph); 112 const t_ephGlo* ephGlo = dynamic_cast<const t_ephGlo*>(eph); 113 const t_ephGal* ephGal = dynamic_cast<const t_ephGal*>(eph); 114 if (ephGPS) { 115 _ephPool->putEphemeris(new t_ephGPS(*ephGPS)); 116 } 117 else if (ephGlo) { 118 _ephPool->putEphemeris(new t_ephGlo(*ephGlo)); 119 } 120 else if (ephGal) { 121 _ephPool->putEphemeris(new t_ephGal(*ephGal)); 122 } 123 } 124 125 // 126 ////////////////////////////////////////////////////////////////////////////// 127 void t_pppClient::putOrbCorrections(const vector<t_orbCorr>& corr) { 128 for (unsigned ii = 0; ii < corr.size(); ii++) { 130 129 _ephPool->putOrbCorrection(new t_orbCorr(corr[ii])); 131 130 } … … 134 133 // 135 134 ////////////////////////////////////////////////////////////////////////////// 136 void t_pppClient::putClkCorrections( int numCorr, constt_clkCorr*corr) {137 for ( intii = 0; ii <numCorr; ii++) {135 void t_pppClient::putClkCorrections(const vector<t_clkCorr>& corr) { 136 for (unsigned ii = 0; ii < corr.size(); ii++) { 138 137 _ephPool->putClkCorrection(new t_clkCorr(corr[ii])); 139 138 } … … 142 141 // 143 142 ////////////////////////////////////////////////////////////////////////////// 144 void t_pppClient::putBiases( int numBiases, constt_satBiases*biases) {145 for ( intii = 0; ii <numBiases; ii++) {143 void t_pppClient::putBiases(const vector<t_satBiases>& biases) { 144 for (unsigned ii = 0; ii < biases.size(); ii++) { 146 145 _obsPool->putBiases(new t_satBias(biases[ii])); 147 146 } … … 150 149 // 151 150 ////////////////////////////////////////////////////////////////////////////// 152 t_irc t_pppClient::prepareObs( int numSat, constt_pppSatObs* satObs,153 151 t_irc t_pppClient::prepareObs(const vector<t_pppSatObs>& pppSatObs, 152 vector<t_satObs*>& obsVector, bncTime& epoTime) { 154 153 // Default 155 154 // ------- … … 159 158 // ----------------------------------- 160 159 int numValidGPS = 0; 161 for ( intii = 0; ii <numSat; ii++) {162 char system = satObs[ii]._prn.system();160 for (unsigned ii = 0; ii < pppSatObs.size(); ii++) { 161 char system = pppSatObs[ii]._prn.system(); 163 162 if (system == 'G' || (system == 'R' && OPT->useGlonass())) { 164 t_satObs* satObs = new t_satObs( satObs[ii]);163 t_satObs* satObs = new t_satObs(pppSatObs[ii]); 165 164 if (satObs->isValid()) { 166 165 obsVector.push_back(satObs); … … 401 400 // 402 401 ////////////////////////////////////////////////////////////////////////////// 403 void t_pppClient::processEpoch(int numSatRover, const t_pppSatObs* satObsRover, 404 t_output* output) { 402 void t_pppClient::processEpoch(const vector<t_pppSatObs>& pppSatObs, t_output* output) { 405 403 406 404 try { … … 409 407 // Prepare Observations of the Rover 410 408 // --------------------------------- 411 if (prepareObs(numSatRover, satObsRover, _obsRover, 412 _epoTimeRover) != success) { 409 if (prepareObs(pppSatObs, _obsRover, _epoTimeRover) != success) { 413 410 return finish(failure); 414 411 } -
trunk/BNC/src/PPP/pppClient.h
r5769 r5772 23 23 ~t_pppClient(); 24 24 25 void putGPSEphemeris(const t_ephGPS* eph); 26 void putGloEphemeris(const t_ephGlo* eph); 27 void putGalEphemeris(const t_ephGal* eph); 28 void putOrbCorrections(int numCorr, const t_orbCorr* corr); 29 void putClkCorrections(int numCorr, const t_clkCorr* corr); 30 void putBiases(int numBiases, const t_satBiases* biases); 31 void processEpoch(int numSatRover, const t_pppSatObs* satObsRover, 32 t_output* output); 25 void putEphemeris(const t_eph* eph); 26 void putOrbCorrections(const std::vector<t_orbCorr>& corr); 27 void putClkCorrections(const std::vector<t_clkCorr>& corr); 28 void putBiases(const std::vector<t_satBiases>& biases); 29 void processEpoch(const std::vector<t_pppSatObs>& pppSatObs, t_output* output); 33 30 34 31 const t_ephPool* ephPool() const {return _ephPool;} … … 49 46 void finish(t_irc irc); 50 47 void clearObs(); 51 t_irc prepareObs( int numSat, constt_pppSatObs* satObs,52 48 t_irc prepareObs(const std::vector<t_pppSatObs>& pppSatObs, 49 std::vector<t_satObs*>& obsVector, bncTime& epoTime); 53 50 t_irc cmpModel(t_station* station, const ColumnVector& xyzc, 54 std::vector<t_satObs*>& obsVector); 55 t_irc cmpBancroft(const bncTime& epoTime, 56 std::vector<t_satObs*>& obsVector, 57 ColumnVector& xyzc, bool print); 51 std::vector<t_satObs*>& obsVector); 52 t_irc cmpBancroft(const bncTime& epoTime, std::vector<t_satObs*>& obsVector, 53 ColumnVector& xyzc, bool print); 58 54 double cmpOffGG(std::vector<t_satObs*>& obsVector); 59 55 -
trunk/BNC/src/PPP/pppThread.cpp
r5771 r5772 118 118 t_ephGPS eph; 119 119 eph.set(&gpseph); 120 _pppClient->put GPSEphemeris(&eph);120 _pppClient->putEphemeris(&eph); 121 121 } 122 122 … … 127 127 t_ephGlo eph; 128 128 eph.set(&gloeph); 129 _pppClient->put GloEphemeris(&eph);129 _pppClient->putEphemeris(&eph); 130 130 } 131 131 … … 136 136 t_ephGal eph; 137 137 eph.set(&galeph); 138 _pppClient->put GalEphemeris(&eph);138 _pppClient->putEphemeris(&eph); 139 139 } 140 140 … … 148 148 } 149 149 150 // _pppClient->putOrbCorrections( int numCorr, constt_orbCorr*corr);151 // _pppClient->putClkCorrections( int numCorr, constt_clkCorr*corr);152 // _pppClient->putBiases( int numBiases, constt_satBiases*biases);150 // _pppClient->putOrbCorrections(const std::vector<t_orbCorr>& corr); 151 // _pppClient->putClkCorrections(const std::vector<t_clkCorr>& corr); 152 // _pppClient->putBiases(const std::vector<t_satBiases>& biases); 153 153 } 154 154 // … … 157 157 QMutexLocker locker(&_mutex); 158 158 159 QByteArray msg = "slotNewObs"; 160 emit newMessage(msg, true); 159 160 vector<t_pppSatObs> satObs; 161 t_output output; 162 163 _pppClient->processEpoch(satObs, &output); 164 165 emit newMessage(QByteArray(output._log.c_str()), true); 161 166 } 162 167
Note:
See TracChangeset
for help on using the changeset viewer.