Changeset 733 in ntrip for trunk


Ignore:
Timestamp:
Mar 18, 2008, 10:18:16 AM (17 years ago)
Author:
mervart
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/test_bnc_qt.cpp

    r633 r733  
    5757
    5858  QTcpSocket socketObs;
    59   QTcpSocket socketEph;
     59  ////  QTcpSocket socketEph;
    6060
    6161  QFile obsFile("obs.txt");
    62   QFile ephFile("eph.txt");
     62  ////  QFile ephFile("eph.txt");
    6363 
    6464  socketObs.connectToHost("127.0.0.1", 1968);
     
    6868  }
    6969
    70   socketEph.connectToHost("127.0.0.1", 1969);
    71   if (!socketEph.waitForConnected(10000)) {
    72     cout << "socketEph: not connected" << endl;
    73     exit(1);
    74   }
     70  ////  socketEph.connectToHost("127.0.0.1", 1969);
     71  ////  if (!socketEph.waitForConnected(10000)) {
     72  ////    cout << "socketEph: not connected" << endl;
     73  ////    exit(1);
     74  ////  }
    7575
    7676  obsFile.open(QIODevice::WriteOnly | QIODevice::Unbuffered);
    77   ephFile.open(QIODevice::WriteOnly | QIODevice::Unbuffered);
     77  ////  ephFile.open(QIODevice::WriteOnly | QIODevice::Unbuffered);
    7878
    7979  QTextStream outObs(&obsFile);
    8080  outObs.setRealNumberNotation(QTextStream::FixedNotation);
    8181
    82   QTextStream outEph(&ephFile);
    83   outEph.setRealNumberNotation(QTextStream::FixedNotation);
     82  ////  QTextStream outEph(&ephFile);
     83  ////  outEph.setRealNumberNotation(QTextStream::FixedNotation);
    8484
    8585  // Receive Data
     
    9494      exit(0);
    9595    }
    96     if (socketEph.state() != QAbstractSocket::ConnectedState) {
    97       cout << "socketEph: disconnected" << endl;
    98       exit(0);
    99     }
     96    ////  if (socketEph.state() != QAbstractSocket::ConnectedState) {
     97    ////    cout << "socketEph: disconnected" << endl;
     98    ////    exit(0);
     99    ////  }
    100100
    101101    if ( socketObs.bytesAvailable() ) {
     
    125125    }
    126126
    127     if ( socketEph.bytesAvailable() ) {
    128       QByteArray eph = socketEph.readAll();
    129       outEph << eph.data() << endl;
    130     }
    131     else {
    132       socketEph.waitForReadyRead(1);
    133     }
     127    ////  if ( socketEph.bytesAvailable() ) {
     128    ////    QByteArray eph = socketEph.readAll();
     129    ////    outEph << eph.data() << endl;
     130    ////  }
     131    ////  else {
     132    ////    socketEph.waitForReadyRead(1);
     133    ////  }
    134134  }
    135135
Note: See TracChangeset for help on using the changeset viewer.