[748] | 1 |
|
---|
| 2 | /* -------------------------------------------------------------------------
|
---|
[749] | 3 | * BKG NTRIP Server
|
---|
[748] | 4 | * -------------------------------------------------------------------------
|
---|
| 5 | *
|
---|
| 6 | * Class: bnsWindow
|
---|
| 7 | *
|
---|
| 8 | * Purpose: This class implements the main application window.
|
---|
| 9 | *
|
---|
| 10 | * Author: L. Mervart
|
---|
| 11 | *
|
---|
| 12 | * Created: 29-Mar-2008
|
---|
| 13 | *
|
---|
| 14 | * Changes:
|
---|
| 15 | *
|
---|
| 16 | * -----------------------------------------------------------------------*/
|
---|
| 17 |
|
---|
[749] | 18 | #include <iostream>
|
---|
| 19 |
|
---|
[748] | 20 | #include "bnswindow.h"
|
---|
[749] | 21 | #include "bnshlpdlg.h"
|
---|
[1668] | 22 | #include "bnssettings.h"
|
---|
[1771] | 23 | #include "bnscustomtrafo.h"
|
---|
[748] | 24 |
|
---|
| 25 | using namespace std;
|
---|
| 26 |
|
---|
[754] | 27 | // About Dialog - Constructor
|
---|
| 28 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 29 | bnsAboutDlg::bnsAboutDlg(QWidget* parent) :
|
---|
| 30 | QDialog(parent) {
|
---|
| 31 |
|
---|
| 32 | QTextBrowser* tb = new QTextBrowser;
|
---|
| 33 | QUrl url; url.setPath(":bnsabout.html");
|
---|
| 34 | tb->setSource(url);
|
---|
| 35 | tb->setReadOnly(true);
|
---|
| 36 |
|
---|
| 37 | int ww = QFontMetrics(font()).width('w');
|
---|
| 38 | QPushButton* _closeButton = new QPushButton("Close");
|
---|
| 39 | _closeButton->setMaximumWidth(10*ww);
|
---|
| 40 | connect(_closeButton, SIGNAL(clicked()), this, SLOT(close()));
|
---|
| 41 |
|
---|
| 42 | QGridLayout* dlgLayout = new QGridLayout();
|
---|
| 43 | QLabel* img = new QLabel();
|
---|
| 44 | img->setPixmap(QPixmap(":ntrip-logo.png"));
|
---|
| 45 | dlgLayout->addWidget(img, 0,0);
|
---|
[1666] | 46 | dlgLayout->addWidget(new QLabel("BKG Ntrip State Space Server (BNS) Version 1.1"), 0,1);
|
---|
[754] | 47 | dlgLayout->addWidget(tb,1,0,1,2);
|
---|
| 48 | dlgLayout->addWidget(_closeButton,2,1,Qt::AlignRight);
|
---|
| 49 |
|
---|
| 50 | setLayout(dlgLayout);
|
---|
| 51 | resize(60*ww, 60*ww);
|
---|
| 52 | show();
|
---|
| 53 | }
|
---|
| 54 |
|
---|
| 55 | // About Dialog - Destructor
|
---|
| 56 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 57 | bnsAboutDlg::~bnsAboutDlg() {
|
---|
| 58 | };
|
---|
| 59 |
|
---|
[998] | 60 | // Flowchart Dialog - Constructor
|
---|
| 61 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 62 | bnsFlowchartDlg::bnsFlowchartDlg(QWidget* parent) :
|
---|
| 63 | QDialog(parent) {
|
---|
| 64 |
|
---|
| 65 | int ww = QFontMetrics(font()).width('w');
|
---|
| 66 | QPushButton* _closeButton = new QPushButton("Close");
|
---|
| 67 | _closeButton->setMaximumWidth(10*ww);
|
---|
| 68 | connect(_closeButton, SIGNAL(clicked()), this, SLOT(close()));
|
---|
| 69 |
|
---|
| 70 | QGridLayout* dlgLayout = new QGridLayout();
|
---|
| 71 | QLabel* img = new QLabel();
|
---|
| 72 | img->setPixmap(QPixmap(":bnsflowchart.png"));
|
---|
| 73 | dlgLayout->addWidget(img, 0,0);
|
---|
| 74 | dlgLayout->addWidget(_closeButton,1,0,Qt::AlignLeft);
|
---|
| 75 |
|
---|
| 76 | setLayout(dlgLayout);
|
---|
| 77 | show();
|
---|
| 78 | }
|
---|
| 79 |
|
---|
| 80 | // Flowchart Dialog - Destructor
|
---|
| 81 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 82 | bnsFlowchartDlg::~bnsFlowchartDlg() {
|
---|
| 83 | };
|
---|
| 84 |
|
---|
[748] | 85 | // Constructor
|
---|
| 86 | ////////////////////////////////////////////////////////////////////////////
|
---|
[758] | 87 | bnsWindow::bnsWindow() {
|
---|
[749] | 88 |
|
---|
[758] | 89 | _bns = 0;
|
---|
[757] | 90 |
|
---|
[1668] | 91 | bnsSettings settings;
|
---|
[752] | 92 |
|
---|
| 93 | QString fontString = settings.value("font").toString();
|
---|
| 94 | if ( !fontString.isEmpty() ) {
|
---|
| 95 | QFont newFont;
|
---|
| 96 | if (newFont.fromString(fontString)) {
|
---|
[1057] | 97 | QApplication::setFont(newFont);
|
---|
[752] | 98 | }
|
---|
| 99 | }
|
---|
| 100 |
|
---|
[749] | 101 | int ww = QFontMetrics(this->font()).width('w');
|
---|
| 102 | setMinimumSize(77*ww, 65*ww);
|
---|
[1666] | 103 | setWindowTitle(tr("BKG Ntrip State Space Server (BNS) Version 1.1"));
|
---|
[752] | 104 | setWindowIcon(QPixmap(":ntrip-logo.png"));
|
---|
[749] | 105 |
|
---|
| 106 | // Create Actions
|
---|
| 107 | // --------------
|
---|
| 108 | _actHelp = new QAction(tr("&Help Contents"),this);
|
---|
| 109 | connect(_actHelp, SIGNAL(triggered()), SLOT(slotHelp()));
|
---|
| 110 |
|
---|
| 111 | _actAbout = new QAction(tr("&About BNS"),this);
|
---|
| 112 | connect(_actAbout, SIGNAL(triggered()), SLOT(slotAbout()));
|
---|
| 113 |
|
---|
[998] | 114 | _actFlowchart = new QAction(tr("&Flow Chart"),this);
|
---|
| 115 | connect(_actFlowchart, SIGNAL(triggered()), SLOT(slotFlowchart()));
|
---|
| 116 |
|
---|
[749] | 117 | _actFontSel = new QAction(tr("Select &Font"),this);
|
---|
| 118 | connect(_actFontSel, SIGNAL(triggered()), SLOT(slotFontSel()));
|
---|
| 119 |
|
---|
| 120 | _actSaveOpt = new QAction(tr("&Save Options"),this);
|
---|
| 121 | connect(_actSaveOpt, SIGNAL(triggered()), SLOT(slotSaveOptions()));
|
---|
| 122 |
|
---|
| 123 | _actQuit = new QAction(tr("&Quit"),this);
|
---|
| 124 | connect(_actQuit, SIGNAL(triggered()), SLOT(close()));
|
---|
| 125 |
|
---|
[753] | 126 | _actWhatsThis= new QAction(tr("Help=Shift+F1"),this);
|
---|
| 127 | connect(_actWhatsThis, SIGNAL(triggered()), SLOT(slotWhatsThis()));
|
---|
[749] | 128 |
|
---|
[753] | 129 | _actStart = new QAction(tr("Sta&rt"),this);
|
---|
| 130 | connect(_actStart, SIGNAL(triggered()), SLOT(slotStart()));
|
---|
| 131 |
|
---|
| 132 | _actStop = new QAction(tr("Sto&p"),this);
|
---|
| 133 | connect(_actStop, SIGNAL(triggered()), SLOT(slotStop()));
|
---|
| 134 | _actStop->setEnabled(false);
|
---|
| 135 |
|
---|
[749] | 136 | CreateMenu();
|
---|
| 137 | AddToolbar();
|
---|
| 138 |
|
---|
| 139 | // Canvas with Editable Fields
|
---|
| 140 | // ---------------------------
|
---|
| 141 | _canvas = new QWidget;
|
---|
| 142 | setCentralWidget(_canvas);
|
---|
| 143 |
|
---|
[1668] | 144 | // Proxy Options
|
---|
| 145 | // -------------
|
---|
[958] | 146 | _proxyHostLineEdit = new QLineEdit(settings.value("proxyHost").toString());
|
---|
| 147 | _proxyPortLineEdit = new QLineEdit(settings.value("proxyPort").toString());
|
---|
| 148 |
|
---|
[1668] | 149 | // General Options
|
---|
| 150 | // ---------------
|
---|
[958] | 151 | _logFileLineEdit = new QLineEdit(settings.value("logFile").toString());
|
---|
| 152 | _fileAppendCheckBox = new QCheckBox();
|
---|
| 153 | _fileAppendCheckBox->setCheckState(Qt::CheckState(settings.value("fileAppend").toInt()));
|
---|
[1668] | 154 | _autoStartCheckBox = new QCheckBox();
|
---|
| 155 | _autoStartCheckBox->setCheckState(Qt::CheckState(
|
---|
| 156 | settings.value("autoStart").toInt()));
|
---|
[958] | 157 |
|
---|
[1668] | 158 | // RINEX Ephemeris Options
|
---|
| 159 | // -----------------------
|
---|
[958] | 160 | _ephHostLineEdit = new QLineEdit(settings.value("ephHost").toString());
|
---|
[752] | 161 | _ephPortLineEdit = new QLineEdit(settings.value("ephPort").toString());
|
---|
[1089] | 162 | _ephEchoLineEdit = new QLineEdit(settings.value("ephEcho").toString());
|
---|
[752] | 163 |
|
---|
[1668] | 164 | // Clocks & Orbits Options
|
---|
| 165 | // -----------------------
|
---|
[787] | 166 | _clkPortLineEdit = new QLineEdit(settings.value("clkPort").toString());
|
---|
[1668] | 167 | _inpEchoLineEdit = new QLineEdit(settings.value("inpEcho").toString());
|
---|
[750] | 168 |
|
---|
[1668] | 169 |
|
---|
[1682] | 170 | // Broadcast Corrections I Options
|
---|
[1668] | 171 | // -------------------------------
|
---|
[1249] | 172 | _outHost_1_LineEdit = new QLineEdit(settings.value("outHost1").toString());
|
---|
| 173 | _outPort_1_LineEdit = new QLineEdit(settings.value("outPort1").toString());
|
---|
| 174 | _password_1_LineEdit = new QLineEdit(settings.value("password1").toString());
|
---|
| 175 | _password_1_LineEdit->setEchoMode(QLineEdit::Password);
|
---|
[1068] | 176 | _mountpoint_1_LineEdit = new QLineEdit(settings.value("mountpoint_1").toString());
|
---|
| 177 | _refSys_1_ComboBox = new QComboBox;
|
---|
| 178 | _refSys_1_ComboBox->setEditable(false);
|
---|
[1771] | 179 | _refSys_1_ComboBox->addItems(QString("IGS05,ETRF2000,Custom").split(","));
|
---|
[1068] | 180 | int ii = _refSys_1_ComboBox->findText(settings.value("refSys_1").toString());
|
---|
| 181 | if (ii != -1) {
|
---|
| 182 | _refSys_1_ComboBox->setCurrentIndex(ii);
|
---|
| 183 | }
|
---|
[1668] | 184 | _outFile_1_LineEdit = new QLineEdit(settings.value("outFile_1").toString());
|
---|
[2046] | 185 | _CoM_1_CheckBox = new QCheckBox();
|
---|
| 186 | _CoM_1_CheckBox->setCheckState(Qt::CheckState(settings.value("CoM_1").toInt()));
|
---|
[1668] | 187 |
|
---|
[1682] | 188 | // Broadcast Corrections II Options
|
---|
[1668] | 189 | // --------------------------------
|
---|
| 190 | _outHost_2_LineEdit = new QLineEdit(settings.value("outHost2").toString());
|
---|
| 191 | _outPort_2_LineEdit = new QLineEdit(settings.value("outPort2").toString());
|
---|
| 192 | _password_2_LineEdit = new QLineEdit(settings.value("password2").toString());
|
---|
| 193 | _password_2_LineEdit->setEchoMode(QLineEdit::Password);
|
---|
| 194 | _mountpoint_2_LineEdit = new QLineEdit(settings.value("mountpoint_2").toString());
|
---|
[1068] | 195 | _refSys_2_ComboBox = new QComboBox;
|
---|
| 196 | _refSys_2_ComboBox->setEditable(false);
|
---|
[1771] | 197 | _refSys_2_ComboBox->addItems(QString("IGS05,ETRF2000,Custom").split(","));
|
---|
[1068] | 198 | ii = _refSys_2_ComboBox->findText(settings.value("refSys_2").toString());
|
---|
| 199 | if (ii != -1) {
|
---|
| 200 | _refSys_2_ComboBox->setCurrentIndex(ii);
|
---|
| 201 | }
|
---|
| 202 | _outFile_2_LineEdit = new QLineEdit(settings.value("outFile_2").toString());
|
---|
[2046] | 203 | _CoM_2_CheckBox = new QCheckBox();
|
---|
| 204 | _CoM_2_CheckBox->setCheckState(Qt::CheckState(settings.value("CoM_2").toInt()));
|
---|
[813] | 205 |
|
---|
[1728] | 206 | // Broadcast Corrections III Options
|
---|
| 207 | // ---------------------------------
|
---|
| 208 | _outHost_3_LineEdit = new QLineEdit(settings.value("outHost3").toString());
|
---|
| 209 | _outPort_3_LineEdit = new QLineEdit(settings.value("outPort3").toString());
|
---|
| 210 | _password_3_LineEdit = new QLineEdit(settings.value("password3").toString());
|
---|
| 211 | _password_3_LineEdit->setEchoMode(QLineEdit::Password);
|
---|
| 212 | _mountpoint_3_LineEdit = new QLineEdit(settings.value("mountpoint_3").toString());
|
---|
| 213 | _refSys_3_ComboBox = new QComboBox;
|
---|
| 214 | _refSys_3_ComboBox->setEditable(false);
|
---|
[1771] | 215 | _refSys_3_ComboBox->addItems(QString("IGS05,ETRF2000,Custom").split(","));
|
---|
[1728] | 216 | ii = _refSys_3_ComboBox->findText(settings.value("refSys_3").toString());
|
---|
| 217 | if (ii != -1) {
|
---|
| 218 | _refSys_3_ComboBox->setCurrentIndex(ii);
|
---|
| 219 | }
|
---|
| 220 | _outFile_3_LineEdit = new QLineEdit(settings.value("outFile_3").toString());
|
---|
[2046] | 221 | _CoM_3_CheckBox = new QCheckBox();
|
---|
| 222 | _CoM_3_CheckBox->setCheckState(Qt::CheckState(settings.value("CoM_3").toInt()));
|
---|
[1728] | 223 |
|
---|
[1795] | 224 | // Broadcast Ephemerides
|
---|
| 225 | // ---------------------
|
---|
| 226 | _outHost_Eph_LineEdit = new QLineEdit(settings.value("outHostEph").toString());
|
---|
| 227 | _outPort_Eph_LineEdit = new QLineEdit(settings.value("outPortEph").toString());
|
---|
| 228 | _password_Eph_LineEdit = new QLineEdit(settings.value("passwordEph").toString());
|
---|
| 229 | _password_Eph_LineEdit->setEchoMode(QLineEdit::Password);
|
---|
| 230 | _mountpoint_Eph_LineEdit = new QLineEdit(settings.value("mountpoint_Eph").toString());
|
---|
[1805] | 231 | _samplEphSpinBox = new QSpinBox;
|
---|
| 232 | _samplEphSpinBox->setMinimum(0);
|
---|
| 233 | _samplEphSpinBox->setMaximum(60);
|
---|
| 234 | _samplEphSpinBox->setSingleStep(5);
|
---|
| 235 | _samplEphSpinBox->setMaximumWidth(9*ww);
|
---|
| 236 | _samplEphSpinBox->setValue(settings.value("samplEph").toInt());
|
---|
| 237 | _samplEphSpinBox->setSuffix(" sec");
|
---|
[1795] | 238 |
|
---|
[1668] | 239 | // RINEX Clocks Options
|
---|
| 240 | // --------------------
|
---|
[846] | 241 | _rnxPathLineEdit = new QLineEdit(settings.value("rnxPath").toString());
|
---|
[845] | 242 | _rnxIntrComboBox = new QComboBox;
|
---|
[846] | 243 | _rnxIntrComboBox->setEditable(false);
|
---|
| 244 | _rnxIntrComboBox->addItems(QString("1 min,2 min,5 min,10 min,15 min,30 min,1 hour,1 day").split(","));
|
---|
[958] | 245 | ii = _rnxIntrComboBox->findText(settings.value("rnxIntr").toString());
|
---|
[846] | 246 | if (ii != -1) {
|
---|
| 247 | _rnxIntrComboBox->setCurrentIndex(ii);
|
---|
| 248 | }
|
---|
[845] | 249 | _rnxSamplSpinBox = new QSpinBox;
|
---|
[846] | 250 | _rnxSamplSpinBox->setMinimum(0);
|
---|
| 251 | _rnxSamplSpinBox->setMaximum(60);
|
---|
| 252 | _rnxSamplSpinBox->setSingleStep(5);
|
---|
| 253 | _rnxSamplSpinBox->setMaximumWidth(9*ww);
|
---|
| 254 | _rnxSamplSpinBox->setValue(settings.value("rnxSampl").toInt());
|
---|
| 255 | _rnxSamplSpinBox->setSuffix(" sec");
|
---|
[845] | 256 |
|
---|
[1668] | 257 | // SP3 Orbits Options
|
---|
| 258 | // ------------------
|
---|
[846] | 259 | _sp3PathLineEdit = new QLineEdit(settings.value("sp3Path").toString());
|
---|
[845] | 260 | _sp3IntrComboBox = new QComboBox;
|
---|
[846] | 261 | _sp3IntrComboBox->setEditable(false);
|
---|
| 262 | _sp3IntrComboBox->addItems(QString("1 min,2 min,5 min,10 min,15 min,30 min,1 hour,1 day").split(","));
|
---|
| 263 | ii = _sp3IntrComboBox->findText(settings.value("sp3Intr").toString());
|
---|
| 264 | if (ii != -1) {
|
---|
| 265 | _sp3IntrComboBox->setCurrentIndex(ii);
|
---|
| 266 | }
|
---|
[845] | 267 | _sp3SamplSpinBox = new QSpinBox;
|
---|
[846] | 268 | _sp3SamplSpinBox->setMinimum(0);
|
---|
[855] | 269 | _sp3SamplSpinBox->setMaximum(900);
|
---|
| 270 | _sp3SamplSpinBox->setSingleStep(60);
|
---|
[846] | 271 | _sp3SamplSpinBox->setMaximumWidth(9*ww);
|
---|
| 272 | _sp3SamplSpinBox->setValue(settings.value("sp3Sampl").toInt());
|
---|
| 273 | _sp3SamplSpinBox->setSuffix(" sec");
|
---|
[1668] | 274 |
|
---|
| 275 | // Whats This
|
---|
| 276 | // ----------
|
---|
| 277 | _proxyHostLineEdit->setWhatsThis(tr("<p>If you are running BNS within a protected Local Area Network (LAN), you might need to use a proxy server to access the Internet. Enter your proxy server IP and port number in case one is operated in front of BNS. If you do not know the IP and port of your proxy server, check the proxy server settings in your Internet browser or ask your network administrator.</p><p>Note that IP streaming is sometimes not allowed in a LAN. In this case you need to ask your network administrator for an appropriate modification of the local security policy or for the installation of a TCP relay to the NTRIP broadcasters. If these are not possible, you might need to run BNS outside your LAN on a network that has unobstructed connection to the Internet.</p>"));
|
---|
| 278 | _proxyPortLineEdit->setWhatsThis(tr("<p>Enter your proxy server port number in case one is operated in front of BNS.</p>"));
|
---|
| 279 | _logFileLineEdit->setWhatsThis(tr("<p>Records of BNS activities are shown in the Log section on the bottom of this window. They can be saved into a file when a valid path is specified in the 'Logfile (full path)' field.</p>"));
|
---|
| 280 | _fileAppendCheckBox->setWhatsThis(tr("<p>When BNS is started, new files are created by default and any existing files with the same name will be overwritten. However, users might want to append already existing files following a restart of BNS, a system crash or when BNS crashed. Tick 'Append files' to continue with existing files and keep what has been recorded so far.</p>"));
|
---|
| 281 | _inpEchoLineEdit->setWhatsThis(tr("Specify the full path to a file where incoming clocks and orbits are saved. Beware that the size of this file can rapidly increase. Default is an empty option field meaning that incoming clocks and orbits are not saved."));
|
---|
| 282 | _ephHostLineEdit->setWhatsThis(tr("BNS reads Broadcast Ephemeris in RINEX Version 3 Navigation file format from an IP address. Specify the host IP e.g. of a BNC installation providing this information."));
|
---|
| 283 | _ephPortLineEdit->setWhatsThis(tr("BNS reads Broadcast Ephemeris in RINEX Version 3 Navigation file format from an IP address. Specify the IP port e.g. of a BNC installation providing this information."));
|
---|
| 284 | _ephEchoLineEdit->setWhatsThis(tr("Specify the full path to a file where incoming Broadcast Ephemeris are saved. Beware that the size of this file can rapidly increase. Default is an empty option field meaning that incoming Broadcast Ephemeris are not saved."));
|
---|
| 285 | _clkPortLineEdit->setWhatsThis(tr("BNS reads Clocks & Orbits referring to the IGS system (X,Y,Z, ECEF) in SP3 format from an IP port. Specify a local IP port e.g. for an RTNet installation to provide this information."));
|
---|
| 286 | _outHost_1_LineEdit->setWhatsThis(tr("BNS can stream clock and orbit corrections to Broadcast Ephemeris in RTCM Version 3 format. Specify the host IP of an NTRIP Broadcaster to upload the stream. An empty option field means that you don't want to upload corrections."));
|
---|
| 287 | _outPort_1_LineEdit->setWhatsThis(tr("Specify the IP port of an NTRIP Broadcaster to upload the stream. Default is port 80."));
|
---|
[1728] | 288 | _mountpoint_1_LineEdit->setWhatsThis(tr("Specify the mounpoint for stream upload to an NTRIP Broadcaster."));
|
---|
[1668] | 289 | _password_1_LineEdit->setWhatsThis(tr("Specify the stream upload password protecting the mounpoint on an NTRIP Broadcaster."));
|
---|
| 290 | _refSys_1_ComboBox->setWhatsThis(tr("Select the target reference system for outgoing clock and orbit corrections."));
|
---|
[1728] | 291 | _outFile_1_LineEdit->setWhatsThis(tr("Specify the full path to a file where outgoing clock and orbit corrections to Broadcast Ephemeris are saved. Beware that the size of this file can rapidly increase. Default is an empty option field meaning that outgoing corrections are not saved."));
|
---|
[1668] | 292 | _outHost_2_LineEdit->setWhatsThis(tr("BNS can stream clock and orbit corrections to Broadcast Ephemeris in RTCM Version 3 format. Specify the host IP of an NTRIP Broadcaster to upload the stream. An empty option field means that you don't want to upload corrections."));
|
---|
| 293 | _outPort_2_LineEdit->setWhatsThis(tr("Specify the IP port of an NTRIP Broadcaster to upload the stream. Default is port 80."));
|
---|
[1728] | 294 | _mountpoint_2_LineEdit->setWhatsThis(tr("Specify the mounpoint for stream upload to an NTRIP Broadcaster."));
|
---|
[1668] | 295 | _password_2_LineEdit->setWhatsThis(tr("Specify the stream upload password protecting the mounpoint on an NTRIP Broadcaster."));
|
---|
| 296 | _refSys_2_ComboBox->setWhatsThis(tr("Select the target reference system for outgoing clock and orbit corrections."));
|
---|
| 297 | _outFile_2_LineEdit->setWhatsThis(tr("Specify the full path to a file where outgoing clock and orbit corrections to Broadcast Ephemeris are saved. Beware that the size of this file can rapidly increase. Default is an empty option field meaning that outgoing corrections are not saved."));
|
---|
[1728] | 298 | _outHost_3_LineEdit->setWhatsThis(tr("BNS can stream clock and orbit corrections to Broadcast Ephemeris in RTCM Version 3 format. Specify the host IP of an NTRIP Broadcaster to upload the stream. An empty option field means that you don't want to upload corrections."));
|
---|
| 299 | _outPort_3_LineEdit->setWhatsThis(tr("Specify the IP port of an NTRIP Broadcaster to upload the stream. Default is port 80."));
|
---|
| 300 | _mountpoint_3_LineEdit->setWhatsThis(tr("Specify the mounpoint for stream upload to an NTRIP Broadcaster."));
|
---|
| 301 | _password_3_LineEdit->setWhatsThis(tr("Specify the stream upload password protecting the mounpoint on an NTRIP Broadcaster."));
|
---|
| 302 | _refSys_3_ComboBox->setWhatsThis(tr("Select the target reference system for outgoing clock and orbit corrections."));
|
---|
| 303 | _outFile_3_LineEdit->setWhatsThis(tr("Specify the full path to a file where outgoing clock and orbit corrections to Broadcast Ephemeris are saved. Beware that the size of this file can rapidly increase. Default is an empty option field meaning that outgoing corrections are not saved."));
|
---|
[1803] | 304 | _outHost_Eph_LineEdit->setWhatsThis(tr("BNS can upload a Broadcast Ephemeris stream in RTCM Version 3 format. Specify the host IP of an NTRIP Broadcaster to upload the stream. An empty option field means that you don't want to upload Broadcast Ephemeris."));
|
---|
| 305 | _outPort_Eph_LineEdit->setWhatsThis(tr("Specify the IP port of an NTRIP Broadcaster to upload the stream. Default is port 80."));
|
---|
| 306 | _mountpoint_Eph_LineEdit->setWhatsThis(tr("Specify the mounpoint for stream upload to an NTRIP Broadcaster."));
|
---|
| 307 | _password_Eph_LineEdit->setWhatsThis(tr("Specify the stream upload password protecting the mounpoint on an NTRIP Broadcaster."));
|
---|
[1805] | 308 | _samplEphSpinBox->setWhatsThis(tr("Select the Broadcast Ephemeris sampling interval in seconds. Defaut is '5' meaning that a complete set of Broadcast Ephemeris is uploaded every 5 seconds."));
|
---|
[1668] | 309 | _rnxPathLineEdit->setWhatsThis(tr("Specify the path for saving the generated clock corrections as Clock RINEX files. If the specified directory does not exist, BNS will not create Clock RINEX files."));
|
---|
| 310 | _rnxIntrComboBox->setWhatsThis(tr("Select the length of the Clock RINEX file."));
|
---|
| 311 | _rnxSamplSpinBox->setWhatsThis(tr("Select the Clock RINEX file sampling interval in seconds. A value of zero '0' tells BNS to store all available samples into Clock RINEX files."));
|
---|
| 312 | _sp3PathLineEdit->setWhatsThis(tr("Specify the path for saving the generated orbit corrections as SP3 orbit files. If the specified directory does not exist, BNS will not create SP3 orbit files."));
|
---|
| 313 | _sp3IntrComboBox->setWhatsThis(tr("Select the length of the SP3 orbit file."));
|
---|
[958] | 314 | _sp3SamplSpinBox->setWhatsThis(tr("Select the SP3 orbit file sampling interval in seconds. A value of zero '0' tells BNS to store all available samples into SP3 orbit files."));
|
---|
[1668] | 315 | _autoStartCheckBox->setWhatsThis(tr("<p>Tick 'Auto start' for auto-start of BNS at startup time in window mode with preassigned processing options.</p>"));
|
---|
[2102] | 316 | _CoM_1_CheckBox->setWhatsThis(tr("<p>By default orbit and clock corrections refer to APC. Tick 'Center of Mass' to refer uploaded corrections to CoM.</p>"));
|
---|
| 317 | _CoM_2_CheckBox->setWhatsThis(tr("<p>By default orbit and clock corrections refer to APC. Tick 'Center of Mass' to refer uploaded corrections to CoM.</p>"));
|
---|
| 318 | _CoM_3_CheckBox->setWhatsThis(tr("<p>By default orbit and clock corrections refer to APC. Tick 'Center of Mass' to refer uploaded corrections to CoM.</p>"));
|
---|
[845] | 319 |
|
---|
[2102] | 320 |
|
---|
[750] | 321 | // TabWidget
|
---|
| 322 | // ---------
|
---|
[1668] | 323 | tabs = new QTabWidget();
|
---|
[813] | 324 |
|
---|
[958] | 325 | // Proxy Tab
|
---|
| 326 | // ---------
|
---|
| 327 | QWidget* tab_prx = new QWidget();
|
---|
| 328 | tabs->setMaximumHeight(20*ww);
|
---|
| 329 | tabs->addTab(tab_prx, "Proxy");
|
---|
[750] | 330 |
|
---|
[958] | 331 | QGridLayout* layout_prx = new QGridLayout;
|
---|
[1668] | 332 |
|
---|
[958] | 333 | layout_prx->setColumnMinimumWidth(0,9*ww);
|
---|
[1668] | 334 | _proxyPortLineEdit->setMaximumWidth(9*ww);
|
---|
[845] | 335 |
|
---|
[1668] | 336 | layout_prx->addWidget(new QLabel("Host"), 0, 0);
|
---|
| 337 | layout_prx->addWidget(_proxyHostLineEdit, 0, 1, 1, 10);
|
---|
| 338 | layout_prx->addWidget(new QLabel("Port"), 1, 0);
|
---|
[958] | 339 | layout_prx->addWidget(_proxyPortLineEdit, 1, 1);
|
---|
[1668] | 340 | layout_prx->addWidget(new QLabel("Settings for the proxy in protected networks, leave boxes blank if none."),2, 0, 1, 50, Qt::AlignLeft);
|
---|
[958] | 341 | layout_prx->addWidget(new QLabel(" "), 3, 0);
|
---|
[813] | 342 |
|
---|
[958] | 343 | tab_prx->setLayout(layout_prx);
|
---|
[752] | 344 |
|
---|
[1668] | 345 | connect(_proxyHostLineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 346 | this, SLOT(slotBnsTextChanged()));
|
---|
[1668] | 347 |
|
---|
[958] | 348 | // General Tab
|
---|
| 349 | // -----------
|
---|
| 350 | QWidget* tab_gen = new QWidget();
|
---|
| 351 | tabs->addTab(tab_gen, "General");
|
---|
| 352 |
|
---|
| 353 | QGridLayout* layout_gen = new QGridLayout;
|
---|
[1668] | 354 |
|
---|
[958] | 355 | layout_gen->setColumnMinimumWidth(0,9*ww);
|
---|
[1668] | 356 | _logFileLineEdit->setMaximumWidth(40*ww);
|
---|
[958] | 357 |
|
---|
[1668] | 358 | layout_gen->addWidget(new QLabel("Logfile (full path) "), 0, 0);
|
---|
| 359 | layout_gen->addWidget(_logFileLineEdit, 0, 1);
|
---|
| 360 | layout_gen->addWidget(new QLabel("Append files"), 1, 0);
|
---|
| 361 | layout_gen->addWidget(_fileAppendCheckBox, 1, 1);
|
---|
| 362 | layout_gen->addWidget(new QLabel("Auto start"), 2, 0);
|
---|
| 363 | layout_gen->addWidget(_autoStartCheckBox, 2, 1);
|
---|
| 364 | layout_gen->addWidget(new QLabel("General settings for logfile and file handling."), 3, 0, 1, 50, Qt::AlignLeft);
|
---|
[958] | 365 |
|
---|
| 366 | tab_gen->setLayout(layout_gen);
|
---|
| 367 |
|
---|
[1668] | 368 | // RINEX Ephemeris Tab
|
---|
| 369 | // -------------------
|
---|
[1083] | 370 | QWidget* tab_eph = new QWidget();
|
---|
[1084] | 371 | tabs->addTab(tab_eph, "RINEX Ephemeris");
|
---|
[958] | 372 |
|
---|
[1083] | 373 | QGridLayout* layout_eph = new QGridLayout;
|
---|
[1668] | 374 |
|
---|
[1083] | 375 | layout_eph->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 376 | _ephPortLineEdit->setMaximumWidth(9*ww);
|
---|
[958] | 377 |
|
---|
[1083] | 378 | layout_eph->addWidget(new QLabel("Host"), 0, 0);
|
---|
[1668] | 379 | layout_eph->addWidget(_ephHostLineEdit, 0, 1, 1, 10);
|
---|
[1083] | 380 | layout_eph->addWidget(new QLabel("Port"), 1, 0);
|
---|
| 381 | layout_eph->addWidget(_ephPortLineEdit, 1, 1);
|
---|
[1089] | 382 | layout_eph->addWidget(new QLabel("Save (full path)"), 2, 0);
|
---|
[1668] | 383 | layout_eph->addWidget(_ephEchoLineEdit, 2, 1, 1, 26);
|
---|
| 384 | layout_eph->addWidget(new QLabel("Read broadcast ephemeris in RINEX Version 3 Navigation format."), 3, 0, 1, 50, Qt::AlignLeft);
|
---|
[958] | 385 |
|
---|
[1083] | 386 | tab_eph->setLayout(layout_eph);
|
---|
[958] | 387 |
|
---|
[1696] | 388 | connect(_ephHostLineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 389 | this, SLOT(slotBnsTextChanged()));
|
---|
[1696] | 390 |
|
---|
[1668] | 391 | // Clocks & Orbits Tab
|
---|
| 392 | // -------------------
|
---|
[1083] | 393 | QWidget* tab_co = new QWidget();
|
---|
| 394 | tabs->addTab(tab_co,"Clocks && Orbits");
|
---|
| 395 |
|
---|
[1668] | 396 | QGridLayout* layout_co = new QGridLayout;
|
---|
[1083] | 397 |
|
---|
| 398 | layout_co->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 399 | _clkPortLineEdit->setMaximumWidth(9*ww);
|
---|
[1083] | 400 |
|
---|
| 401 | layout_co->addWidget(new QLabel("Listening port"), 0, 0);
|
---|
| 402 | layout_co->addWidget(_clkPortLineEdit, 0, 1);
|
---|
[1668] | 403 | layout_co->addWidget(new QLabel("Save (full path) "), 1, 0);
|
---|
[1083] | 404 | layout_co->addWidget(_inpEchoLineEdit, 1, 1);
|
---|
[1668] | 405 | layout_co->addWidget(new QLabel("Read clocks and orbits in SP3 format."), 2, 0, 1, 50, Qt::AlignLeft);
|
---|
[1083] | 406 | layout_co->addWidget(new QLabel(""), 3, 0);
|
---|
| 407 |
|
---|
| 408 | tab_co->setLayout(layout_co);
|
---|
| 409 |
|
---|
[1696] | 410 | connect(_clkPortLineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 411 | this, SLOT(slotBnsTextChanged()));
|
---|
[1696] | 412 |
|
---|
[1682] | 413 | // Broadcast Corrections I Tab
|
---|
[1668] | 414 | // ---------------------------
|
---|
[1249] | 415 | QWidget* tab_cas1 = new QWidget();
|
---|
[1682] | 416 | tabs->addTab(tab_cas1, "Broadcast Corrections I");
|
---|
[813] | 417 |
|
---|
[1249] | 418 | QGridLayout* layout_cas1 = new QGridLayout;
|
---|
[1668] | 419 |
|
---|
[1249] | 420 | layout_cas1->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 421 | _outPort_1_LineEdit->setMaximumWidth(9*ww);
|
---|
| 422 | _password_1_LineEdit->setMaximumWidth(9*ww);
|
---|
| 423 | _mountpoint_1_LineEdit->setMaximumWidth(12*ww);
|
---|
| 424 | _refSys_1_ComboBox->setMaximumWidth(12*ww);
|
---|
[845] | 425 |
|
---|
[1668] | 426 | layout_cas1->addWidget(new QLabel("Host"), 0, 0);
|
---|
| 427 | layout_cas1->addWidget(_outHost_1_LineEdit, 0, 1, 1, 3);
|
---|
| 428 | layout_cas1->addWidget(new QLabel(" Port"), 0, 4, Qt::AlignRight);
|
---|
[1699] | 429 | layout_cas1->addWidget(_outPort_1_LineEdit, 0, 5, 1, 10);
|
---|
[1668] | 430 | layout_cas1->addWidget(new QLabel("Mountpoint"), 1, 0);
|
---|
| 431 | layout_cas1->addWidget(_mountpoint_1_LineEdit, 1, 1);
|
---|
| 432 | layout_cas1->addWidget(new QLabel("Password"), 1, 2, Qt::AlignRight);
|
---|
| 433 | layout_cas1->addWidget(_password_1_LineEdit, 1, 3);
|
---|
| 434 | layout_cas1->addWidget(new QLabel(" "), 1, 4);
|
---|
| 435 | layout_cas1->addWidget(new QLabel(" "), 1, 5);
|
---|
| 436 | layout_cas1->addWidget(new QLabel("System"), 2, 0);
|
---|
| 437 | layout_cas1->addWidget(_refSys_1_ComboBox, 2, 1);
|
---|
| 438 | layout_cas1->addWidget(new QLabel(" Save (full path)"), 2, 2, Qt::AlignRight);
|
---|
| 439 | layout_cas1->addWidget(_outFile_1_LineEdit, 2, 3, 1, 30);
|
---|
[2048] | 440 | layout_cas1->addWidget(new QLabel("Center of Mass"), 3, 0);
|
---|
[2046] | 441 | layout_cas1->addWidget(_CoM_1_CheckBox, 3, 1);
|
---|
[1670] | 442 | layout_cas1->addWidget(new QLabel("Produce broadcast ephemeris corrections, upload to caster, reference system, local storage."), 4, 0, 1, 50);
|
---|
[1668] | 443 |
|
---|
[1249] | 444 | tab_cas1->setLayout(layout_cas1);
|
---|
[2138] | 445 |
|
---|
[1771] | 446 | connect(_refSys_1_ComboBox, SIGNAL(currentIndexChanged(const QString &)),
|
---|
| 447 | this, SLOT(customTrafo(const QString)));
|
---|
[2138] | 448 |
|
---|
[1668] | 449 | connect(_outHost_1_LineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 450 | this, SLOT(slotBnsTextChanged()));
|
---|
[1668] | 451 |
|
---|
[1682] | 452 | // Broadcast Corrections II Tab
|
---|
[1668] | 453 | // ----------------------------
|
---|
[1249] | 454 | QWidget* tab_cas2 = new QWidget();
|
---|
[1682] | 455 | tabs->addTab(tab_cas2, "Broadcast Corrections II");
|
---|
[1068] | 456 |
|
---|
[1249] | 457 | QGridLayout* layout_cas2 = new QGridLayout;
|
---|
[1668] | 458 |
|
---|
[1249] | 459 | layout_cas2->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 460 | _outPort_2_LineEdit->setMaximumWidth(9*ww);
|
---|
| 461 | _password_2_LineEdit->setMaximumWidth(9*ww);
|
---|
| 462 | _mountpoint_2_LineEdit->setMaximumWidth(12*ww);
|
---|
| 463 | _refSys_2_ComboBox->setMaximumWidth(12*ww);
|
---|
[1068] | 464 |
|
---|
[1668] | 465 | layout_cas2->addWidget(new QLabel("Host"), 0, 0);
|
---|
| 466 | layout_cas2->addWidget(_outHost_2_LineEdit, 0, 1, 1, 3);
|
---|
| 467 | layout_cas2->addWidget(new QLabel(" Port"), 0, 4, Qt::AlignRight);
|
---|
[1699] | 468 | layout_cas2->addWidget(_outPort_2_LineEdit, 0, 5, 1, 10);
|
---|
[1668] | 469 | layout_cas2->addWidget(new QLabel("Mountpoint"), 1, 0);
|
---|
| 470 | layout_cas2->addWidget(_mountpoint_2_LineEdit, 1, 1);
|
---|
| 471 | layout_cas2->addWidget(new QLabel("Password"), 1, 2, Qt::AlignRight);
|
---|
| 472 | layout_cas2->addWidget(_password_2_LineEdit, 1, 3);
|
---|
| 473 | layout_cas2->addWidget(new QLabel(" "), 1, 4);
|
---|
| 474 | layout_cas2->addWidget(new QLabel(" "), 1, 5);
|
---|
| 475 | layout_cas2->addWidget(new QLabel("System"), 2, 0);
|
---|
| 476 | layout_cas2->addWidget(_refSys_2_ComboBox, 2, 1);
|
---|
| 477 | layout_cas2->addWidget(new QLabel(" Save (full path)"), 2, 2, Qt::AlignRight);
|
---|
| 478 | layout_cas2->addWidget(_outFile_2_LineEdit, 2, 3, 1, 30);
|
---|
[2048] | 479 | layout_cas2->addWidget(new QLabel("Center of Mass"), 3, 0);
|
---|
[2046] | 480 | layout_cas2->addWidget(_CoM_2_CheckBox, 3, 1);
|
---|
[1670] | 481 | layout_cas2->addWidget(new QLabel("Produce broadcast ephemeris corrections, upload to caster, reference system, local storage."), 4, 0, 1, 50);
|
---|
[1668] | 482 |
|
---|
[1249] | 483 | tab_cas2->setLayout(layout_cas2);
|
---|
[2138] | 484 |
|
---|
[1771] | 485 | connect(_refSys_2_ComboBox, SIGNAL(currentIndexChanged(const QString &)),
|
---|
| 486 | this, SLOT(customTrafo(const QString)));
|
---|
[2138] | 487 |
|
---|
[1668] | 488 | connect(_outHost_2_LineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 489 | this, SLOT(slotBnsTextChanged()));
|
---|
[1668] | 490 |
|
---|
[1728] | 491 | // Broadcast Corrections III Tab
|
---|
| 492 | // -----------------------------
|
---|
| 493 | QWidget* tab_cas3 = new QWidget();
|
---|
| 494 | tabs->addTab(tab_cas3, "Broadcast Corrections III");
|
---|
| 495 |
|
---|
| 496 | QGridLayout* layout_cas3 = new QGridLayout;
|
---|
| 497 |
|
---|
| 498 | layout_cas3->setColumnMinimumWidth(0, 9*ww);
|
---|
| 499 | _outPort_3_LineEdit->setMaximumWidth(9*ww);
|
---|
| 500 | _password_3_LineEdit->setMaximumWidth(9*ww);
|
---|
| 501 | _mountpoint_3_LineEdit->setMaximumWidth(12*ww);
|
---|
| 502 | _refSys_3_ComboBox->setMaximumWidth(12*ww);
|
---|
| 503 |
|
---|
| 504 | layout_cas3->addWidget(new QLabel("Host"), 0, 0);
|
---|
| 505 | layout_cas3->addWidget(_outHost_3_LineEdit, 0, 1, 1, 3);
|
---|
| 506 | layout_cas3->addWidget(new QLabel(" Port"), 0, 4, Qt::AlignRight);
|
---|
| 507 | layout_cas3->addWidget(_outPort_3_LineEdit, 0, 5, 1, 10);
|
---|
| 508 | layout_cas3->addWidget(new QLabel("Mountpoint"), 1, 0);
|
---|
| 509 | layout_cas3->addWidget(_mountpoint_3_LineEdit, 1, 1);
|
---|
| 510 | layout_cas3->addWidget(new QLabel("Password"), 1, 2, Qt::AlignRight);
|
---|
| 511 | layout_cas3->addWidget(_password_3_LineEdit, 1, 3);
|
---|
| 512 | layout_cas3->addWidget(new QLabel(" "), 1, 4);
|
---|
| 513 | layout_cas3->addWidget(new QLabel(" "), 1, 5);
|
---|
| 514 | layout_cas3->addWidget(new QLabel("System"), 2, 0);
|
---|
| 515 | layout_cas3->addWidget(_refSys_3_ComboBox, 2, 1);
|
---|
| 516 | layout_cas3->addWidget(new QLabel(" Save (full path)"), 2, 2, Qt::AlignRight);
|
---|
| 517 | layout_cas3->addWidget(_outFile_3_LineEdit, 2, 3, 1, 30);
|
---|
[2048] | 518 | layout_cas3->addWidget(new QLabel("Center of Mass"), 3, 0);
|
---|
[2046] | 519 | layout_cas3->addWidget(_CoM_3_CheckBox, 3, 1);
|
---|
[1728] | 520 | layout_cas3->addWidget(new QLabel("Produce broadcast ephemeris corrections, upload to caster, reference system, local storage."), 4, 0, 1, 50);
|
---|
| 521 |
|
---|
| 522 | tab_cas3->setLayout(layout_cas3);
|
---|
[2138] | 523 |
|
---|
[1771] | 524 | connect(_refSys_3_ComboBox, SIGNAL(currentIndexChanged(const QString &)),
|
---|
| 525 | this, SLOT(customTrafo(const QString)));
|
---|
[2138] | 526 |
|
---|
[1728] | 527 | connect(_outHost_3_LineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 528 | this, SLOT(slotBnsTextChanged()));
|
---|
[1728] | 529 |
|
---|
[1795] | 530 | // Broadcast Ephemerides
|
---|
| 531 | // ---------------------
|
---|
| 532 | QWidget* tab_casEph = new QWidget();
|
---|
[1803] | 533 | tabs->addTab(tab_casEph, "Broadcast Ephemeris");
|
---|
[1795] | 534 |
|
---|
| 535 | QGridLayout* layout_casEph = new QGridLayout;
|
---|
| 536 |
|
---|
| 537 | layout_casEph->setColumnMinimumWidth(0, 9*ww);
|
---|
| 538 | _outPort_Eph_LineEdit->setMaximumWidth(9*ww);
|
---|
| 539 | _password_Eph_LineEdit->setMaximumWidth(9*ww);
|
---|
| 540 | _mountpoint_Eph_LineEdit->setMaximumWidth(12*ww);
|
---|
| 541 |
|
---|
[1803] | 542 | layout_casEph->addWidget(new QLabel("Host"), 0, 0);
|
---|
| 543 | layout_casEph->addWidget(_outHost_Eph_LineEdit, 0, 1, 1, 3);
|
---|
| 544 | layout_casEph->addWidget(new QLabel(" Port"), 0, 4, Qt::AlignRight);
|
---|
| 545 | layout_casEph->addWidget(_outPort_Eph_LineEdit, 0, 5, 1, 10);
|
---|
| 546 | layout_casEph->addWidget(new QLabel("Mountpoint "), 1, 0);
|
---|
| 547 | layout_casEph->addWidget(_mountpoint_Eph_LineEdit, 1, 1);
|
---|
| 548 | layout_casEph->addWidget(new QLabel(" Password"), 1, 2, Qt::AlignRight);
|
---|
| 549 | layout_casEph->addWidget(_password_Eph_LineEdit, 1, 3);
|
---|
[1805] | 550 | layout_casEph->addWidget(new QLabel("Sampling"), 2, 0);
|
---|
| 551 | layout_casEph->addWidget(_samplEphSpinBox, 2, 1);
|
---|
[1806] | 552 | layout_casEph->addWidget(new QLabel("Upload concatenated RTCMv3 Broadcast Ephemeris to caster."), 3, 0, 1, 50);
|
---|
[1795] | 553 |
|
---|
| 554 | tab_casEph->setLayout(layout_casEph);
|
---|
[2138] | 555 |
|
---|
[1795] | 556 | connect(_outHost_Eph_LineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 557 | this, SLOT(slotBnsTextChanged()));
|
---|
[1795] | 558 |
|
---|
[1668] | 559 | // RINEX Clocks Tab
|
---|
| 560 | // ----------------
|
---|
[845] | 561 | QWidget* tab_rin = new QWidget();
|
---|
[958] | 562 | tabs->addTab(tab_rin, "RINEX Clocks ");
|
---|
[845] | 563 |
|
---|
| 564 | QGridLayout* layout_rin = new QGridLayout;
|
---|
[1668] | 565 |
|
---|
[958] | 566 | layout_rin->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 567 | _rnxIntrComboBox->setMaximumWidth(9*ww);
|
---|
[845] | 568 |
|
---|
[958] | 569 | layout_rin->addWidget(new QLabel("Directory"), 0, 0);
|
---|
[1668] | 570 | layout_rin->addWidget(_rnxPathLineEdit, 0, 1, 1, 27);
|
---|
[958] | 571 | layout_rin->addWidget(new QLabel("Interval"), 1, 0);
|
---|
| 572 | layout_rin->addWidget(_rnxIntrComboBox, 1, 1);
|
---|
| 573 | layout_rin->addWidget(new QLabel("Sampling"), 2, 0);
|
---|
| 574 | layout_rin->addWidget(_rnxSamplSpinBox, 2, 1);
|
---|
[1668] | 575 | layout_rin->addWidget(new QLabel("Save clock corrections in Clock RINEX file format."), 3, 0, 1, 50, Qt::AlignLeft);
|
---|
| 576 | layout_rin->addWidget(new QLabel(" "), 3, 0);
|
---|
[845] | 577 |
|
---|
| 578 | tab_rin->setLayout(layout_rin);
|
---|
| 579 |
|
---|
[1668] | 580 | connect(_rnxPathLineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 581 | this, SLOT(slotBnsTextChanged()));
|
---|
[1668] | 582 |
|
---|
| 583 | // SP3 Orbits Tab
|
---|
| 584 | // --------------
|
---|
[958] | 585 | QWidget* tab_sp3 = new QWidget();
|
---|
| 586 | tabs->addTab(tab_sp3, "SP3 Orbits");
|
---|
| 587 |
|
---|
| 588 | QGridLayout* layout_sp3 = new QGridLayout;
|
---|
[1668] | 589 |
|
---|
[958] | 590 | layout_sp3->setColumnMinimumWidth(0, 9*ww);
|
---|
[1668] | 591 | _sp3IntrComboBox->setMaximumWidth(9*ww);
|
---|
[958] | 592 |
|
---|
| 593 | layout_sp3->addWidget(new QLabel("Directory"), 0, 0);
|
---|
[1668] | 594 | layout_sp3->addWidget(_sp3PathLineEdit, 0, 1, 1, 27);
|
---|
[958] | 595 | layout_sp3->addWidget(new QLabel("Interval"), 1, 0);
|
---|
| 596 | layout_sp3->addWidget(_sp3IntrComboBox, 1, 1);
|
---|
| 597 | layout_sp3->addWidget(new QLabel("Sampling"), 2, 0);
|
---|
| 598 | layout_sp3->addWidget(_sp3SamplSpinBox, 2, 1);
|
---|
[1668] | 599 | layout_sp3->addWidget(new QLabel("Save orbit corrections in SP3 file format."), 3, 0, 1, 50, Qt::AlignLeft);
|
---|
| 600 | layout_sp3->addWidget(new QLabel(" "), 3, 0);
|
---|
[958] | 601 |
|
---|
| 602 | tab_sp3->setLayout(layout_sp3);
|
---|
| 603 |
|
---|
[1668] | 604 | connect(_sp3PathLineEdit, SIGNAL(textChanged(const QString &)),
|
---|
[2138] | 605 | this, SLOT(slotBnsTextChanged()));
|
---|
[1668] | 606 |
|
---|
| 607 | tabs->setCurrentIndex(settings.value("startTab").toInt());
|
---|
| 608 |
|
---|
[750] | 609 | // Log
|
---|
| 610 | // ---
|
---|
| 611 | _log = new QTextBrowser();
|
---|
| 612 | _log->setReadOnly(true);
|
---|
| 613 | _log->setWhatsThis(tr("Records of BNS's activities are shown in the Log section."));
|
---|
| 614 |
|
---|
[1058] | 615 | // Status
|
---|
| 616 | // ------
|
---|
[1083] | 617 | _status = new QGroupBox(tr("Status"));
|
---|
[1058] | 618 | QGridLayout* layout_status = new QGridLayout;
|
---|
| 619 |
|
---|
| 620 | _statusLbl[0] = new QLabel("0 byte(s)"); _statusCnt[0] = 0;
|
---|
| 621 | _statusLbl[1] = new QLabel("0 byte(s)"); _statusCnt[1] = 0;
|
---|
| 622 | _statusLbl[2] = new QLabel("0 byte(s)"); _statusCnt[2] = 0;
|
---|
[1728] | 623 | _statusLbl[3] = new QLabel("0 byte(s)"); _statusCnt[3] = 0;
|
---|
[1803] | 624 | _statusLbl[4] = new QLabel("0 byte(s)"); _statusCnt[4] = 0;
|
---|
| 625 | _statusLbl[5] = new QLabel("0 byte(s)"); _statusCnt[5] = 0;
|
---|
| 626 | _statusLbl[6] = new QLabel("RINEX Ephemeris:");
|
---|
| 627 | _statusLbl[7] = new QLabel("Clocks & Orbits:");
|
---|
| 628 | _statusLbl[8] = new QLabel("Broadcast Corrections I:");
|
---|
| 629 | _statusLbl[9] = new QLabel("Broadcast Corrections II:");
|
---|
| 630 | _statusLbl[10] = new QLabel("Broadcast Corrections III:");
|
---|
| 631 | _statusLbl[11] = new QLabel("Broadcast Ephemeris:");
|
---|
[1058] | 632 |
|
---|
[1083] | 633 | _statusLbl[0]->setWhatsThis(tr("Status of incoming broadcast ephemeris."));
|
---|
| 634 | _statusLbl[1]->setWhatsThis(tr("Status of incoming stream of clocks and orbits."));
|
---|
[1803] | 635 | _statusLbl[2]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster I."));
|
---|
| 636 | _statusLbl[3]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster II."));
|
---|
| 637 | _statusLbl[4]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster III."));
|
---|
| 638 | _statusLbl[5]->setWhatsThis(tr("Status of outgoing Broadcast Ephemeris to NTRIP broadcaster"));
|
---|
| 639 | _statusLbl[6]->setWhatsThis(tr("Status of incoming broadcast ephemeris."));
|
---|
| 640 | _statusLbl[7]->setWhatsThis(tr("Status of incoming stream of clocks and orbits I."));
|
---|
| 641 | _statusLbl[8]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster I."));
|
---|
| 642 | _statusLbl[9]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster II."));
|
---|
| 643 | _statusLbl[10]->setWhatsThis(tr("Status of outgoing corrections stream to NTRIP broadcaster III."));
|
---|
| 644 | _statusLbl[11]->setWhatsThis(tr("Status of outgoing Broadcast Ephemeris to NTRIP broadcaster"));
|
---|
[1083] | 645 |
|
---|
[1803] | 646 | layout_status->addWidget(_statusLbl[6], 0, 0);
|
---|
| 647 | layout_status->addWidget(_statusLbl[0], 0, 1);
|
---|
| 648 | layout_status->addWidget(_statusLbl[11], 0, 2);
|
---|
| 649 | layout_status->addWidget(_statusLbl[5], 0, 3);
|
---|
| 650 | layout_status->addWidget(_statusLbl[7], 1, 0);
|
---|
| 651 | layout_status->addWidget(_statusLbl[1], 1, 1);
|
---|
| 652 | layout_status->addWidget(_statusLbl[8], 1, 2);
|
---|
| 653 | layout_status->addWidget(_statusLbl[2], 1, 3);
|
---|
| 654 | layout_status->addWidget(_statusLbl[9], 2, 2);
|
---|
| 655 | layout_status->addWidget(_statusLbl[3], 2, 3);
|
---|
| 656 | layout_status->addWidget(_statusLbl[10], 3, 2);
|
---|
| 657 | layout_status->addWidget(_statusLbl[4], 3, 3);
|
---|
[1058] | 658 | _status->setLayout(layout_status);
|
---|
| 659 |
|
---|
[750] | 660 | // Main Layout
|
---|
| 661 | // -----------
|
---|
| 662 | QVBoxLayout* mainLayout = new QVBoxLayout;
|
---|
| 663 | mainLayout->addWidget(tabs);
|
---|
| 664 | mainLayout->addWidget(_log);
|
---|
[1058] | 665 | mainLayout->addWidget(_status);
|
---|
[750] | 666 |
|
---|
| 667 | _canvas->setLayout(mainLayout);
|
---|
[1668] | 668 |
|
---|
[2138] | 669 | // Enable/Disable all Widgets
|
---|
| 670 | // --------------------------
|
---|
| 671 | slotBnsTextChanged();
|
---|
| 672 |
|
---|
[1668] | 673 | // Auto start
|
---|
| 674 | // ----------
|
---|
| 675 | if ( Qt::CheckState(settings.value("autoStart").toInt()) == Qt::Checked) {
|
---|
| 676 | slotStart();
|
---|
| 677 | }
|
---|
| 678 |
|
---|
[748] | 679 | }
|
---|
| 680 |
|
---|
| 681 | // Destructor
|
---|
| 682 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 683 | bnsWindow::~bnsWindow() {
|
---|
| 684 | }
|
---|
| 685 |
|
---|
| 686 | // Close Application gracefully
|
---|
| 687 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 688 | void bnsWindow::closeEvent(QCloseEvent* event) {
|
---|
[749] | 689 |
|
---|
| 690 | int iRet = QMessageBox::question(this, "Close", "Save Options?",
|
---|
| 691 | QMessageBox::Yes, QMessageBox::No,
|
---|
| 692 | QMessageBox::Cancel);
|
---|
| 693 |
|
---|
| 694 | if (iRet == QMessageBox::Cancel) {
|
---|
| 695 | event->ignore();
|
---|
| 696 | return;
|
---|
| 697 | }
|
---|
| 698 | else if (iRet == QMessageBox::Yes) {
|
---|
| 699 | slotSaveOptions();
|
---|
| 700 | }
|
---|
| 701 |
|
---|
[748] | 702 | QMainWindow::closeEvent(event);
|
---|
| 703 | }
|
---|
| 704 |
|
---|
[749] | 705 | // About Message
|
---|
| 706 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 707 | void bnsWindow::slotAbout() {
|
---|
| 708 | new bnsAboutDlg(0);
|
---|
| 709 | }
|
---|
| 710 |
|
---|
[1668] | 711 | // Flowchart
|
---|
[998] | 712 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 713 | void bnsWindow::slotFlowchart() {
|
---|
| 714 | new bnsFlowchartDlg(0);
|
---|
| 715 | }
|
---|
| 716 |
|
---|
[749] | 717 | // Help Window
|
---|
| 718 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 719 | void bnsWindow::slotHelp() {
|
---|
| 720 | QUrl url;
|
---|
| 721 | url.setPath(":bnshelp.html");
|
---|
| 722 | new bnsHlpDlg(0, url);
|
---|
| 723 | }
|
---|
| 724 |
|
---|
| 725 | // Select Fonts
|
---|
| 726 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 727 | void bnsWindow::slotFontSel() {
|
---|
| 728 | bool ok;
|
---|
| 729 | QFont newFont = QFontDialog::getFont(&ok, this->font(), this);
|
---|
| 730 | if (ok) {
|
---|
[1668] | 731 | bnsSettings settings;
|
---|
[749] | 732 | settings.setValue("font", newFont.toString());
|
---|
| 733 | QApplication::setFont(newFont);
|
---|
| 734 | int ww = QFontMetrics(newFont).width('w');
|
---|
[752] | 735 | setMinimumSize(77*ww, 65*ww);
|
---|
[749] | 736 | }
|
---|
| 737 | }
|
---|
| 738 |
|
---|
| 739 | // Whats This Help
|
---|
| 740 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 741 | void bnsWindow::slotWhatsThis() {
|
---|
| 742 | QWhatsThis::enterWhatsThisMode();
|
---|
| 743 | }
|
---|
| 744 |
|
---|
| 745 | // Create Menus
|
---|
| 746 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 747 | void bnsWindow::CreateMenu() {
|
---|
| 748 | _menuFile = menuBar()->addMenu(tr("&File"));
|
---|
| 749 | _menuFile->addAction(_actFontSel);
|
---|
| 750 | _menuFile->addSeparator();
|
---|
| 751 | _menuFile->addAction(_actSaveOpt);
|
---|
| 752 | _menuFile->addSeparator();
|
---|
| 753 | _menuFile->addAction(_actQuit);
|
---|
| 754 |
|
---|
| 755 | _menuHlp = menuBar()->addMenu(tr("&Help"));
|
---|
| 756 | _menuHlp->addAction(_actHelp);
|
---|
[998] | 757 | _menuHlp->addAction(_actFlowchart);
|
---|
[749] | 758 | _menuHlp->addAction(_actAbout);
|
---|
| 759 | }
|
---|
| 760 |
|
---|
| 761 | // Tool (Command) Bar
|
---|
| 762 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 763 | void bnsWindow::AddToolbar() {
|
---|
| 764 | QToolBar* toolBar = new QToolBar;
|
---|
| 765 | addToolBar(Qt::BottomToolBarArea, toolBar);
|
---|
| 766 | toolBar->setMovable(false);
|
---|
[753] | 767 | toolBar->addAction(_actStart);
|
---|
| 768 | toolBar->addAction(_actStop);
|
---|
[749] | 769 | toolBar->addWidget(new QLabel(" "));
|
---|
[753] | 770 | toolBar->addAction(_actWhatsThis);
|
---|
[749] | 771 | }
|
---|
| 772 |
|
---|
| 773 | // Save Options
|
---|
| 774 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 775 | void bnsWindow::slotSaveOptions() {
|
---|
[1668] | 776 | bnsSettings settings;
|
---|
[1249] | 777 | settings.setValue("proxyHost", _proxyHostLineEdit->text());
|
---|
| 778 | settings.setValue("proxyPort", _proxyPortLineEdit->text());
|
---|
[1728] | 779 |
|
---|
[1249] | 780 | settings.setValue("logFile", _logFileLineEdit->text());
|
---|
| 781 | settings.setValue("fileAppend", _fileAppendCheckBox->checkState());
|
---|
[1668] | 782 | settings.setValue("autoStart", _autoStartCheckBox->checkState());
|
---|
[1728] | 783 |
|
---|
[1249] | 784 | settings.setValue("ephHost", _ephHostLineEdit->text());
|
---|
| 785 | settings.setValue("ephPort", _ephPortLineEdit->text());
|
---|
| 786 | settings.setValue("ephEcho", _ephEchoLineEdit->text());
|
---|
[1728] | 787 |
|
---|
[1249] | 788 | settings.setValue("clkPort", _clkPortLineEdit->text());
|
---|
[1728] | 789 | settings.setValue("inpEcho", _inpEchoLineEdit->text());
|
---|
| 790 |
|
---|
[1249] | 791 | settings.setValue("outHost1", _outHost_1_LineEdit->text());
|
---|
| 792 | settings.setValue("outPort1", _outPort_1_LineEdit->text());
|
---|
[1728] | 793 | settings.setValue("mountpoint_1",_mountpoint_1_LineEdit->text());
|
---|
| 794 | settings.setValue("password1", _password_1_LineEdit->text());
|
---|
| 795 | settings.setValue("refSys_1", _refSys_1_ComboBox->currentText());
|
---|
| 796 | settings.setValue("outFile_1", _outFile_1_LineEdit->text());
|
---|
[2046] | 797 | settings.setValue("CoM_1", _CoM_1_CheckBox->checkState());
|
---|
[1728] | 798 |
|
---|
[1251] | 799 | settings.setValue("outHost2", _outHost_2_LineEdit->text());
|
---|
| 800 | settings.setValue("outPort2", _outPort_2_LineEdit->text());
|
---|
[1249] | 801 | settings.setValue("mountpoint_2",_mountpoint_2_LineEdit->text());
|
---|
[1728] | 802 | settings.setValue("password2", _password_2_LineEdit->text());
|
---|
| 803 | settings.setValue("refSys_2", _refSys_2_ComboBox->currentText());
|
---|
[1249] | 804 | settings.setValue("outFile_2", _outFile_2_LineEdit->text());
|
---|
[2046] | 805 | settings.setValue("CoM_2", _CoM_2_CheckBox->checkState());
|
---|
[1728] | 806 |
|
---|
| 807 | settings.setValue("outHost3", _outHost_3_LineEdit->text());
|
---|
| 808 | settings.setValue("outPort3", _outPort_3_LineEdit->text());
|
---|
| 809 | settings.setValue("mountpoint_3",_mountpoint_3_LineEdit->text());
|
---|
| 810 | settings.setValue("password3", _password_3_LineEdit->text());
|
---|
| 811 | settings.setValue("refSys_3", _refSys_3_ComboBox->currentText());
|
---|
| 812 | settings.setValue("outFile_3", _outFile_3_LineEdit->text());
|
---|
[2046] | 813 | settings.setValue("CoM_3", _CoM_3_CheckBox->checkState());
|
---|
[1795] | 814 |
|
---|
| 815 | settings.setValue("outHostEph", _outHost_Eph_LineEdit->text());
|
---|
| 816 | settings.setValue("outPortEph", _outPort_Eph_LineEdit->text());
|
---|
| 817 | settings.setValue("mountpoint_Eph",_mountpoint_Eph_LineEdit->text());
|
---|
| 818 | settings.setValue("passwordEph", _password_Eph_LineEdit->text());
|
---|
[1805] | 819 | settings.setValue("samplEph", _samplEphSpinBox->value());
|
---|
[1795] | 820 |
|
---|
[1249] | 821 | settings.setValue("rnxPath", _rnxPathLineEdit->text());
|
---|
| 822 | settings.setValue("rnxIntr", _rnxIntrComboBox->currentText());
|
---|
| 823 | settings.setValue("rnxSampl", _rnxSamplSpinBox->value());
|
---|
[1728] | 824 |
|
---|
[1249] | 825 | settings.setValue("sp3Path", _sp3PathLineEdit->text());
|
---|
| 826 | settings.setValue("sp3Intr", _sp3IntrComboBox->currentText());
|
---|
| 827 | settings.setValue("sp3Sampl", _sp3SamplSpinBox->value());
|
---|
[1728] | 828 |
|
---|
[1668] | 829 | settings.setValue("startTab", tabs->currentIndex());
|
---|
[749] | 830 | }
|
---|
| 831 |
|
---|
[750] | 832 | // Display Program Messages
|
---|
| 833 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 834 | void bnsWindow::slotMessage(const QByteArray msg) {
|
---|
| 835 |
|
---|
| 836 | const int maxBufferSize = 10000;
|
---|
| 837 |
|
---|
| 838 | QString txt = _log->toPlainText() + "\n" +
|
---|
| 839 | QDateTime::currentDateTime().toUTC().toString("yy-MM-dd hh:mm:ss ") + msg;
|
---|
| 840 | _log->clear();
|
---|
| 841 | _log->append(txt.right(maxBufferSize));
|
---|
| 842 | }
|
---|
[753] | 843 |
|
---|
[760] | 844 | // Delete bns
|
---|
| 845 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 846 | void bnsWindow::deleteBns() {
|
---|
| 847 | _actStart->setEnabled(true);
|
---|
| 848 | _actStop->setEnabled(false);
|
---|
[762] | 849 | _bns->terminate();
|
---|
[764] | 850 | _bns->wait(100);
|
---|
[760] | 851 | delete _bns;
|
---|
| 852 | _bns = 0;
|
---|
| 853 | }
|
---|
| 854 |
|
---|
| 855 | // Error in bns
|
---|
| 856 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 857 | void bnsWindow::slotError(const QByteArray msg) {
|
---|
| 858 | slotMessage(msg);
|
---|
| 859 | deleteBns();
|
---|
| 860 | }
|
---|
| 861 |
|
---|
[753] | 862 | // Stop
|
---|
| 863 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 864 | void bnsWindow::slotStop() {
|
---|
| 865 | int iRet = QMessageBox::question(this, "Stop", "Do you want to stop?",
|
---|
| 866 | QMessageBox::Yes, QMessageBox::No,
|
---|
| 867 | QMessageBox::NoButton);
|
---|
| 868 | if (iRet == QMessageBox::Yes) {
|
---|
[760] | 869 | deleteBns();
|
---|
[753] | 870 | }
|
---|
| 871 | }
|
---|
| 872 |
|
---|
| 873 | // Start
|
---|
| 874 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 875 | void bnsWindow::slotStart() {
|
---|
| 876 | slotSaveOptions();
|
---|
| 877 |
|
---|
| 878 | _actStart->setEnabled(false);
|
---|
| 879 | _actStop->setEnabled(true);
|
---|
| 880 |
|
---|
[758] | 881 | _bns = new t_bns(0);
|
---|
[760] | 882 |
|
---|
[758] | 883 | connect(_bns, SIGNAL(newMessage(QByteArray)),
|
---|
| 884 | this, SLOT(slotMessage(const QByteArray)));
|
---|
[760] | 885 |
|
---|
| 886 | connect(_bns, SIGNAL(error(QByteArray)),
|
---|
| 887 | this, SLOT(slotError(const QByteArray)));
|
---|
| 888 |
|
---|
[1058] | 889 | connect(_bns, SIGNAL(newEphBytes(int)), this, SLOT(slotEphBytes(int)));
|
---|
| 890 | connect(_bns, SIGNAL(newClkBytes(int)), this, SLOT(slotClkBytes(int)));
|
---|
[1258] | 891 | connect(_bns, SIGNAL(newOutBytes1(int)), this, SLOT(slotOutBytes1(int)));
|
---|
| 892 | connect(_bns, SIGNAL(newOutBytes2(int)), this, SLOT(slotOutBytes2(int)));
|
---|
[1728] | 893 | connect(_bns, SIGNAL(newOutBytes3(int)), this, SLOT(slotOutBytes3(int)));
|
---|
[1803] | 894 | connect(_bns, SIGNAL(newOutEphBytes(int)), this, SLOT(slotOutEphBytes(int)));
|
---|
[1058] | 895 |
|
---|
[757] | 896 | _bns->start();
|
---|
[753] | 897 | }
|
---|
[1058] | 898 |
|
---|
| 899 | // Input and output bytes statistics
|
---|
| 900 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 901 | void bnsWindow::slotEphBytes(int nBytes) {
|
---|
| 902 | updateStatus(0, nBytes);
|
---|
| 903 | }
|
---|
| 904 | void bnsWindow::slotClkBytes(int nBytes) {
|
---|
| 905 | updateStatus(1, nBytes);
|
---|
| 906 | }
|
---|
[1258] | 907 | void bnsWindow::slotOutBytes1(int nBytes) {
|
---|
[1058] | 908 | updateStatus(2, nBytes);
|
---|
| 909 | }
|
---|
[1258] | 910 | void bnsWindow::slotOutBytes2(int nBytes) {
|
---|
| 911 | updateStatus(3, nBytes);
|
---|
| 912 | }
|
---|
[1728] | 913 | void bnsWindow::slotOutBytes3(int nBytes) {
|
---|
| 914 | updateStatus(4, nBytes);
|
---|
| 915 | }
|
---|
[1803] | 916 | void bnsWindow::slotOutEphBytes(int nBytes) {
|
---|
| 917 | updateStatus(5, nBytes);
|
---|
| 918 | }
|
---|
[1058] | 919 |
|
---|
| 920 | void bnsWindow::updateStatus(int ii, int nBytes) {
|
---|
| 921 | QMutexLocker locker(&_mutex);
|
---|
| 922 |
|
---|
| 923 | _statusCnt[ii] += nBytes;
|
---|
| 924 |
|
---|
| 925 | if (_statusCnt[ii] < 1e3) {
|
---|
| 926 | _statusLbl[ii]->setText(QString("%1 byte(s)").arg((int)_statusCnt[ii]));
|
---|
| 927 | }
|
---|
| 928 | else if (_statusCnt[ii] < 1e6) {
|
---|
| 929 | _statusLbl[ii]->setText(QString("%1 kb").arg(_statusCnt[ii]/1.e3, 5));
|
---|
| 930 | }
|
---|
| 931 | else {
|
---|
| 932 | _statusLbl[ii]->setText(QString("%1 Mb").arg(_statusCnt[ii]/1.e6, 5));
|
---|
| 933 | }
|
---|
| 934 | }
|
---|
[1668] | 935 |
|
---|
[2138] | 936 | // Enable/Disable Widgets according to user input
|
---|
[1668] | 937 | ////////////////////////////////////////////////////////////////////////////
|
---|
[2138] | 938 | void bnsWindow::slotBnsTextChanged(){
|
---|
[1668] | 939 |
|
---|
[2138] | 940 | QPalette palette_white(QColor(255, 255, 255));
|
---|
| 941 | QPalette palette_gray(QColor(230, 230, 230));
|
---|
[1668] | 942 |
|
---|
| 943 | // Enable/disable Proxy Options
|
---|
[1696] | 944 | // ----------------------------
|
---|
[2138] | 945 | if (sender() == 0 || sender() == _proxyHostLineEdit) {
|
---|
| 946 | if (!_proxyHostLineEdit->text().isEmpty()) {
|
---|
[1668] | 947 | _proxyPortLineEdit->setStyleSheet("background-color: white");
|
---|
| 948 | _proxyPortLineEdit->setEnabled(true);
|
---|
[2138] | 949 | }
|
---|
| 950 | else {
|
---|
[1668] | 951 | _proxyPortLineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 952 | _proxyPortLineEdit->setEnabled(false);
|
---|
| 953 | }
|
---|
| 954 | }
|
---|
| 955 |
|
---|
[1696] | 956 | // Enable/disable RINEX Ephemeris Options
|
---|
| 957 | // --------------------------------------
|
---|
[2138] | 958 | if (sender() == 0 || sender() == _ephHostLineEdit) {
|
---|
| 959 | if (!_ephHostLineEdit->text().isEmpty()) {
|
---|
| 960 | _ephPortLineEdit->setStyleSheet("background-color: white");
|
---|
| 961 | _ephEchoLineEdit->setStyleSheet("background-color: white");
|
---|
| 962 | _ephPortLineEdit->setEnabled(true);
|
---|
| 963 | _ephEchoLineEdit->setEnabled(true);
|
---|
| 964 | }
|
---|
| 965 | else {
|
---|
| 966 | _ephPortLineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 967 | _ephEchoLineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 968 | _ephPortLineEdit->setEnabled(false);
|
---|
| 969 | _ephEchoLineEdit->setEnabled(false);
|
---|
[1696] | 970 | }
|
---|
| 971 | }
|
---|
| 972 |
|
---|
| 973 | // Enable/disable Clocks & Orbits Options
|
---|
| 974 | // --------------------------------------
|
---|
[2138] | 975 | if (sender() == 0 || sender() == _clkPortLineEdit) {
|
---|
| 976 | if (!_clkPortLineEdit->text().isEmpty()) {
|
---|
| 977 | _inpEchoLineEdit->setStyleSheet("background-color: white");
|
---|
| 978 | _inpEchoLineEdit->setEnabled(true);
|
---|
| 979 | }
|
---|
| 980 | else {
|
---|
| 981 | _inpEchoLineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 982 | _inpEchoLineEdit->setEnabled(false);
|
---|
[1696] | 983 | }
|
---|
| 984 | }
|
---|
| 985 |
|
---|
[1682] | 986 | // Enable/disable Broadcast Corrections I Options
|
---|
[1668] | 987 | // -----------------------------------------------
|
---|
[2138] | 988 | if (sender() == 0 || sender() == _outHost_1_LineEdit) {
|
---|
| 989 | if (!_outHost_1_LineEdit->text().isEmpty()) {
|
---|
[1668] | 990 | _outPort_1_LineEdit->setStyleSheet("background-color: white");
|
---|
| 991 | _mountpoint_1_LineEdit->setStyleSheet("background-color: white");
|
---|
| 992 | _password_1_LineEdit->setStyleSheet("background-color: white");
|
---|
| 993 | _outFile_1_LineEdit->setStyleSheet("background-color: white");
|
---|
| 994 | _refSys_1_ComboBox->setStyleSheet("background-color: white");
|
---|
[2138] | 995 | _CoM_1_CheckBox->setPalette(palette_white);
|
---|
[1668] | 996 | _outPort_1_LineEdit->setEnabled(true);
|
---|
| 997 | _mountpoint_1_LineEdit->setEnabled(true);
|
---|
| 998 | _password_1_LineEdit->setEnabled(true);
|
---|
| 999 | _outFile_1_LineEdit->setEnabled(true);
|
---|
| 1000 | _refSys_1_ComboBox->setEnabled(true);
|
---|
[2046] | 1001 | _CoM_1_CheckBox->setEnabled(true);
|
---|
[2138] | 1002 | }
|
---|
| 1003 | else {
|
---|
[1668] | 1004 | _outPort_1_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1005 | _mountpoint_1_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1006 | _password_1_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1007 | _outFile_1_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1008 | _refSys_1_ComboBox->setStyleSheet("background-color: lightGray");
|
---|
[2138] | 1009 | _CoM_1_CheckBox->setPalette(palette_gray);
|
---|
[1668] | 1010 | _outPort_1_LineEdit->setEnabled(false);
|
---|
| 1011 | _mountpoint_1_LineEdit->setEnabled(false);
|
---|
| 1012 | _password_1_LineEdit->setEnabled(false);
|
---|
| 1013 | _outFile_1_LineEdit->setEnabled(false);
|
---|
| 1014 | _refSys_1_ComboBox->setEnabled(false);
|
---|
[2046] | 1015 | _CoM_1_CheckBox->setEnabled(false);
|
---|
[1668] | 1016 | }
|
---|
| 1017 | }
|
---|
| 1018 |
|
---|
[1682] | 1019 | // Enable/disable Broadcast Corrections II Options
|
---|
[1668] | 1020 | // -----------------------------------------------
|
---|
[2138] | 1021 | if (sender() == 0 || sender() == _outHost_2_LineEdit) {
|
---|
| 1022 | if (!_outHost_2_LineEdit->text().isEmpty()) {
|
---|
[1668] | 1023 | _outPort_2_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1024 | _mountpoint_2_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1025 | _password_2_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1026 | _outFile_2_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1027 | _refSys_2_ComboBox->setStyleSheet("background-color: white");
|
---|
[2138] | 1028 | _CoM_2_CheckBox->setPalette(palette_white);
|
---|
[1668] | 1029 | _outPort_2_LineEdit->setEnabled(true);
|
---|
| 1030 | _mountpoint_2_LineEdit->setEnabled(true);
|
---|
| 1031 | _password_2_LineEdit->setEnabled(true);
|
---|
| 1032 | _outFile_2_LineEdit->setEnabled(true);
|
---|
| 1033 | _refSys_2_ComboBox->setEnabled(true);
|
---|
[2046] | 1034 | _CoM_2_CheckBox->setEnabled(true);
|
---|
[2138] | 1035 | }
|
---|
| 1036 | else {
|
---|
[1668] | 1037 | _outPort_2_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1038 | _mountpoint_2_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1039 | _password_2_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1040 | _outFile_2_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1041 | _refSys_2_ComboBox->setStyleSheet("background-color: lightGray");
|
---|
[2138] | 1042 | _CoM_2_CheckBox->setPalette(palette_gray);
|
---|
[1668] | 1043 | _outPort_2_LineEdit->setEnabled(false);
|
---|
| 1044 | _mountpoint_2_LineEdit->setEnabled(false);
|
---|
| 1045 | _password_2_LineEdit->setEnabled(false);
|
---|
| 1046 | _outFile_2_LineEdit->setEnabled(false);
|
---|
| 1047 | _refSys_2_ComboBox->setEnabled(false);
|
---|
[2046] | 1048 | _CoM_2_CheckBox->setEnabled(false);
|
---|
[1668] | 1049 | }
|
---|
| 1050 | }
|
---|
| 1051 |
|
---|
[1728] | 1052 | // Enable/disable Broadcast Corrections III Options
|
---|
| 1053 | // -----------------------------------------------
|
---|
[2138] | 1054 | if (sender() == 0 || sender() == _outHost_3_LineEdit) {
|
---|
| 1055 | if (!_outHost_3_LineEdit->text().isEmpty()) {
|
---|
[1728] | 1056 | _outPort_3_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1057 | _mountpoint_3_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1058 | _password_3_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1059 | _outFile_3_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1060 | _refSys_3_ComboBox->setStyleSheet("background-color: white");
|
---|
[2138] | 1061 | _CoM_3_CheckBox->setPalette(palette_white);
|
---|
[1728] | 1062 | _outPort_3_LineEdit->setEnabled(true);
|
---|
| 1063 | _mountpoint_3_LineEdit->setEnabled(true);
|
---|
| 1064 | _password_3_LineEdit->setEnabled(true);
|
---|
| 1065 | _outFile_3_LineEdit->setEnabled(true);
|
---|
| 1066 | _refSys_3_ComboBox->setEnabled(true);
|
---|
[2046] | 1067 | _CoM_3_CheckBox->setEnabled(true);
|
---|
[2138] | 1068 | }
|
---|
| 1069 | else {
|
---|
[1728] | 1070 | _outPort_3_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1071 | _mountpoint_3_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1072 | _password_3_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1073 | _outFile_3_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1074 | _refSys_3_ComboBox->setStyleSheet("background-color: lightGray");
|
---|
[2138] | 1075 | _CoM_3_CheckBox->setPalette(palette_gray);
|
---|
[1728] | 1076 | _outPort_3_LineEdit->setEnabled(false);
|
---|
| 1077 | _mountpoint_3_LineEdit->setEnabled(false);
|
---|
| 1078 | _password_3_LineEdit->setEnabled(false);
|
---|
| 1079 | _outFile_3_LineEdit->setEnabled(false);
|
---|
| 1080 | _refSys_3_ComboBox->setEnabled(false);
|
---|
[2046] | 1081 | _CoM_3_CheckBox->setEnabled(false);
|
---|
[1728] | 1082 | }
|
---|
| 1083 | }
|
---|
| 1084 |
|
---|
[1795] | 1085 | // Enable/disable Broadcast Ephemerides
|
---|
[1803] | 1086 | // ------------------------------------
|
---|
[2138] | 1087 | if (sender() == 0 || sender() == _outHost_Eph_LineEdit) {
|
---|
| 1088 | if (!_outHost_Eph_LineEdit->text().isEmpty()) {
|
---|
[1795] | 1089 | _outPort_Eph_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1090 | _mountpoint_Eph_LineEdit->setStyleSheet("background-color: white");
|
---|
| 1091 | _password_Eph_LineEdit->setStyleSheet("background-color: white");
|
---|
[1805] | 1092 | _samplEphSpinBox->setStyleSheet("background-color: white");
|
---|
[1795] | 1093 | _outPort_Eph_LineEdit->setEnabled(true);
|
---|
| 1094 | _mountpoint_Eph_LineEdit->setEnabled(true);
|
---|
| 1095 | _password_Eph_LineEdit->setEnabled(true);
|
---|
[1805] | 1096 | _samplEphSpinBox->setEnabled(true);
|
---|
[2138] | 1097 | }
|
---|
| 1098 | else {
|
---|
[1795] | 1099 | _outPort_Eph_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1100 | _mountpoint_Eph_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
| 1101 | _password_Eph_LineEdit->setStyleSheet("background-color: lightGray");
|
---|
[1805] | 1102 | _samplEphSpinBox->setStyleSheet("background-color: lightGray");
|
---|
[1795] | 1103 | _outPort_Eph_LineEdit->setEnabled(false);
|
---|
| 1104 | _mountpoint_Eph_LineEdit->setEnabled(false);
|
---|
| 1105 | _password_Eph_LineEdit->setEnabled(false);
|
---|
[1805] | 1106 | _samplEphSpinBox->setEnabled(false);
|
---|
[1795] | 1107 | }
|
---|
| 1108 | }
|
---|
| 1109 |
|
---|
[1668] | 1110 | // Enable/disable RINEX Clocks Options
|
---|
| 1111 | // -----------------------------------
|
---|
[2138] | 1112 | if (sender() == 0 || sender() == _rnxPathLineEdit) {
|
---|
| 1113 | if (!_rnxPathLineEdit->text().isEmpty()) {
|
---|
[1668] | 1114 | _rnxIntrComboBox->setStyleSheet("background-color: white");
|
---|
| 1115 | _rnxSamplSpinBox->setStyleSheet("background-color: white");
|
---|
| 1116 | _rnxIntrComboBox->setEnabled(true);
|
---|
| 1117 | _rnxSamplSpinBox->setEnabled(true);
|
---|
[2138] | 1118 | }
|
---|
| 1119 | else {
|
---|
[1668] | 1120 | _rnxIntrComboBox->setStyleSheet("background-color: lightGray");
|
---|
| 1121 | _rnxSamplSpinBox->setStyleSheet("background-color: lightGray");
|
---|
| 1122 | _rnxIntrComboBox->setEnabled(false);
|
---|
| 1123 | _rnxSamplSpinBox->setEnabled(false);
|
---|
| 1124 | }
|
---|
| 1125 | }
|
---|
| 1126 |
|
---|
| 1127 | // Enable/disable SP3 Orbits Options
|
---|
| 1128 | // ---------------------------------
|
---|
[2138] | 1129 | if (sender() == 0 || sender() == _sp3PathLineEdit) {
|
---|
| 1130 | if (!_sp3PathLineEdit->text().isEmpty()) {
|
---|
[1668] | 1131 | _sp3IntrComboBox->setStyleSheet("background-color: white");
|
---|
| 1132 | _sp3SamplSpinBox->setStyleSheet("background-color: white");
|
---|
| 1133 | _sp3IntrComboBox->setEnabled(true);
|
---|
| 1134 | _sp3SamplSpinBox->setEnabled(true);
|
---|
[2138] | 1135 | }
|
---|
| 1136 | else {
|
---|
[1668] | 1137 | _sp3IntrComboBox->setStyleSheet("background-color: lightGray");
|
---|
| 1138 | _sp3SamplSpinBox->setStyleSheet("background-color: lightGray");
|
---|
| 1139 | _sp3IntrComboBox->setEnabled(false);
|
---|
| 1140 | _sp3SamplSpinBox->setEnabled(false);
|
---|
| 1141 | }
|
---|
| 1142 | }
|
---|
| 1143 |
|
---|
| 1144 | }
|
---|
[1771] | 1145 |
|
---|
| 1146 | // Custom transformation parameters
|
---|
| 1147 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 1148 | void bnsWindow::customTrafo(const QString &text){
|
---|
| 1149 | if (text == "Custom" ) {
|
---|
| 1150 | bnsCustomTrafo* dlg = new bnsCustomTrafo(this);
|
---|
| 1151 | dlg->exec();
|
---|
| 1152 | delete dlg;
|
---|
| 1153 | }
|
---|
| 1154 | }
|
---|
| 1155 |
|
---|