Index: /trunk/BNC/bnc.pro
===================================================================
--- /trunk/BNC/bnc.pro	(revision 1619)
+++ /trunk/BNC/bnc.pro	(revision 1620)
@@ -31,5 +31,5 @@
           bncnetquery.h bncnetqueryv1.h bncnetqueryv2.h               \
           bncnetqueryrtp.h bncsettings.h latencychecker.h             \
-          bncipport.h                                                 \
+          bncipport.h bncnetqueryv0.h                                 \ 
           RTCM/GPSDecoder.h RTCM/RTCM2.h RTCM/RTCM2Decoder.h          \
           RTCM/RTCM2_2021.h RTCM/rtcm_utils.h                         \
@@ -51,5 +51,5 @@
           bnczerodecoder.cpp bncnetqueryv1.cpp bncnetqueryv2.cpp      \
           bncnetqueryrtp.cpp bncsettings.cpp latencychecker.cpp       \
-          bncipport.cpp                                               \
+          bncipport.cpp bncnetqueryv0.cpp                             \
           RTCM/RTCM2.cpp RTCM/RTCM2Decoder.cpp                        \
           RTCM/RTCM2_2021.cpp RTCM/rtcm_utils.cpp                     \
Index: /trunk/BNC/bnchelp.html
===================================================================
--- /trunk/BNC/bnchelp.html	(revision 1619)
+++ /trunk/BNC/bnchelp.html	(revision 1620)
@@ -845,5 +845,5 @@
 <p><a name="streamip"><h4>3.12.10 Add Streams - Coming from TCP/IP Port</h4></p>
 <p>
-BNC allows to retrieve streams via TCP directly from an IP address without using the NTRIP transport protocol. For that you:
+If no proxy server is involved in the communication link, BNC allows to retrieve streams via TCP directly from an IP address without using the NTRIP transport protocol. For that you:
 <ul>
 <li>Enter the IP address of the stream providing host.</li>
@@ -856,5 +856,5 @@
 </p>
 <p>
-Streams directly received via TCP/IP port show up with an 'N' for 'No NTRIP' in the 'Streams' canvas section on BNC's main window . Latitude and longitude are to be entered just for informal reasons.
+Streams directly received from a TCP/IP port show up with an 'N' for 'No NTRIP' in the 'Streams' canvas section on BNC's main window . Latitude and longitude are to be entered just for informal reasons.
 </p>
 
Index: /trunk/BNC/bncipport.cpp
===================================================================
--- /trunk/BNC/bncipport.cpp	(revision 1619)
+++ /trunk/BNC/bncipport.cpp	(revision 1620)
@@ -71,6 +71,6 @@
   // WhatsThis
   // ---------
-  _ipHostLineEdit->setWhatsThis(tr("<p>BNC allows to retrieve streams directly via TCP from an IP address without using the NTRIP transport protocol.</p><p>Enter the IP address of the stream providing host.</p>"));
-  _ipPortLineEdit->setWhatsThis(tr("<p>Enter the port number of the stream providing host.</p>"));
+  _ipHostLineEdit->setWhatsThis(tr("<p>If no proxy server is involed in the communication, BNC allows to retrieve streams via TCP directly from an IP address without using the NTRIP transport protocol.</p><p>Enter the IP address of the stream providing host.</p>"));
+  _ipPortLineEdit->setWhatsThis(tr("<p>Enter the IP port number of the stream providing host.</p>"));
   _ipMountLineEdit->setWhatsThis(tr("<p>Specify a mountpoint.</p><p>Recommended is a 4-character reference station ID.<br>Example: FFMJ</p>"));
   _ipFormatLineEdit->setWhatsThis(tr("<p>Specify the stream format.</p><p>Available options are 'RTCM_2', 'RTCM_3', 'RTIGS', and 'ZERO'.</p>"));
