Changeset 7753 in ntrip


Ignore:
Timestamp:
Feb 10, 2016, 1:54:36 PM (8 years ago)
Author:
stuerze
Message:

minor changes to prevent the loss of observation epochs

Location:
trunk/BNC/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/RTCM3/RTCM3Decoder.cpp

    r7215 r7753  
    3535 * Created:    24-Aug-2006
    3636 *
    37  * Changes:   
     37 * Changes:
    3838 *
    3939 * -----------------------------------------------------------------------*/
     
    5252#include "bnccore.h"
    5353#include "bncutils.h"
    54 #include "bncsettings.h" 
     54#include "bncsettings.h"
    5555
    5656using namespace std;
     
    6363// Constructor
    6464////////////////////////////////////////////////////////////////////////////
    65 RTCM3Decoder::RTCM3Decoder(const QString& staID, bncRawFile* rawFile) : 
     65RTCM3Decoder::RTCM3Decoder(const QString& staID, bncRawFile* rawFile) :
    6666                GPSDecoder() {
    6767
     
    8989}
    9090
    91 // 
     91//
    9292////////////////////////////////////////////////////////////////////////////
    9393bool RTCM3Decoder::DecodeRTCM3GPS(unsigned char* data, int size)
     
    109109  {
    110110    decoded = true;
    111     _obsList = _CurrentObsList;
     111    _obsList.append(_CurrentObsList);
    112112    _CurrentObsList.clear();
    113113  }
     114
    114115  _CurrentTime = CurrentObsTime;
    115116
     
    199200    _CurrentObsList.push_back(CurrentObs);
    200201  }
     202
    201203  if(!syncf)
    202204  {
    203205    decoded = true;
    204     _obsList = _CurrentObsList;
     206    _obsList.append(_CurrentObsList);
    205207    _CurrentTime.reset();
    206208    _CurrentObsList.clear();
     
    266268/**
    267269 * MSM signal types for GLONASS
    268  * 
     270 *
    269271 * NOTE: Uses 0.0, 1.0 for wavelength as sat index dependence is done later!
    270272 */
     
    418420#define UINT64(c) c ## ULL
    419421
    420 // 
     422//
    421423////////////////////////////////////////////////////////////////////////////
    422424bool RTCM3Decoder::DecodeRTCM3MSM(unsigned char* data, int size)
     
    473475  /**
    474476   * Ignore unknown types except for sync flag
    475    * 
     477   *
    476478   * We actually support types 1-3 in following code, but as they are missing
    477479   * the full cycles and can't be used later we skip interpretation here already.
     
    849851}
    850852
    851 // 
     853//
    852854////////////////////////////////////////////////////////////////////////////
    853855bool RTCM3Decoder::DecodeRTCM3GLONASS(unsigned char* data, int size)
     
    869871  {
    870872    decoded = true;
    871     _obsList = _CurrentObsList;
     873    _obsList.append(_CurrentObsList);
    872874    _CurrentObsList.clear();
    873875  }
     
    961963  {
    962964    decoded = true;
    963     _obsList = _CurrentObsList;
     965    _obsList.append(_CurrentObsList);
    964966    _CurrentTime.reset();
    965967    _CurrentObsList.clear();
     
    11061108    eph._tt = eph._TOC;
    11071109
    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;
    11141116
    11151117    emit newGlonassEph(eph);
     
    14401442}
    14411443
    1442 // 
     1444//
    14431445////////////////////////////////////////////////////////////////////////////
    14441446t_irc RTCM3Decoder::Decode(char* buffer, int bufLen, vector<string>& errmsg)
     
    14721474      {
    14731475        if (!_coDecoders.contains(_staID.toAscii()))
    1474           _coDecoders[_staID.toAscii()] = new RTCM3coDecoder(_staID); 
     1476          _coDecoders[_staID.toAscii()] = new RTCM3coDecoder(_staID);
    14751477        RTCM3coDecoder* coDecoder = _coDecoders[_staID.toAscii()];
    14761478        if(coDecoder->Decode(reinterpret_cast<char *>(_Message), _BlockSize,
     
    15421544};
    15431545
    1544 // 
     1546//
    15451547////////////////////////////////////////////////////////////////////////////
    15461548uint32_t RTCM3Decoder::CRC24(long size, const unsigned char *buf)
     
    15621564}
    15631565
    1564 // 
     1566//
    15651567////////////////////////////////////////////////////////////////////////////
    15661568int RTCM3Decoder::GetMessage(void)
  • trunk/BNC/src/bncgetthread.cpp

    r7724 r7753  
    493493        continue;
    494494      }
    495       decoder()->_obsList.clear();
     495
    496496      t_irc irc = decoder()->Decode(data.data(), data.size(), errmsg);
    497497
     498      if (irc != success) {
     499        continue;
     500      }
    498501      // Perform various scans and checks
    499502      // --------------------------------
     
    506509      }
    507510
    508       if (irc == success) {
    509         miscScanRTCM();
    510       }
     511      miscScanRTCM();
    511512
    512513      // Loop over all observations (observations output)
     
    570571      }
    571572
    572       decoder()->_obsList.clear();
    573573    }
    574574    catch (Exception& exc) {
Note: See TracChangeset for help on using the changeset viewer.