Index: trunk/BNC/bncgetthread.cpp
===================================================================
--- trunk/BNC/bncgetthread.cpp	(revision 1138)
+++ trunk/BNC/bncgetthread.cpp	(revision 1139)
@@ -65,9 +65,11 @@
                            const QByteArray& format) {
 
-  _decoder    = 0;
-  _socket     = 0;
-  _rawOutFile = 0;
   _format     = format;
-  
+
+  initialize();
+
+  _inspSegm = 0;
+
+  _staID = "SASS";  
   _rawInpFile = new QFile(rawInpFileName);
   _rawInpFile->open(QIODevice::ReadOnly);
@@ -82,5 +84,4 @@
   setTerminationEnabled(true);
 
-  _decoder    = 0;
   _mountPoint = mountPoint;
   _staID      = mountPoint.path().mid(1).toAscii();
@@ -90,9 +91,17 @@
   _longitude  = longitude;
   _nmea       = nmea;
+  _iMount     = iMount;   // index in mountpoints array
+
+  initialize();
+}
+
+void bncGetThread::initialize() {
+
+  _decoder    = 0;
   _socket     = 0;
-  _timeOut    = 20*1000;  // 20 seconds
-  _nextSleep  =  1;       //  1 second
-  _iMount     = iMount;   // index in mountpoints array
+  _timeOut    = 20*1000; // 20 seconds
+  _nextSleep  = 1;       //  1 second
   _rawInpFile = 0;
+  _rawOutFile = 0;
 
   // Check name conflict
@@ -156,19 +165,14 @@
   }
   else {
-    _rnx = new bncRinex(_staID, mountPoint, format, latitude, longitude, nmea);
+    _rnx = new bncRinex(_staID, _mountPoint, 
+                        _format, _latitude, _longitude, _nmea);
   }
   _rnx_set_position = false;
-
 
   // Raw Output
   // ----------
-  if (false) {    // special option used for testing
-    QByteArray rawOutFileName = "./" + _staID + ".raw";
-    _rawOutFile = new QFile(rawOutFileName);
-    _rawOutFile->open(QIODevice::WriteOnly);
-  }
-  else {
-    _rawOutFile = 0;
-  }
+  QByteArray rawOutFileName = "./" + _staID + ".raw";
+  _rawOutFile = new QFile(rawOutFileName);
+  _rawOutFile->open(QIODevice::WriteOnly);
 
   msleep(100); //sleep 0.1 sec
@@ -493,5 +497,5 @@
       }
       else if (_rawInpFile) {
-        const qint64 maxBytes = 1024;
+        const qint64 maxBytes = 10000;
         nBytes = maxBytes;
       }
