- Timestamp:
- Jan 28, 2008, 3:50:05 PM (17 years ago)
- Location:
- trunk/BNC
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/RTCM3/RTCM3Decoder.cpp
r649 r658 90 90 t_irc RTCM3Decoder::Decode(char* buffer, int bufLen) { 91 91 92 bool decoded = false; 93 92 94 for (int ii = 0; ii < bufLen; ii++) { 93 95 … … 100 102 // ----------------- 101 103 if (rr == 1 || rr == 2) { 104 decoded = true; 102 105 103 106 if (!_Parser.init) { … … 185 188 // ------------- 186 189 else if (rr == 1019) { 190 decoded = true; 187 191 gpsephemeris* ep = new gpsephemeris(_Parser.ephemerisGPS); 188 192 emit _ephSender.newGPSEph(ep); … … 192 196 // ----------------- 193 197 else if (rr == 1020) { 198 decoded = true; 194 199 glonassephemeris* ep = new glonassephemeris(_Parser.ephemerisGLONASS); 195 200 emit _ephSender.newGlonassEph(ep); … … 198 203 } 199 204 } 205 if (!decoded) { 206 return failure; 207 } 208 else { 200 209 return success; 201 } 210 } 211 } -
trunk/BNC/bnc.pro
r635 r658 2 2 # Switch to debug configuration 3 3 # ----------------------------- 4 ###CONFIG -= release5 ###CONFIG += debug4 CONFIG -= release 5 CONFIG += debug 6 6 7 7 DEFINES += NO_RTCM3_MAIN -
trunk/BNC/bncgetthread.cpp
r657 r658 103 103 _staID = _staID.left(_staID.length()-1) + QString("%1").arg(num).toAscii(); 104 104 } 105 106 // Notice threshold 107 // ---------------- 108 _inspSegm = settings.value("inspSegm").toInt(); 109 _noticeFail = settings.value("noticeFail").toInt(); 110 _noticeReco = settings.value("noticeReco").toInt(); 111 _noticeScript = settings.value("noticeScript").toString(); 112 expandEnvVar(_noticeScript); 105 113 106 114 // RINEX writer … … 374 382 } 375 383 384 bool decode = true; 385 int numSucc = 0; 386 int secSucc = 0; 387 int secFail = 0; 388 int initPause = 30; 389 int currPause = 0; 390 bool begCorrupt = false; 391 bool endCorrupt = false; 392 _decodeTime = QDateTime::currentDateTime(); 393 394 if (initPause < _inspSegm) { 395 initPause = _inspSegm; 396 } 397 if ( _noticeFail < 1 && _noticeReco < 1 ) { 398 initPause = 0; 399 } 400 currPause = initPause; 401 376 402 // Read Incoming Data 377 403 // ------------------ … … 397 423 _socket->read(data, nBytes); 398 424 399 if ( !_decodeFailure.isValid() || 400 _decodeFailure.secsTo(QDateTime::currentDateTime()) > 60 ) { 401 if ( _decoder->Decode(data, nBytes) == success ) { 402 _decodeFailure.setDate(QDate()); 403 _decodeFailure.setTime(QTime()); 404 } 405 else { 406 _decodeFailure = QDateTime::currentDateTime(); 425 if (_inspSegm<1) { 426 _decoder->Decode(data, nBytes); 427 } 428 else { 429 430 // Decode data 431 // ----------- 432 if (!_decodePause.isValid() || 433 _decodePause.secsTo(QDateTime::currentDateTime()) >= currPause ) { 434 435 if (decode) { 436 if ( _decoder->Decode(data, nBytes) == success ) { 437 numSucc += 1; 438 } 439 if ( _decodeTime.secsTo(QDateTime::currentDateTime()) > _inspSegm ) { 440 decode = false; 441 } 442 } 443 444 // Check - once per inspect segment 445 // -------------------------------- 446 if (!decode) { 447 _decodeTime = QDateTime::currentDateTime(); 448 if (numSucc>0) { 449 secSucc += _inspSegm; 450 if (secSucc > _noticeReco * 60) { 451 secSucc = _noticeReco * 60 + 1; 452 } 453 numSucc = 0; 454 currPause = initPause; 455 _decodePause.setDate(QDate()); 456 _decodePause.setTime(QTime()); 457 } 458 else { 459 secFail += _inspSegm; 460 secSucc = 0; 461 if (secFail > _noticeFail * 60) { 462 secFail = _noticeFail * 60 + 1; 463 } 464 if (!_decodePause.isValid()) { 465 _decodePause = QDateTime::currentDateTime(); 466 } 467 else { 468 _decodePause.setDate(QDate()); 469 _decodePause.setTime(QTime()); 470 secFail = secFail + currPause - _inspSegm; 471 currPause = currPause * 2; 472 if (currPause > 960) { 473 currPause = 960; 474 } 475 } 476 } 477 478 // End corrupt threshold 479 // --------------------- 480 if ( begCorrupt && !endCorrupt && secSucc > _noticeReco * 60 ) { 481 emit(newMessage(_staID + ": End_Corrupted threshold exceeded")); 482 callScript("End_Corrupted"); 483 endCorrupt = true; 484 begCorrupt = false; 485 secFail = 0; 486 } 487 else { 488 489 // Begin corrupt threshold 490 // ----------------------- 491 if ( !begCorrupt && secFail > _noticeFail * 60 ) { 492 emit(newMessage(_staID + ": Begin_Corrupted threshold exceeded")); 493 callScript("Begin_Corrupted"); 494 begCorrupt = true; 495 endCorrupt = false; 496 secSucc = 0; 497 numSucc = 0; 498 } 499 } 500 decode = true; 407 501 } 408 502 } 409 else { 410 if ( _decodeFailure.isValid() && 411 _decodeFailure.secsTo(QDateTime::currentDateTime()) < 5 && 412 _decoder->Decode(data, nBytes) == success ) { 413 _decodeFailure.setDate(QDate()); 414 _decodeFailure.setTime(QTime()); 415 } 416 } 503 } 504 505 // End outage threshold 506 // -------------------- 507 if ( _decodeStart.isValid() && _decodeStart.secsTo(QDateTime::currentDateTime()) > _noticeReco * 60 ) { 508 _decodeStart.setDate(QDate()); 509 _decodeStart.setTime(QTime()); 510 emit(newMessage(_staID + ": End_Outage threshold exceeded")); 511 callScript("End_Outage"); 512 } 417 513 418 514 delete [] data; … … 425 521 // ----------------------- 426 522 int week; 523 bool wrongEpoch = false; 427 524 double sec; 428 525 currentGPSWeeks(week, sec); … … 441 538 double dt = fabs(sec - obs->_o.GPSWeeks); 442 539 if (week != obs->_o.GPSWeek || dt > maxDt) { 443 emit( newMessage("Wrong observation epoch") ); 540 if (!wrongEpoch) { 541 emit( newMessage(_staID + ": Wrong observation epoch") ); 542 wrongEpoch = true; 543 } 444 544 delete obs; 445 545 continue; 546 } 547 else { 548 wrongEpoch = false; 446 549 } 447 550 … … 491 594 _rnx->setReconnectFlag(true); 492 595 } 596 if ( !_decodeStart.isValid()) { 597 _decodeStop = QDateTime::currentDateTime(); 598 } 493 599 while (1) { 494 600 delete _socket; _socket = 0; 495 601 sleep(_nextSleep); 496 602 if ( initRun() == success ) { 603 if ( !_decodeStop.isValid()) { 604 _decodeStart = QDateTime::currentDateTime(); 605 } 497 606 break; 498 607 } 499 608 else { 609 610 // Begin outage threshold 611 // ---------------------- 612 if ( _decodeStop.isValid() && _decodeStop.secsTo(QDateTime::currentDateTime()) > _noticeFail * 60 ) { 613 _decodeStop.setDate(QDate()); 614 _decodeStop.setTime(QTime()); 615 emit(newMessage(_staID + ": Begin_Outage threshold exceeded")); 616 callScript("Begin_Outage"); 617 } 500 618 _nextSleep *= 2; 501 619 if (_nextSleep > 256) { … … 507 625 _nextSleep = 1; 508 626 } 627 628 // Call notice advisory script 629 //////////////////////////////////////////////////////////////////////////// 630 void bncGetThread::callScript(const char* _comment) { 631 if (!_noticeScript.isEmpty()) { 632 #ifdef WIN32 633 QProcess::startDetached(_noticeScript, QStringList() << _staID << _comment) ; 634 #else 635 QProcess::startDetached("nohup", QStringList() << _noticeScript << _staID << _comment) ; 636 #endif 637 } 638 } -
trunk/BNC/bncgetthread.h
r651 r658 65 65 void exit(int exitCode = 0); 66 66 void tryReconnect(); 67 void callScript(const char* _comment); 67 68 GPSDecoder* _decoder; 68 69 QTcpSocket* _socket; … … 74 75 QByteArray _longitude; 75 76 QByteArray _nmea; 77 QString _noticeScript; 78 int _inspSegm; 79 int _noticeFail; 80 int _noticeReco; 76 81 int _timeOut; 77 82 int _nextSleep; … … 80 85 bncRinex* _rnx; 81 86 QDateTime _decodeFailure; 87 QDateTime _decodeStart; 88 QDateTime _decodeStop; 89 QDateTime _decodePause; 90 QDateTime _decodeTime; 82 91 }; 83 92 -
trunk/BNC/bnchelp.html
r644 r658 77 77 3.6.2. <a href=#ephvers>RINEX Version</a><br> 78 78 3.6.3. <a href=#ephinterval>Ephemeris File Interval</a><br> 79 3.7. <a href=#mountpoints>Mountpoints</a><br> 80 3.7.1. <a href=#AddMounts>Add Mountpoints</a><br> 81 3.7.2. <a href=#HostPort>Broadcaster Host and Port</a><br> 82 3.7.3. <a href=#account>Broadcaster User and Password</a><br> 83 3.7.4. <a href=#GetTable>Get Table</a><br> 84 3.7.5. <a href=#delete>Delete Mountpoints</a><br> 85 3.7.6. <a href=#edit>Edit Mountpoints</a><br> 86 3.8. <a href=#log>Log</a><br> 87 3.9. <a href=#start>Start</a><br> 88 3.10. <a href=#stop>Stop</a><br> 89 3.11. <a href=#nw>No Window</a> 79 3.7. <a href=#thresholds>Notice Advisories</a><br> 80 3.7.1. <a href=#threshFail>Failure Threshold</a><br> 81 3.7.2. <a href=#threshReco>Recovery Threshold</a><br> 82 3.7.3. <a href=#inspectSegm>Inspect Segment</a><br> 83 3.7.4. <a href=#noteScript>Notice Script</a><br> 84 3.8. <a href=#mountpoints>Mountpoints</a><br> 85 3.8.1. <a href=#AddMounts>Add Mountpoints</a><br> 86 3.8.2. <a href=#HostPort>Broadcaster Host and Port</a><br> 87 3.8.3. <a href=#account>Broadcaster User and Password</a><br> 88 3.8.4. <a href=#GetTable>Get Table</a><br> 89 3.8.5. <a href=#delete>Delete Mountpoints</a><br> 90 3.8.6. <a href=#edit>Edit Mountpoints</a><br> 91 3.9. <a href=#log>Log</a><br> 92 3.10. <a href=#start>Start</a><br> 93 3.11. <a href=#stop>Stop</a><br> 94 3.12. <a href=#nw>No Window</a> 90 95 </p> 91 96 … … 354 359 </p> 355 360 356 <p><a name="mountpoints"><h4>3.7. Mountpoints</h4></p> 361 <p><a name="thresholds"><h4>3.7. Notice Advisories</h4></p> 362 <p> 363 It may happen at any time that a stream becomes unavailable or corrupted. Understanding problem situations is of importance for BNC's operator as well as for the affected stream providers so that maintenance efforts can be initiated. Furthermore, continuously trying to decode a corrupted stream can generate an unnecessary workload for BNC. 364 </p> 365 <p> 366 <u>Stream outages:</u> Connection to an NTRIP broadcaster can sometimes be disrupted or a stream requested may temporarily be unavailable. Connection is defined by BNC as broken if no data is coming in for a period of 20 seconds. When this occurs, reconnects are attempted at decreasing rate. BNC first attempts to reconnect with ~1 second lag, if unsuccessful, again in ~2 seconds since the previous attempt. If it is still unsuccessful, it will attempt to reconnect within ~4 seconds since the previous attempt etc. Each attempt doubles the wait time from the previous attempt. The maximum delay between attempts is limited to ~256 seconds. This reconnection process is documented in the 'Log' file/section. 367 </p> 368 <p> 369 <u>Stream corruption:</u> Not each transfer of a chunk of bits (as received) to BNC's internal decoders necessarily results in the return of valid observations. It may need several chunks till the next observation can be derived. Hence BNC collects all returns (success or failure) coming from a decoder within a certain short 'Inspect segment' time span to then decide whether a stream content is okay or not. When a stream is corrupted, the decoding process can be stopped temporarily. Decodings are tried again at decreasing rate. BNC first attempts to decode again after a 30 second lag, if unsuccessful, again in 60 seconds since the previous attempt. If it is still unsuccessful, it will attempt to decode after 120 seconds since the previous attempt etc. Each decoding attempt doubles the wait time from the previous attempt. The maximum delay between attempts is limited to 960 seconds. 370 </p> 371 <p> 372 If a persistent stream failure or recovery caused by a stream outage or corruption exceeds the 'Failure' or 'Recovery' threshold, BNC can inform its users about this event. The information becomes available in the 'Log' file/section as a 'Begin_Outage', 'End_Outage', 'Begin_Corrupted', or 'End_Corrupted' message. It can also be passed on as a Notice advisory to a 'Notice script' or batch file to keep BNC's operator or affected stream providers up-to-date by email. This functionality lets you use BNC as a real-time performance monitor and alarm system for the network of GNSS reference stations in use. 373 </p> 374 375 <p><a name="threshFail"><h4>3.7.1 Failure Threshold - optional</h4></p> 376 <p>A Notice advisory is generated if no or only corrupted observations are received throughout the 'Failure' threshold time span. Specifying a value of 15 min (default) is recommendable to not bother a BNC user with too much information. 377 </p> 378 <p> 379 Note that specifying a value of zero '0' for both, the 'Failure' and the 'Recovery' threshold means that BNC immediately informs about any failure/recovery and that decoding efforts shall never pause. 380 </p> 381 <p> 382 Note further that using this function for corrupted streams needs an 'Inspect segment' greater zero '0'. 383 </p> 384 385 <p><a name="threshReco"><h4>3.7.2 Recovery Threshold - optional</h4></p> 386 <p> 387 Following a longer lasting stream outage or series of completely corrupted observations, a Notice advisory is generated as soon as a valid observation is received again at least once within the 'Recovery' threshold time span. Specifying a value of 5 min (default) is recommendable to not bother a BNC user with too much information. 388 </p> 389 <p> 390 Note that specifying a value of zero '0' for both, the 'Failure' and the 'Recovery' threshold means that BNC immediately informs about any failure/recovery and that decoding efforts shall never pause. 391 </p> 392 <p> 393 Note further that using this function for corrupted streams needs an 'Inspect segment' greater zero '0'. 394 </p> 395 396 <p><a name="inspectSegm"><h4>3.7.3 Inspect Segment - mandatory for 'Failure' and 'Recovery' thresholds</h4></p> 397 <p> 398 BNC can collect all returns (failure or success) coming from a decoder within a short 'Inspect segment' time span to then decide whether a stream content is corrupted or not. If a continuous problem (or recovery) is detected, BNC informs about this event. A value of about 15 sec (default) as 'Inspect segment' is recommended when handling 1Hz data. If this value is specified too small, temporary communication bottlenecks my lead to an additional loss of some data of the affected stream. 399 </p> 400 <p> 401 Specifying a value of zero '0' means that you by-pass BNC's corruption check. However, this may result in an additional workload in case of long-lasting stream corruptions. Note that specifying an 'Inspect segment' greater zero '0' is mandatory to generate Notice advisories informing about corrupted streams. 402 </p> 403 404 <p><a name="noteScript"><h4>3.7.4 Notice Script - optional </h4></p> 405 <p> 406 Specify the full path to a script or batch file to handle Notice advisories generated in case of outages or currupted streams. The affected mountpoint and of a comment 'Begin_Outage', 'End_Outage', 'Begin_Currupted', or 'End_Corrupted' are transfered to the script as command line parameters (%1 and %2 on Windows systems, $1 and $2 on Unix/Linux systems). 407 </p><p>The script may contain commands to archive outage/corrupt information or to send an email to BNC's operator and/or to the affected stream provider. An empty option field or invalid path means that you don't want to use this option. 408 </p> 409 410 <p><a name="mountpoints"><h4>3.8. Mountpoints</h4></p> 357 411 <p> 358 412 Each stream on an NTRIP broadcaster is defined using a unique source ID called mountpoint. An NTRIP client like BNC access the desired data stream by referring to its mountpoint. Information about mountpoints is available through the source-table maintained by the NTRIP broadcaster. Note that mountpoints could show up in BNC more than once when retrieving streams from several NTRIP broadcasters. … … 371 425 </table> 372 426 373 <p><a name="AddMounts"><h4>3. 7.1 Add Mountpoints</h4></p>427 <p><a name="AddMounts"><h4>3.8.1 Add Mountpoints</h4></p> 374 428 <p> 375 429 Button 'Add Mountpoints' opens a window that allows user to select data streams from an NTRIP broadcaster according to their mountpoints. 376 430 </p> 377 431 378 <p><a name="HostPort"><h4>3. 7.2 Broadcaster Host and Port - required</h4></p>432 <p><a name="HostPort"><h4>3.8.2 Broadcaster Host and Port - required</h4></p> 379 433 <p> 380 434 Enter the NTRIP broadcaster host IP and port number. <u>http://www.rtcm-ntrip.org/home</u> provides information about known NTRIP broadcaster installations. Note that EUREF and IGS operate NTRIP broadcasters at <u>http://www.euref-ip.net/home</u> and <u>http://www.igs-ip.net/home</u>. 381 435 </p> 382 436 383 <p><a name="account"><h4>3. 7.3 Broadcaster User and Password - required for protected streams</h4></p>437 <p><a name="account"><h4>3.8.3 Broadcaster User and Password - required for protected streams</h4></p> 384 438 <p> 385 439 Some streams on NTRIP broadcasters may be restricted. Enter a valid 'User' ID and 'Password' for access to protected streams. Accounts are usually provided per NTRIP broadcaster through a registration procedure. Register through <u>http://igs.bkg.bund.de/index_ntrip_reg.htm</u> for access to protected streams on <u>www.euref-ip.net</u> and <u>www.igs-ip.net</u>. 386 440 </p> 387 441 388 <p><a name="GetTable"><h4>3. 7.4 Get Table</h4></p>442 <p><a name="GetTable"><h4>3.8.4 Get Table</h4></p> 389 443 <p> 390 444 Use the 'Get Table' button to download the source-table from the NTRIP broadcaster. Pay attention to data fields 'format' and 'format-details'. Keep in mind that BNC can only decode and convert streams that come in RTCM Version 2.x, RTCM Version 3.x, or RTIGS format. RTCM Version 2.x streams must contain message types 18 and 19 while RTCM Version 3.x streams must contain GPS or SBAS message types 1002 or 1004 and may contain GLONASS message types 1010 or 1012, see data field 'format-details' for available message types and their repetition rates in brackets. Note that in order to produce RINEX Navigation files RTCM Version 3.x streams containing message types 1019 (GPS) and 1020 (GLONASS) are required. Select your streams line by line, use +Shift and +Ctrl when necessary. … … 397 451 </p> 398 452 399 <p><a name="delete"><h4>3. 7.5 Delete Mountpoints</h4></p>453 <p><a name="delete"><h4>3.8.5 Delete Mountpoints</h4></p> 400 454 <p> 401 455 To remove a stream from the 'Mountpoints' list in the main window, highlight it by clicking on it and hit the 'Delete Mountpoints' button. You can also remove multiple mountpoints simultaneously by highlighting them using +Shift and +Ctrl.</p> 402 456 403 <p><a name="edit"><h4>3. 7.6 Edit Mountpoints</h4></p>457 <p><a name="edit"><h4>3.8.6 Edit Mountpoints</h4></p> 404 458 <ul> 405 459 <li> … … 416 470 </ul> 417 471 418 <p><a name="log"><h4>3. 8. Log - optional</h4></p>472 <p><a name="log"><h4>3.9. Log - optional</h4></p> 419 473 <p> 420 474 Records of BNC's activities are shown in the 'Log' section of the main windows. These logs can be saved into a file when a valid path is specified in the 'Log (full path)' field. The message log covers the communication status between BNC and the NTRIP broadcaster as well as problems that may occur in the communication link, stream availability, stream delay, stream conversion etc. The default value for 'Log (full path)' is an empty option field, meaning that BNC logs will not saved into a file. 421 475 </p> 422 476 423 <p><a name="start"><h4>3. 9. Start</h4></p>477 <p><a name="start"><h4>3.10. Start</h4></p> 424 478 <p> 425 479 Hit 'Start' to start retrieving, decoding, and converting GNSS data streams in real-time. Note that 'Start' generally forces BNC to begin with fresh RINEX which might overwrite existing files when necessary unless the option 'Append files' is ticked. 426 480 </p> 427 481 428 <p><a name="stop"><h4>3.1 0. Stop</h4></p>482 <p><a name="stop"><h4>3.11. Stop</h4></p> 429 483 <p> 430 484 Hit the 'Stop' button in order to stop BNC. 431 485 </p> 432 486 433 <p><a name="nw"><h4>3.1 1. No Window - optional</h4></p>487 <p><a name="nw"><h4>3.12. No Window - optional</h4></p> 434 488 <p> 435 489 On all systems BNC can be started in batch mode with the command line option '-nw'. BNC will then run in 'no window' mode, using options from the configuration file ${HOME}/.config/BKG/BNC_NTRIP_Client.conf (Unix/Linux, see Config File example in the Annex) or from the register BKG_NTRIP_Client (Windows). … … 440 494 <p><a name="limits"><h3>4. Limitations</h3></p> 441 495 <ul> 442 <li>443 Connection to an NTRIP broadcaster can sometimes be disrupted or a stream requested may temporarily be unavailable. Connection is defined by BNC as broken if no data is coming in for a period of 20 seconds. When this occurs, reconnects are attempted at decreasing rate. BNC first attempts to reconnect with ~1 second lag, if unsuccessful, again in ~2 seconds since the previous attempt. If it is still unsuccessful, it will attempt to reconnect within ~4 seconds since the previous attempt etc. Each attempt doubles the wait time from the previous attempt. The maximum delay between attempts is limited to ~256 seconds. This reconnection process is documented in the 'Log' file/section.444 </li>445 496 <li> 446 497 Currently BNC only handles GPS, SBAS and GLONASS data. Galileo is not yet supported. -
trunk/BNC/bncmain.cpp
r628 r658 81 81 settings.setValue("rnxSkel", "SKL"); 82 82 settings.setValue("waitTime", 5); 83 settings.setValue("inspSegm", "15"); 84 settings.setValue("noticeFail", "15"); 85 settings.setValue("noticeReco", "5"); 83 86 } 84 87 -
trunk/BNC/bncwindow.cpp
r647 r658 173 173 _rnxAppendCheckBox->setWhatsThis(tr("<p>When BNC is started, new RINEX Observation files are created by default and any existing files with the same name will be overwritten. However, users might want to append observations and ephemeris to existing RINEX files following a restart of BNC, a system crash or when BNC crashed. Tick 'Append files' to continue with existing files and keep what has been recorded so far.</p>")); 174 174 _rnxIntrComboBox = new QComboBox(); 175 _rnxIntrComboBox->setWhatsThis(tr("<p>Select the length of the RINEX Observation file generated.</p>"));175 _rnxIntrComboBox->setWhatsThis(tr("<p>Select the length of the RINEX Observation file.</p>")); 176 176 _rnxIntrComboBox->setMaximumWidth(9*ww); 177 177 _rnxIntrComboBox->setEditable(false); … … 182 182 } 183 183 _ephIntrComboBox = new QComboBox(); 184 _ephIntrComboBox->setWhatsThis(tr("<p>Select the length of the RINEX Navigation file generated.</p>"));184 _ephIntrComboBox->setWhatsThis(tr("<p>Select the length of the RINEX Navigation file.</p>")); 185 185 _ephIntrComboBox->setMaximumWidth(9*ww); 186 186 _ephIntrComboBox->setEditable(false); … … 198 198 _rnxSamplSpinBox->setValue(settings.value("rnxSampl").toInt()); 199 199 _rnxSamplSpinBox->setSuffix(" sec"); 200 _inspSegmSpinBox = new QSpinBox(); 201 _inspSegmSpinBox->setWhatsThis(tr("<p>Select the RINEX Observation sampling interval in seconds. A value of zero '0' tells BNC to store all received epochs into RINEX.</p>")); 202 _inspSegmSpinBox->setMinimum(0); 203 _inspSegmSpinBox->setMaximum(60); 204 _inspSegmSpinBox->setSingleStep(1); 205 _inspSegmSpinBox->setMaximumWidth(9*ww); 206 _inspSegmSpinBox->setValue(settings.value("inspSegm").toInt()); 207 _inspSegmSpinBox->setSuffix(" sec"); 208 _inspSegmSpinBox->setWhatsThis(tr("<p>BNC can collect all returns (success or failure) coming from a decoder within a certain short time span (Inspect segment) to then decide whether a stream content is corrupted or not. When a continuous problem is detected, BNC can inform its operator about this event through a Notice advisory. A value of about 15 sec (default) as 'Inspect segment' is recommended when handling 1Hz data.</p><p>A value of zero '0' means that you don't want BNC to inform you about incoming data that can not be decoded.</p>")); 209 _noticeRecoSpinBox = new QSpinBox(); 210 _noticeRecoSpinBox->setMinimum(0); 211 _noticeRecoSpinBox->setMaximum(60); 212 _noticeRecoSpinBox->setSingleStep(1); 213 _noticeRecoSpinBox->setSuffix(" min"); 214 _noticeRecoSpinBox->setMaximumWidth(9*ww); 215 _noticeRecoSpinBox->setValue(settings.value("noticeReco").toInt()); 216 _noticeRecoSpinBox->setWhatsThis(tr("<p>Following a stream outage or a longer series of corrupted observations, a Notice advisory is generated when at least one valid observation is received again within the 'Recovery' threshold time span defined here. A value of about 5min (default) is recommendable. A valu of zero '0' means that BNC immediately informs about any stream recovery. </p><p>Note that using this function for corrupted streams needs an 'Inspect segment' greater zero '0'.</p>")); 217 _noticeFailSpinBox = new QSpinBox(); 218 _noticeFailSpinBox->setMinimum(0); 219 _noticeFailSpinBox->setMaximum(60); 220 _noticeFailSpinBox->setSingleStep(1); 221 _noticeFailSpinBox->setSuffix(" min"); 222 _noticeFailSpinBox->setMaximumWidth(9*ww); 223 _noticeFailSpinBox->setValue(settings.value("noticeFail").toInt()); 224 _noticeFailSpinBox->setWhatsThis(tr("<p>A Notice advisory is generated when no (or corrupted) observations are received throughout the 'Failure' threshold time span defined here. A value of about 15 min (default) is recommendable. A value of zero '0' means that BNC immediately informs about any stream failure.</p><p>Note that using this function forcorrupted streams needs an 'Inspect segment' greater zero '0'.</p>")); 200 225 _logFileLineEdit = new QLineEdit(settings.value("logFile").toString()); 201 226 _logFileLineEdit->setWhatsThis(tr("<p>Records of BNC's activities are shown in the 'Log' section below. They can be saved into a file when a valid path is specified in the 'Log (full path)' field.</p>")); 227 _noticeScriptLineEdit = new QLineEdit(settings.value("noticeScript").toString()); 228 _noticeScriptLineEdit->setWhatsThis(tr("<p>Specify the full path to a script or batch file to handle Notice advisories generated in case of corrupted streams of stream outages. The affected mountpoint and one of the comments 'Begin_Outage', 'End_Outage', 'Begin_Currupted', or 'End_Corrupted' are passed on to the script as two command line parameters.</p><p>The script may be used to send an email to BNC's operator and/or to the affected streamprovider. An empty option field or invalid path means that you don't want to use this option.</p>")); 202 229 _mountPointsTable = new QTableWidget(0,7); 203 230 _mountPointsTable->setWhatsThis(tr("<p>Streams selected for retrieval are listed in the 'Mountpoints' section. Button 'Add Mountpoints' opens a window that allows the user to select data streams from an NTRIP broadcaster according to their mountpoints. To remove a stream from the 'Mountpoints' list, highlight it by clicking on it and hit the 'Delete Mountpoints' button. You can also remove multiple mountpoints simultaneously by highlighting them using +Shift and +Ctrl.</p><p>BNC automatically allocates one of its internal decoders to a stream based on the stream's 'format' and 'format-details' as given in the source-table. However, there might be cases where you need to override the automatic selection due to incorrect source-table for example. BNC allows users to manually select the required decoder by editing the decoder string. Doubleclick on the 'decoder' field, enter your preferred decoder and then hit Enter. The accepted decoder strings are 'RTCM_2.x', 'RTCM_3.x', and 'RTIGS'.</p><p>In case you need to log the raw data as is, BNC allows users to by-pass its decoders and and directly save the input in daily log files. To do this specify the decoder string as 'ZERO'.</p><p>BNC can also retrieve streams from virtual reference stations (VRS). To initiate these streams, an approximate rover position needs to be sent in NMEA format to the NTRIP broadcaster. In return, a user-specific data stream is generated, typically by a Network-RTK software. This stream is customized to the exact latitude and longitude as shown in the 'lat' and 'long' columns under 'Mountpoints'. These VRS streams are indicated by a 'yes' in the 'nmea' column under 'Mountpoints' as well as in the source-table. The default 'lat' and 'long' values are taken from the source-table. However, in most cases you would probably want to change this according to your requirement. Double-click on 'lat' and 'long' fields, enter the values you wish to send and then hit Enter. The format is in positive north latitude degrees (e.g. for northern hemisphere: 52.436, for southern hemisphere: -24.567) and eastern longitude degrees (example: 358.872 or -1.128). Only mountpoints with a 'yes' in its 'nmea' column can be edited. The position must preferably be a point within the service area of the network.</p>")); … … 289 316 layout->addWidget(_outFileLineEdit, 2, 2, 1, 3); 290 317 291 layout->addWidget(new QLabel("Port for output"),3, 0, 1, 2);318 layout->addWidget(new QLabel("Ports for output"), 3, 0, 1, 2); 292 319 QBoxLayout* bl1 = new QBoxLayout(QBoxLayout::LeftToRight); 293 320 bl1->addWidget(_outPortLineEdit); … … 308 335 layout->addWidget(_rnxScrpLineEdit, 5, 2, 1, 3); 309 336 310 layout->addWidget(new QLabel("File interval "),6, 0, 1, 2);337 layout->addWidget(new QLabel("File intervals"), 6, 0, 1, 2); 311 338 312 339 QBoxLayout* bl = new QBoxLayout(QBoxLayout::LeftToRight); … … 333 360 _ephV3CheckBox->setWhatsThis(tr("<p>Default format for RINEX Navigation files containing Broadcast Ephemeris is RINEX Version 2.11. Select 'RINEX v3' if you want to save the ephemeris in RINEX Version 3 format.</p>")); 334 361 335 layout->addWidget(new QLabel("Mountpoints"), 9, 0, 1, 2); 336 337 layout->addWidget(_mountPointsTable, 10, 0, 1, 5); 338 339 layout->addWidget(new QLabel("Log (full path)"), 11, 0, 1, 2); 340 layout->addWidget(_logFileLineEdit, 11, 2, 1, 3); 341 layout->addWidget(_log, 12, 0, 1, 5); 362 layout->addWidget(new QLabel("Notice thresholds"), 9, 0, 1, 2); 363 QBoxLayout* bl2 = new QBoxLayout(QBoxLayout::LeftToRight); 364 bl2->addWidget(_noticeFailSpinBox); 365 bl2->addWidget(new QLabel("Failure")); 366 bl2->addWidget(_noticeRecoSpinBox); 367 bl2->addWidget(new QLabel("Recovery")); 368 bl2->addWidget(new QLabel("Inspect segment")); 369 bl2->addWidget(_inspSegmSpinBox); 370 layout->addLayout(bl2, 9, 2, 1, 3); 371 372 layout->addWidget(new QLabel("Notice script (full path)"), 10, 0, 1, 2); 373 layout->addWidget(_noticeScriptLineEdit, 10, 2, 1, 3); 374 375 layout->addWidget(new QLabel("Mountpoints"), 11, 0, 1, 2); 376 377 layout->addWidget(_mountPointsTable, 12, 0, 1, 5); 378 379 layout->addWidget(new QLabel("Log (full path)"), 13, 0, 1, 2); 380 layout->addWidget(_logFileLineEdit, 13, 2, 1, 3); 381 layout->addWidget(_log, 14, 0, 1, 5); 342 382 } 343 383 … … 466 506 settings.setValue("proxyPort", _proxyPortLineEdit->text()); 467 507 settings.setValue("waitTime", _waitTimeSpinBox->value()); 508 settings.setValue("inspSegm", _inspSegmSpinBox->value()); 509 settings.setValue("noticeFail", _noticeFailSpinBox->value()); 510 settings.setValue("noticeReco", _noticeRecoSpinBox->value()); 468 511 settings.setValue("outFile", _outFileLineEdit->text()); 469 512 settings.setValue("outPort", _outPortLineEdit->text()); … … 480 523 settings.setValue("ephV3", _ephV3CheckBox->checkState()); 481 524 settings.setValue("logFile", _logFileLineEdit->text()); 525 settings.setValue("noticeScript",_noticeScriptLineEdit->text()); 482 526 483 527 QStringList mountPoints; -
trunk/BNC/bncwindow.h
r588 r658 92 92 QCheckBox* _rnxAppendCheckBox; 93 93 QSpinBox* _waitTimeSpinBox; 94 QSpinBox* _inspSegmSpinBox; 95 QSpinBox* _noticeFailSpinBox; 96 QSpinBox* _noticeRecoSpinBox; 97 QLineEdit* _noticeScriptLineEdit; 94 98 QTableWidget* _mountPointsTable; 95 99
Note:
See TracChangeset
for help on using the changeset viewer.