Changeset 1035 in ntrip for trunk/BNC/RTCM3
- Timestamp:
- Aug 15, 2008, 6:31:34 PM (17 years ago)
- Location:
- trunk/BNC/RTCM3
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/RTCM3/RTCM3Decoder.cpp
r1034 r1035 47 47 #include "bncconst.h" 48 48 #include "bncapp.h" 49 #include "bncutils.h" /* Weber, for latencies */ 49 50 50 51 using namespace std; … … 67 68 QSettings settings; 68 69 _checkMountPoint = settings.value("messTypes").toString(); 70 _corrLate = settings.value("corrLate").toInt(); 69 71 _staID = staID; 70 72 … … 110 112 if ( _coDecoder->Decode(buffer, bufLen) == success ) { 111 113 decoded = true; 114 115 // Latency, Weber 116 // ------- 117 if ( _corrLate == 2 ) { 118 if (0<_coDecoder->_epochList.size()) { 119 for (int ii=0;ii<_coDecoder->_epochList.size();ii++) { 120 int week; 121 double sec; 122 double secGPS = _coDecoder->_epochList[ii]; 123 leapsecGPSWeeks(week, sec); 124 double dt = fabs(sec - secGPS); 125 const double secPerWeek = 7.0 * 24.0 * 3600.0; 126 if (dt > 0.5 * secPerWeek) { 127 if (sec > secGPS) { 128 sec -= secPerWeek; 129 } else { 130 sec += secPerWeek; 131 } 132 } 133 QString late; 134 late = QString("%1 ").arg(int((sec - secGPS)*100.)/100.); 135 if (late != "") { 136 emit(newMessage(QString(_staID + ": Latency " + late + "sec").toAscii() ) ); 137 } 138 } 139 } 140 } 141 _coDecoder->_epochList.clear(); 142 112 143 if (_mode == unknown) { 113 144 _mode = corrections; -
trunk/BNC/RTCM3/RTCM3Decoder.h
r1034 r1035 50 50 QString _staID; 51 51 QString _checkMountPoint; 52 int _corrLate; 52 53 struct RTCM3ParserData _Parser; 53 54 RTCM3coDecoder* _coDecoder; … … 56 57 57 58 #endif 59 -
trunk/BNC/RTCM3/RTCM3coDecoder.cpp
r1023 r1035 139 139 double GPSweeks; 140 140 currentGPSWeeks(GPSweek, GPSweeks); 141 142 for (int kk = 0; kk < _co.epochSize; kk++) { 143 _epochList.push_back(_co.epochGPS[kk]); /* Weber, for latency */ 144 } 141 145 142 146 if (_co.NumberOfGPSSat > 0) { -
trunk/BNC/RTCM3/clock_orbit_rtcm.c
r879 r1035 3 3 Name: clock_orbit_rtcm.c 4 4 Project: RTCM3 5 Version: $Id $5 Version: $Id: clock_orbit_rtcm.c,v 1.2 2008/05/06 15:07:41 mervart Exp $ 6 6 Authors: Dirk Stöcker 7 7 Description: state space approach for RTCM3 … … 495 495 if(!co) return GCOBR_NOCLOCKORBITPARAMETER; 496 496 G_GPS_EPOCH_TIME(co->GPSEpochTime, co->NumberOfGPSSat) 497 co->epochGPS[co->epochSize] = co->GPSEpochTime; /* Weber, for latency */ 498 if(co->epochSize < 100) {co->epochSize += 1;} /* Weber, for latency */ 497 499 G_MULTIPLE_MESSAGE_INDICATOR(mmi) 498 500 G_RESERVED6 … … 521 523 if(!co) return GCOBR_NOCLOCKORBITPARAMETER; 522 524 G_GPS_EPOCH_TIME(co->GPSEpochTime, co->NumberOfGPSSat) 525 co->epochGPS[co->epochSize] = co->GPSEpochTime; /* Weber, for latency */ 526 if(co->epochSize < 100) {co->epochSize += 1;} /* Weber, for latency */ 523 527 G_MULTIPLE_MESSAGE_INDICATOR(mmi) 524 528 G_RESERVED6 … … 539 543 if(!co) return -5; 540 544 G_GPS_EPOCH_TIME(co->GPSEpochTime, co->NumberOfGPSSat) 545 co->epochGPS[co->epochSize] = co->GPSEpochTime; /* Weber, for latency */ 546 if(co->epochSize < 100) {co->epochSize += 1;} /* Weber, for latency */ 541 547 G_MULTIPLE_MESSAGE_INDICATOR(mmi) 542 548 G_RESERVED6 -
trunk/BNC/RTCM3/clock_orbit_rtcm.h
r879 r1035 6 6 Name: clock_orbit_rtcm.h 7 7 Project: RTCM3 8 Version: $Id $8 Version: $Id: clock_orbit_rtcm.h,v 1.2 2008/05/06 15:07:41 mervart Exp $ 9 9 Authors: Dirk Stöcker 10 10 Description: state space approach for RTCM3 … … 52 52 int ClockDataSupplied; /* boolean */ 53 53 int OrbitDataSupplied; /* boolean */ 54 int epochGPS[101]; /* Weber, for latency */ 55 int epochSize; /* Weber, for latency */ 54 56 enum SatelliteReferencePoint SatRefPoint; 55 57 enum SatelliteReferenceDatum SatRefDatum;
Note:
See TracChangeset
for help on using the changeset viewer.