Changeset 9307 in ntrip


Ignore:
Timestamp:
Dec 10, 2020, 3:40:35 PM (3 years ago)
Author:
stuerze
Message:

bug fixed

Location:
branches/BNC_2.12/src/RTCM3
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/BNC_2.12/src/RTCM3/RTCM3Decoder.cpp

    r9286 r9307  
    17321732        if (!_coDecoders.contains(_staID.toLatin1())) {
    17331733          _coDecoders[_staID.toLatin1()] = new RTCM3coDecoder(_staID);
     1734          if (id == 4076) {
     1735            _coDecoders[_staID.toLatin1()]->initSsrFormatType(RTCM3coDecoder::IGSssr);
     1736          }
     1737          else {
     1738            _coDecoders[_staID.toLatin1()]->initSsrFormatType(RTCM3coDecoder::RTCMssr);
     1739          }
    17341740        }
    17351741        RTCM3coDecoder* coDecoder = _coDecoders[_staID.toLatin1()];
    1736         if (id == 4076) {
    1737           coDecoder->setSsrFormatType(RTCM3coDecoder::IGSssr);
    1738         }
    1739         else {
    1740           coDecoder->setSsrFormatType(RTCM3coDecoder::RTCMssr);
    1741         }
    1742         if (coDecoder->Decode(reinterpret_cast<char *>(_Message), _BlockSize,
    1743             errmsg) == success) {
     1742        if (coDecoder->Decode(reinterpret_cast<char *>(_Message), _BlockSize, errmsg) == success) {
    17441743          decoded = true;
    17451744        }
    17461745      }
    1747      else if (id >= 1070 && id <= 1237) { /* MSM */
     1746      else if (id >= 1070 && id <= 1237) { /* MSM */
    17481747        if (DecodeRTCM3MSM(_Message, _BlockSize))
    17491748          decoded = true;
     
    18281827  uint32_t crc = 0;
    18291828  int ii;
    1830  while (size--) {
     1829  while (size--) {
    18311830    crc ^= (*buf++) << (16);
    18321831    for (ii = 0; ii < 8; ii++) {
  • branches/BNC_2.12/src/RTCM3/RTCM3coDecoder.cpp

    r9051 r9307  
    179179
    180180    int bytesused = 0;
    181     if (_type == RTCMssr) {
    182       _ssrCorr = new SsrCorrRtcm();
    183     }
    184     else {
    185       _ssrCorr = new SsrCorrIgs();
    186     }
     181
    187182    GCOB_RETURN irc = _ssrCorr->GetSSR(&_clkOrb, &_codeBias, &_vTEC, &_phaseBias,
    188183                             _buffer.data(), _buffer.size(), &bytesused);
  • branches/BNC_2.12/src/RTCM3/RTCM3coDecoder.h

    r9049 r9307  
    4141  virtual t_irc Decode(char* buffer, int bufLen, std::vector<std::string>& errmsg);
    4242  virtual int corrGPSEpochTime() const {return int(_lastTime.gpssec());}
    43   virtual void setSsrFormatType(const e_type type) {_type = type;}
     43  virtual void initSsrFormatType(const e_type type) {
     44    _type = type;
     45    if      (_type == RTCMssr) {
     46      _ssrCorr = new SsrCorrRtcm();
     47    }
     48    else {
     49      _ssrCorr = new SsrCorrIgs();
     50    }
     51  }
    4452
    4553 signals:
Note: See TracChangeset for help on using the changeset viewer.