Index: /trunk/BNC/bncnetqueryv0.cpp
===================================================================
--- /trunk/BNC/bncnetqueryv0.cpp	(revision 1620)
+++ /trunk/BNC/bncnetqueryv0.cpp	(revision 1620)
@@ -0,0 +1,172 @@
+/* -------------------------------------------------------------------------
+ * BKG NTRIP Client
+ * -------------------------------------------------------------------------
+ *
+ * Class:      bncNetQueryV0
+ *
+ * Purpose:    Blocking Network Requests (NTRIP Version 1)
+ *
+ * Author:     L. Mervart
+ *
+ * Created:    27-Dec-2008
+ *
+ * Changes:    
+ *
+ * -----------------------------------------------------------------------*/
+
+#include <iostream>
+#include <iomanip>
+
+#include "bncnetqueryv0.h"
+#include "bncsettings.h"
+
+using namespace std;
+
+#define BNCVERSION "1.7"
+
+// Constructor
+////////////////////////////////////////////////////////////////////////////
+bncNetQueryV0::bncNetQueryV0() {
+  _socket  = 0;
+  _timeOut = 20000;
+}
+
+// Destructor
+////////////////////////////////////////////////////////////////////////////
+bncNetQueryV0::~bncNetQueryV0() {
+  delete _socket;
+}
+
+// 
+////////////////////////////////////////////////////////////////////////////
+void bncNetQueryV0::stop() {
+#ifndef sparc
+  if (_socket) {
+    _socket->abort();
+  }
+#endif
+  _status = finished;
+}
+
+// 
+////////////////////////////////////////////////////////////////////////////
+void bncNetQueryV0::waitForRequestResult(const QUrl&, QByteArray&) {
+}
+
+// 
+////////////////////////////////////////////////////////////////////////////
+void bncNetQueryV0::waitForReadyRead(QByteArray& outData) {
+  if (_socket && _socket->state() == QAbstractSocket::ConnectedState) {
+    while (true) {
+      int nBytes = _socket->bytesAvailable();
+      if (nBytes > 0) {
+        outData = _socket->readAll();
+        return;
+      }
+      else if (!_socket->waitForReadyRead(_timeOut)) {
+        delete _socket;
+        _socket = 0;
+        _status = error;
+        emit newMessage(_url.path().toAscii() + " read timeout", true);
+        return;
+      }
+    }
+  }
+}
+
+// Connect to Caster, send the Request
+////////////////////////////////////////////////////////////////////////////
+void bncNetQueryV0::startRequest(const QUrl& url, const QByteArray& gga) {
+
+  _status = running;
+
+  delete _socket;
+  _socket = new QTcpSocket();
+
+  // Default scheme and path
+  // -----------------------
+  _url = url;
+  if (_url.scheme().isEmpty()) {
+    _url.setScheme("http");
+  }
+  if (_url.path().isEmpty()) {
+    _url.setPath("/");
+  }
+
+  // Connect the Socket
+  // ------------------
+  bncSettings settings;
+ 
+  _socket->connectToHost(_url.host(), _url.port());
+  if (!_socket->waitForConnected(_timeOut)) {
+    delete _socket; 
+    _socket = 0;
+    _status = error;
+    return;
+  }
+
+  // Send Request
+  // ------------
+  QString uName = QUrl::fromPercentEncoding(_url.userName().toAscii());
+  QString passW = QUrl::fromPercentEncoding(_url.password().toAscii());
+  QByteArray userAndPwd;
+
+  if(!uName.isEmpty() || !passW.isEmpty()) {
+    userAndPwd = "Authorization: Basic " + (uName.toAscii() + ":" +
+    passW.toAscii()).toBase64() + "\r\n";
+  }
+
+  QByteArray reqStr;
+  if (_url.path().indexOf("/") != 0) _url.setPath("/");
+  reqStr = "GET " + _url.path().toAscii() + " HTTP/1.0\r\n"
+           + "User-Agent: NTRIP BNC/" BNCVERSION "\r\n"
+           + userAndPwd + "\r\n";
+
+  // NMEA string to handle VRS stream
+  // --------------------------------
+  if (!gga.isEmpty()) {
+    reqStr += gga + "\r\n";
+  }
+
+  _socket->write(reqStr, reqStr.length());
+
+  if (!_socket->waitForBytesWritten(_timeOut)) {
+    delete _socket;
+    _socket = 0;
+    _status = error;
+    emit newMessage(_url.path().toAscii() + " write timeout", true);
+    return;
+  }
+
+  // Read Caster Response
+  // --------------------
+  QStringList response;
+  while (true) {
+    if (!_socket->waitForReadyRead(_timeOut)) {
+      delete _socket;
+      _socket = 0;
+      _status = error;
+      emit newMessage(_url.path().toAscii() + " read timeout", true);
+      return;
+    }
+    if (_socket->canReadLine()) {
+      QString line = _socket->readLine();
+      response.push_back(line);
+      if (line.trimmed().isEmpty()) {
+        break;
+      }
+      if (line.indexOf("200 OK") == -1) { // != weber
+        response.clear();
+        break;
+      }
+    }
+  }
+  if (response.size() > 0) {
+    delete _socket;
+    _socket = 0;
+    _status = error;
+    emit newMessage(_url.path().toAscii() + " wrong caster response\n" +
+                    response.join("\n").toAscii(), true);
+  }
+}
+
Index: /trunk/BNC/bncnetqueryv0.h
===================================================================
--- /trunk/BNC/bncnetqueryv0.h	(revision 1620)
+++ /trunk/BNC/bncnetqueryv0.h	(revision 1620)
@@ -0,0 +1,20 @@
+#ifndef BNCNETQUERYV0_H
+#define BNCNETQUERYV0_H
+
+#include "bncnetquery.h"
+
+class bncNetQueryV0 : public bncNetQuery {
+ public:
+  bncNetQueryV0();
+  virtual ~bncNetQueryV0();
+
+  virtual void stop();
+  virtual void waitForRequestResult(const QUrl& url, QByteArray& outData);
+  virtual void startRequest(const QUrl& url, const QByteArray& gga);
+  virtual void waitForReadyRead(QByteArray& outData);
+
+ private:
+  QTcpSocket* _socket;
+};
+
+#endif
