Changeset 7753 in ntrip
- Timestamp:
- Feb 10, 2016, 1:54:36 PM (9 years ago)
- Location:
- trunk/BNC/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/RTCM3/RTCM3Decoder.cpp
r7215 r7753 35 35 * Created: 24-Aug-2006 36 36 * 37 * Changes: 37 * Changes: 38 38 * 39 39 * -----------------------------------------------------------------------*/ … … 52 52 #include "bnccore.h" 53 53 #include "bncutils.h" 54 #include "bncsettings.h" 54 #include "bncsettings.h" 55 55 56 56 using namespace std; … … 63 63 // Constructor 64 64 //////////////////////////////////////////////////////////////////////////// 65 RTCM3Decoder::RTCM3Decoder(const QString& staID, bncRawFile* rawFile) : 65 RTCM3Decoder::RTCM3Decoder(const QString& staID, bncRawFile* rawFile) : 66 66 GPSDecoder() { 67 67 … … 89 89 } 90 90 91 // 91 // 92 92 //////////////////////////////////////////////////////////////////////////// 93 93 bool RTCM3Decoder::DecodeRTCM3GPS(unsigned char* data, int size) … … 109 109 { 110 110 decoded = true; 111 _obsList = _CurrentObsList;111 _obsList.append(_CurrentObsList); 112 112 _CurrentObsList.clear(); 113 113 } 114 114 115 _CurrentTime = CurrentObsTime; 115 116 … … 199 200 _CurrentObsList.push_back(CurrentObs); 200 201 } 202 201 203 if(!syncf) 202 204 { 203 205 decoded = true; 204 _obsList = _CurrentObsList;206 _obsList.append(_CurrentObsList); 205 207 _CurrentTime.reset(); 206 208 _CurrentObsList.clear(); … … 266 268 /** 267 269 * MSM signal types for GLONASS 268 * 270 * 269 271 * NOTE: Uses 0.0, 1.0 for wavelength as sat index dependence is done later! 270 272 */ … … 418 420 #define UINT64(c) c ## ULL 419 421 420 // 422 // 421 423 //////////////////////////////////////////////////////////////////////////// 422 424 bool RTCM3Decoder::DecodeRTCM3MSM(unsigned char* data, int size) … … 473 475 /** 474 476 * Ignore unknown types except for sync flag 475 * 477 * 476 478 * We actually support types 1-3 in following code, but as they are missing 477 479 * the full cycles and can't be used later we skip interpretation here already. … … 849 851 } 850 852 851 // 853 // 852 854 //////////////////////////////////////////////////////////////////////////// 853 855 bool RTCM3Decoder::DecodeRTCM3GLONASS(unsigned char* data, int size) … … 869 871 { 870 872 decoded = true; 871 _obsList = _CurrentObsList;873 _obsList.append(_CurrentObsList); 872 874 _CurrentObsList.clear(); 873 875 } … … 961 963 { 962 964 decoded = true; 963 _obsList = _CurrentObsList;965 _obsList.append(_CurrentObsList); 964 966 _CurrentTime.reset(); 965 967 _CurrentObsList.clear(); … … 1106 1108 eph._tt = eph._TOC; 1107 1109 1108 eph._xv(1) = eph._x_pos * 1.e3; 1109 eph._xv(2) = eph._y_pos * 1.e3; 1110 eph._xv(3) = eph._z_pos * 1.e3; 1111 eph._xv(4) = eph._x_velocity * 1.e3; 1112 eph._xv(5) = eph._y_velocity * 1.e3; 1113 eph._xv(6) = eph._z_velocity * 1.e3; 1110 eph._xv(1) = eph._x_pos * 1.e3; 1111 eph._xv(2) = eph._y_pos * 1.e3; 1112 eph._xv(3) = eph._z_pos * 1.e3; 1113 eph._xv(4) = eph._x_velocity * 1.e3; 1114 eph._xv(5) = eph._y_velocity * 1.e3; 1115 eph._xv(6) = eph._z_velocity * 1.e3; 1114 1116 1115 1117 emit newGlonassEph(eph); … … 1440 1442 } 1441 1443 1442 // 1444 // 1443 1445 //////////////////////////////////////////////////////////////////////////// 1444 1446 t_irc RTCM3Decoder::Decode(char* buffer, int bufLen, vector<string>& errmsg) … … 1472 1474 { 1473 1475 if (!_coDecoders.contains(_staID.toAscii())) 1474 _coDecoders[_staID.toAscii()] = new RTCM3coDecoder(_staID); 1476 _coDecoders[_staID.toAscii()] = new RTCM3coDecoder(_staID); 1475 1477 RTCM3coDecoder* coDecoder = _coDecoders[_staID.toAscii()]; 1476 1478 if(coDecoder->Decode(reinterpret_cast<char *>(_Message), _BlockSize, … … 1542 1544 }; 1543 1545 1544 // 1546 // 1545 1547 //////////////////////////////////////////////////////////////////////////// 1546 1548 uint32_t RTCM3Decoder::CRC24(long size, const unsigned char *buf) … … 1562 1564 } 1563 1565 1564 // 1566 // 1565 1567 //////////////////////////////////////////////////////////////////////////// 1566 1568 int RTCM3Decoder::GetMessage(void) -
trunk/BNC/src/bncgetthread.cpp
r7724 r7753 493 493 continue; 494 494 } 495 decoder()->_obsList.clear(); 495 496 496 t_irc irc = decoder()->Decode(data.data(), data.size(), errmsg); 497 497 498 if (irc != success) { 499 continue; 500 } 498 501 // Perform various scans and checks 499 502 // -------------------------------- … … 506 509 } 507 510 508 if (irc == success) { 509 miscScanRTCM(); 510 } 511 miscScanRTCM(); 511 512 512 513 // Loop over all observations (observations output) … … 570 571 } 571 572 572 decoder()->_obsList.clear();573 573 } 574 574 catch (Exception& exc) {
Note:
See TracChangeset
for help on using the changeset viewer.