Changeset 5731 in ntrip for trunk/BNC/src/PPP/pppThread.cpp


Ignore:
Timestamp:
Jul 31, 2014, 4:16:10 PM (10 years ago)
Author:
mervart
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/PPP/pppThread.cpp

    r5730 r5731  
    2828 * -------------------------------------------------------------------------
    2929 *
    30  * Class:      t_pppThread
     30 * Class:      t_pppThread, t_pppRun
    3131 *
    3232 * Purpose:    Single PPP Client (running in its own thread)
     
    6060////////////////////////////////////////////////////////////////////////////
    6161t_pppThread::~t_pppThread() {
     62  delete _pppRun;
    6263  cout << "~t_pppThread" << endl;
    6364}
     
    6970  cout << _opt._roverName << " run" << endl;
    7071
    71   // Connect to BNC Signals
    72   // ----------------------
     72  _pppRun = new t_pppRun(_opt);
     73  QThread::exec();
     74
     75  cout << _opt._roverName << " exit" << endl;
     76}
     77
     78// Constructor
     79////////////////////////////////////////////////////////////////////////////
     80t_pppRun::t_pppRun(const t_options& opt) {
     81  _opt = opt;
     82
    7383  if (BNC_CORE->caster()) {
    7484    connect(BNC_CORE->caster(), SIGNAL(newObs(QByteArray, QList<t_obs>)),
     
    8797            this, SLOT(slotNewCorrections(QList<QString>)));
    8898  }
    89  
    90   // Start processing loop
    91   // ---------------------
    92   QThread::exec();
     99}
    93100
    94   cout << _opt._roverName << " exit" << endl;
     101// Destructor
     102////////////////////////////////////////////////////////////////////////////
     103t_pppRun::~t_pppRun() {
     104  cout << "~t_pppRun" << endl;
    95105}
    96106
    97107//
    98108////////////////////////////////////////////////////////////////////////////
    99 void t_pppThread::slotNewEphGPS(gpsephemeris gpseph) {
     109void t_pppRun::slotNewEphGPS(gpsephemeris gpseph) {
    100110  QMutexLocker locker(&_mutex);
    101111  cout << _opt._roverName << " slotNewEphGPS" << endl;
     
    104114//
    105115////////////////////////////////////////////////////////////////////////////
    106 void t_pppThread::slotNewEphGlonass(glonassephemeris gloeph) {
     116void t_pppRun::slotNewEphGlonass(glonassephemeris gloeph) {
    107117  QMutexLocker locker(&_mutex);
    108118  cout << _opt._roverName << " slotNewEphGlonass" << endl;
     
    111121//
    112122////////////////////////////////////////////////////////////////////////////
    113 void t_pppThread::slotNewEphGalileo(galileoephemeris /* galeph */) {
     123void t_pppRun::slotNewEphGalileo(galileoephemeris /* galeph */) {
    114124  QMutexLocker locker(&_mutex);
    115125  cout << _opt._roverName << " slotNewEphGalileo" << endl;
     
    118128//
    119129////////////////////////////////////////////////////////////////////////////
    120 void t_pppThread::slotNewCorrections(QList<QString> corrList) {
     130void t_pppRun::slotNewCorrections(QList<QString> corrList) {
    121131  QMutexLocker locker(&_mutex);
    122132  cout << _opt._roverName << " slotNewCorrections" << endl;
     
    124134//
    125135////////////////////////////////////////////////////////////////////////////
    126 void t_pppThread::slotNewObs(QByteArray staID, QList<t_obs> obsList) {
     136void t_pppRun::slotNewObs(QByteArray staID, QList<t_obs> obsList) {
    127137  QMutexLocker locker(&_mutex);
    128138  cout << _opt._roverName << " slotNewObs" << endl;
Note: See TracChangeset for help on using the changeset viewer.