Ignore:
Timestamp:
Nov 9, 2026, 12:15:48 PM (12 hours ago)
Author:
stuerze
Message:

Structured logging improved

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/RTCM3/RTCM3Decoder.cpp

    r11141 r11185  
    916916  else if ((type % 10) < 4) {
    917917#ifdef BNC_DEBUG_OBS
    918     emit(newMessage(QString("%1: Block %2 contain partial data! Ignored!")
    919         .arg(_staID).arg(type).toLatin1(), true));
     918    emit(newLogRecord(t_logRecord::debugMessage("obs", QString("%1: Block %2 contain partial data! Ignored!")
     919        .arg(_staID).arg(type).toLatin1()), true));
    920920#endif
    921921  }
    … …  
    10771077    if (i < 1 || i > 63 ) {
    10781078#ifdef BNC_DEBUG_BCE
    1079       emit(newMessage(QString("%1: Block %2 (G) PRN# is out of range: %3!")
     1079      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (G) PRN# is out of range: %3!")
    10801080           .arg(_staID)
    10811081           .arg(1019,4)
    1082            .arg(i).toLatin1(), true));
     1082           .arg(i).toLatin1()), true));
    10831083#endif
    10841084      return false;
    … …  
    10891089    if (week < 0 || week > 1023) {
    10901090#ifdef BNC_DEBUG_BCE
    1091       emit(newMessage(QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
     1091      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
    10921092           .arg(_staID)
    10931093           .arg(1019,4)
    10941094           .arg(eph._prn.toString().c_str())
    1095            .arg(week).toLatin1(), true));
     1095           .arg(week).toLatin1()), true));
    10961096#endif
    10971097      return false;
    … …  
    11061106    if (i < 0 || i > 604784) {
    11071107#ifdef BNC_DEBUG_BCE
    1108       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1108      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    11091109           .arg(_staID)
    11101110           .arg(1019,4)
    11111111           .arg(eph._prn.toString().c_str())
    1112            .arg(i).toLatin1(), true));
     1112           .arg(i).toLatin1()), true));
    11131113#endif
    11141114      return false;
    … …  
    11281128    if (eph._sqrt_A < 1000.0) {
    11291129#ifdef BNC_DEBUG_BCE
    1130       emit(newMessage(QString("%1: Block %2 (%3) SQRT_A %4 m!")
     1130      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SQRT_A %4 m!")
    11311131           .arg(_staID).arg(1019,4).arg(eph._prn.toString().c_str())
    1132            .arg(eph._sqrt_A,10,'F',3).toLatin1(), true));
     1132           .arg(eph._sqrt_A,10,'F',3).toLatin1()), true));
    11331133#endif
    11341134      return false;
    … …  
    11381138    if (i < 0 || i > 604784) {
    11391139#ifdef BNC_DEBUG_BCE
    1140       emit(newMessage(QString("%1: Block %2 (%3) TOE is out of range: %4!")
     1140      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOE is out of range: %4!")
    11411141           .arg(_staID)
    11421142           .arg(1019,4)
    11431143           .arg(eph._prn.toString().c_str())
    1144            .arg(i).toLatin1(), true));
     1144           .arg(i).toLatin1()), true));
    11451145#endif
    11461146      return false;
    … …  
    11971197    if (sv < 1 || sv > 63) {
    11981198#ifdef BNC_DEBUG_BCE
    1199       emit(newMessage(QString("%1: Block %2 (R):  SLOT# is unknown (0) or out of range: %3!")
     1199      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (R):  SLOT# is unknown (0) or out of range: %3!")
    12001200           .arg(_staID)
    12011201           .arg(1020,4)
    1202            .arg(sv).toLatin1(), true));
     1202           .arg(sv).toLatin1()), true));
    12031203#endif
    12041204      return false;
    … …  
    12101210    if (i < 0 || i > 20) {
    12111211#ifdef BNC_DEBUG_BCE
    1212       emit(newMessage(QString("%1: Block %2 (%3): FRQ CHN# is out of range: %4")
     1212      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): FRQ CHN# is out of range: %4")
    12131213           .arg(_staID)
    12141214           .arg(1020,4)
    12151215           .arg(eph._prn.toString().c_str())
    1216            .arg(i).toLatin1(), true));
     1216           .arg(i).toLatin1()), true));
    12171217#endif
    12181218      return false;
    … …  
    12261226    if (i < 0 || i > 23) {
    12271227#ifdef BNC_DEBUG_BCE
    1228       emit(newMessage(QString("%1: Block %2 (%3): T_k (bits 11-7) is out of range: %4")
     1228      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): T_k (bits 11-7) is out of range: %4")
    12291229           .arg(_staID)
    12301230           .arg(1020,4)
    12311231           .arg(eph._prn.toString().c_str())
    1232            .arg(i).toLatin1(), true));
     1232           .arg(i).toLatin1()), true));
    12331233#endif
    12341234      return false;
    … …  
    12381238    if (i < 0 || i > 59) {
    12391239#ifdef BNC_DEBUG_BCE
    1240       emit(newMessage(QString("%1: Block %2 (%3): T_k (bits 6-1) is out of range: %4")
     1240      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): T_k (bits 6-1) is out of range: %4")
    12411241           .arg(_staID)
    12421242           .arg(1020,4)
    12431243           .arg(eph._prn.toString().c_str())
    1244            .arg(i).toLatin1(), true));
     1244           .arg(i).toLatin1()), true));
    12451245#endif
    12461246      return false;
    … …  
    12501250    if (i < 0 || i > 1) {
    12511251#ifdef BNC_DEBUG_BCE
    1252       emit(newMessage(QString("%1: Block %2 (%3): T_k (bit 0) is out of range: %4")
     1252      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): T_k (bit 0) is out of range: %4")
    12531253           .arg(_staID)
    12541254           .arg(1020,4)
    12551255           .arg(eph._prn.toString().c_str())
    1256            .arg(i).toLatin1(), true));
     1256           .arg(i).toLatin1()), true));
    12571257#endif
    12581258      return false;
    … …  
    12691269    if (i < 15 || i > 1425) {
    12701270#ifdef BNC_DEBUG_BCE
    1271       emit(newMessage(QString("%1: Block %2 (%3): T_b is out of range: %4")
     1271      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): T_b is out of range: %4")
    12721272           .arg(_staID)
    12731273           .arg(1020,4)
    12741274           .arg(eph._prn.toString().c_str())
    1275            .arg(i).toLatin1(), true));
     1275           .arg(i).toLatin1()), true));
    12761276#endif
    12771277      return false;
    … …  
    13001300    if (eph._M_NT == 0.0) {
    13011301#ifdef BNC_DEBUG_BCE
    1302       emit(newMessage(QString("%1: Block %2 (%3): NT = %4: missing data!")
    1303            .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).arg(eph._M_NT,4).toLatin1(), true));
     1302      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): NT = %4: missing data!")
     1303           .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).arg(eph._M_NT,4).toLatin1()), true));
    13041304#endif
    13051305      return false;
    … …  
    13091309    if (eph._additional_data_availability == 0.0) {
    13101310#ifdef BNC_DEBUG_BCE
    1311       emit(newMessage(QString("%1: Block %2 (%3): ADD = %4: missing data!")
     1311      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): ADD = %4: missing data!")
    13121312           .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str())
    1313            .arg(eph._additional_data_availability).toLatin1(), true));
     1313           .arg(eph._additional_data_availability).toLatin1()), true));
    13141314#endif
    13151315      return false;
    … …  
    13311331    if (eph._xv.Rows(1,3).NormFrobenius() < 1.0) {
    13321332#ifdef BNC_DEBUG_BCE
    1333       emit(newMessage(QString("%1: Block %2 (%3): zero position!")
    1334            .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).toLatin1(), true));
     1333      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): zero position!")
     1334           .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).toLatin1()), true));
    13351335#endif
    13361336      return false;
    … …  
    13411341    if (eph._xv.Rows(4,6).NormFrobenius() < 1.0) {
    13421342#ifdef BNC_DEBUG_BCE
    1343       emit(newMessage(QString("%1: Block %2 (%3): zero velocity!")
    1344            .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).toLatin1(), true));
     1343      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): zero velocity!")
     1344           .arg(_staID).arg(1020,4).arg(eph._prn.toString().c_str()).toLatin1()), true));
    13451345#endif
    13461346      return false;
    … …  
    13861386    if (i < 1 || i > 10 ) {
    13871387#ifdef BNC_DEBUG_BCE
    1388       emit(newMessage(QString("%1: Block %2 (J) SAT ID is out of range: %3!")
     1388      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (J) SAT ID is out of range: %3!")
    13891389           .arg(_staID)
    13901390           .arg(1044,4)
    1391            .arg(i).toLatin1(), true));
     1391           .arg(i).toLatin1()), true));
    13921392#endif
    13931393      return false;
    … …  
    14001400    if (i < 0 || i > 604784) {
    14011401#ifdef BNC_DEBUG_BCE
    1402       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1402      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    14031403           .arg(_staID)
    14041404           .arg(1044,4)
    14051405           .arg(eph._prn.toString().c_str())
    1406            .arg(i).toLatin1(), true));
     1406           .arg(i).toLatin1()), true));
    14071407#endif
    14081408      return false;
    … …  
    14231423    if (eph._sqrt_A < 1000.0) {
    14241424#ifdef BNC_DEBUG_BCE
    1425       emit(newMessage(QString("%1: Block %2 (%3) SQRT_A %4 m!")
     1425      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SQRT_A %4 m!")
    14261426           .arg(_staID).arg(1044,4).arg(eph._prn.toString().c_str())
    1427            .arg(eph._sqrt_A,10,'F',3).toLatin1(), true));
     1427           .arg(eph._sqrt_A,10,'F',3).toLatin1()), true));
    14281428#endif
    14291429      return false;
    … …  
    14331433    if (i < 0 || i > 604784) {
    14341434#ifdef BNC_DEBUG_BCE
    1435       emit(newMessage(QString("%1: Block %2 (%3) TOE is out of range: %4!")
     1435      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOE is out of range: %4!")
    14361436           .arg(_staID)
    14371437           .arg(1044,4)
    14381438           .arg(eph._prn.toString().c_str())
    1439            .arg(i).toLatin1(), true));
     1439           .arg(i).toLatin1()), true));
    14401440#endif
    14411441      return false;
    … …  
    14571457    if (week < 0 || week > 1023) {
    14581458#ifdef BNC_DEBUG_BCE
    1459       emit(newMessage(QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
     1459      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
    14601460           .arg(_staID)
    14611461           .arg(1044,4)
    14621462           .arg(eph._prn.toString().c_str())
    1463            .arg(week).toLatin1(), true));
     1463           .arg(week).toLatin1()), true));
    14641464#endif
    14651465      return false;
    … …  
    15071507    if (i < 1 || i > 63 ) {
    15081508#ifdef BNC_DEBUG_BCE
    1509       emit(newMessage(QString("%1: Block %2 (I) PRN# is out of range: %3!")
     1509      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (I) PRN# is out of range: %3!")
    15101510           .arg(_staID)
    15111511           .arg(1041,4)
    1512            .arg(i).toLatin1(), true));
     1512           .arg(i).toLatin1()), true));
    15131513#endif
    15141514      return false;
    … …  
    15191519    if (week < 0 || week > 1023) {
    15201520#ifdef BNC_DEBUG_BCE
    1521       emit(newMessage(QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
     1521      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
    15221522           .arg(_staID)
    15231523           .arg(1041,4)
    15241524           .arg(eph._prn.toString().c_str())
    1525            .arg(week).toLatin1(), true));
     1525           .arg(week).toLatin1()), true));
    15261526#endif
    15271527      return false;
    … …  
    15361536    if (i < 0 || i > 1048560) {
    15371537#ifdef BNC_DEBUG_BCE
    1538       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1538      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    15391539           .arg(_staID)
    15401540           .arg(1041,4)
    15411541           .arg(eph._prn.toString().c_str())
    1542            .arg(i).toLatin1(), true));
     1542           .arg(i).toLatin1()), true));
    15431543#endif
    15441544      return false;
    … …  
    15771577    if (i < 0 || i > 1048560) {
    15781578#ifdef BNC_DEBUG_BCE
    1579       emit(newMessage(QString("%1: Block %2 (%3) TOE is out of range: %4!")
     1579      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOE is out of range: %4!")
    15801580           .arg(_staID)
    15811581           .arg(1041,4)
    15821582           .arg(eph._prn.toString().c_str())
    1583            .arg(i).toLatin1(), true));
     1583           .arg(i).toLatin1()), true));
    15841584#endif
    15851585      return false;
    … …  
    15981598    if (eph._sqrt_A < 1000.0) {
    15991599#ifdef BNC_DEBUG_BCE
    1600       emit(newMessage(QString("%1: Block %2 (%3) SQRT_A %4 m!")
     1600      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SQRT_A %4 m!")
    16011601           .arg(_staID).arg(1041,4).arg(eph._prn.toString().c_str())
    1602            .arg(eph._sqrt_A,10,'F',3).toLatin1(), true));
     1602           .arg(eph._sqrt_A,10,'F',3).toLatin1()), true));
    16031603#endif
    16041604      return false;
    … …  
    16421642    if (i < 0 || i > 38 ) {
    16431643#ifdef BNC_DEBUG_BCE
    1644       emit(newMessage(QString("%1: Block %2 (S) PRN# is out of range: %3!")
     1644      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (S) PRN# is out of range: %3!")
    16451645           .arg(_staID)
    16461646           .arg(1043,4)
    1647            .arg(i).toLatin1(), true));
     1647           .arg(i).toLatin1()), true));
    16481648#endif
    16491649      return false;
    … …  
    16561656    if (i < 0 || i > 86384) {
    16571657#ifdef BNC_DEBUG_BCE
    1658       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1658      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    16591659           .arg(_staID)
    16601660           .arg(1043,4)
    16611661           .arg(eph._prn.toString().c_str())
    1662            .arg(i).toLatin1(), true));
     1662           .arg(i).toLatin1()), true));
    16631663#endif
    16641664      return false;
    … …  
    16851685    if (pos.NormFrobenius() < 1.0) {
    16861686#ifdef BNC_DEBUG_BCE
    1687       emit(newMessage(QString("%1: Block %2 (%3): zero position!")
    1688            .arg(_staID).arg(1043,4).arg(eph._prn.toString().c_str()).toLatin1(), true));
     1687      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3): zero position!")
     1688           .arg(_staID).arg(1043,4).arg(eph._prn.toString().c_str()).toLatin1()), true));
    16891689#endif
    16901690      return false;
    … …  
    17201720  size -= 6; /* header + crc */
    17211721  GETBITS(i, 12)
     1722#ifdef BNC_DEBUG_BCE
     1723  const int mnum = i;   // message number for the debug messages
     1724#endif
    17221725
    17231726  if ((i == 1046 && size == 61) ||
    … …  
    17321735    if (i < 1 || i > 36 ) { // max. constellation within I/NAV / F/NAV frames is 36
    17331736#ifdef BNC_DEBUG_BCE
    1734       emit(newMessage(QString("%1: Block %2 (E) PRN# is out of range: %3!")
     1737      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (E) PRN# is out of range: %3!")
    17351738           .arg(_staID)
    17361739           .arg(mnum,4)
    1737            .arg(i).toLatin1(), true));
     1740           .arg(i).toLatin1()), true));
    17381741#endif
    17391742      return false;
    … …  
    17451748    if (week < 0 || week > 4095) {
    17461749#ifdef BNC_DEBUG_BCE
    1747       emit(newMessage(QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
     1750      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
    17481751           .arg(_staID)
    17491752           .arg(mnum,4)
    17501753           .arg(eph._prn.toString().c_str())
    1751            .arg(week).toLatin1(), true));
     1754           .arg(week).toLatin1()), true));
    17521755#endif
    17531756      return false;
    … …  
    17671770    if (i < 0 || i > 604740) {
    17681771#ifdef BNC_DEBUG_BCE
    1769       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1772      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    17701773           .arg(_staID)
    17711774           .arg(mnum,4)
    17721775           .arg(eph._prn.toString().c_str())
    1773            .arg(i).toLatin1(), true));
     1776           .arg(i).toLatin1()), true));
    17741777#endif
    17751778      return false;
    … …  
    17891792    if (i < 0 || i > 604740) {
    17901793#ifdef BNC_DEBUG_BCE
    1791       emit(newMessage(QString("%1: Block %2 (%3) TOE is out of range: %4!")
     1794      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOE is out of range: %4!")
    17921795           .arg(_staID)
    17931796           .arg(mnum,4)
    17941797           .arg(eph._prn.toString().c_str())
    1795            .arg(i).toLatin1(), true));
     1798           .arg(i).toLatin1()), true));
    17961799#endif
    17971800      return false;
    … …  
    18201823      if (eph._E5b_HS != eph._E1B_HS) {
    18211824#ifdef BNC_DEBUG_BCE
    1822         emit(newMessage(QString("%1: Block %2 (%3) SHS E5b %4 E1B %5: inconsistent health!")
     1825        emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SHS E5b %4 E1B %5: inconsistent health!")
    18231826             .arg(_staID).arg(1046,4).arg(eph._prn.toString().c_str())
    1824              .arg(eph._E5b_HS).arg(eph._E1B_HS).toLatin1(), true));
     1827             .arg(eph._E5b_HS).arg(eph._E1B_HS).toLatin1()), true));
    18251828#endif
    18261829        return false;
    … …  
    18291832          (eph._BGD_1_5B == 0.0 && fabs(eph._BGD_1_5A) > 1e-9)) {
    18301833#ifdef BNC_DEBUG_BCE
    1831         emit(newMessage(QString("%1: Block %2 (%3) BGD_1_5a = %4 BGD_1_5b = %5: inconsistent BGD!")
     1834        emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) BGD_1_5a = %4 BGD_1_5b = %5: inconsistent BGD!")
    18321835             .arg(_staID).arg(1046,4).arg(eph._prn.toString().c_str())
    1833              .arg(eph._BGD_1_5A,10,'E',3).arg(eph._BGD_1_5B,10,'E',3).toLatin1(), true));
     1836             .arg(eph._BGD_1_5A,10,'E',3).arg(eph._BGD_1_5B,10,'E',3).toLatin1()), true));
    18341837#endif
    18351838        return false;
    … …  
    18521855    if (eph._sqrt_A < 1000.0) {
    18531856#ifdef BNC_DEBUG_BCE
    1854       emit(newMessage(QString("%1: Block %2 (%3) SQRT_A %4 m!")
     1857      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SQRT_A %4 m!")
    18551858           .arg(_staID).arg(eph._inav? 1046 : 1045,4).arg(eph._prn.toString().c_str())
    1856            .arg(eph._sqrt_A,10,'F',3).toLatin1(), true));
     1859           .arg(eph._sqrt_A,10,'F',3).toLatin1()), true));
    18571860#endif
    18581861      return false;
    … …  
    18861889    if (i < 1 || i > 63 ) {
    18871890#ifdef BNC_DEBUG_BCE
    1888       emit(newMessage(QString("%1: Block %2 (C) PRN# is out of range: %3!")
     1891      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (C) PRN# is out of range: %3!")
    18891892           .arg(_staID)
    18901893           .arg(1042,4)
    1891            .arg(i).toLatin1(), true));
     1894           .arg(i).toLatin1()), true));
    18921895#endif
    18931896      return false;
    … …  
    18991902    if (week < 0 || week > 8191) {
    19001903#ifdef BNC_DEBUG_BCE
    1901       emit(newMessage(QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
     1904      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) WEEK # is out of range: %4!")
    19021905           .arg(_staID)
    19031906           .arg(1042,4)
    19041907           .arg(eph._prn.toString().c_str())
    1905            .arg(week).toLatin1(), true));
     1908           .arg(week).toLatin1()), true));
    19061909#endif
    19071910      return false;
    … …  
    19221925    if (i < 0 || i > 604792) {
    19231926#ifdef BNC_DEBUG_BCE
    1924       emit(newMessage(QString("%1: Block %2 (%3) TOC is out of range: %4!")
     1927      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOC is out of range: %4!")
    19251928           .arg(_staID)
    19261929           .arg(1042,4)
    19271930           .arg(eph._prn.toString().c_str())
    1928            .arg(i).toLatin1(), true));
     1931           .arg(i).toLatin1()), true));
    19291932#endif
    19301933      return false;
    … …  
    19441947    if (eph._sqrt_A < 1000.0) {
    19451948#ifdef BNC_DEBUG_BCE
    1946       emit(newMessage(QString("%1: Block %2 (%3) SQRT_A %4 m!")
     1949      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) SQRT_A %4 m!")
    19471950           .arg(_staID).arg(1042,4).arg(eph._prn.toString().c_str())
    1948            .arg(eph._sqrt_A,10,'F',3).toLatin1(), true));
     1951           .arg(eph._sqrt_A,10,'F',3).toLatin1()), true));
    19491952#endif
    19501953      return false;
    … …  
    19541957    if (i < 0 || i > 604792) {
    19551958#ifdef BNC_DEBUG_BCE
    1956       emit(newMessage(QString("%1: Block %2 (%3) TOE is out of range: %4!")
     1959      emit(newLogRecord(t_logRecord::debugMessage("bce", QString("%1: Block %2 (%3) TOE is out of range: %4!")
    19571960           .arg(_staID)
    19581961           .arg(1042,4)
    19591962           .arg(eph._prn.toString().c_str())
    1960            .arg(i).toLatin1(), true));
     1963           .arg(i).toLatin1()), true));
    19611964#endif
    19621965      return false;
    … …  
    23292332          case 1003:
    23302333#ifdef BNC_DEBUG_OBS
    2331             emit(newMessage(QString("%1: Block %2 contain partial data! Ignored!")
    2332                  .arg(_staID).arg(id).toLatin1(), true));
     2334            emit(newLogRecord(t_logRecord::debugMessage("obs", QString("%1: Block %2 contain partial data! Ignored!")
     2335                 .arg(_staID).arg(id).toLatin1()), true));
    23332336#endif
    23342337            break; /* no use decoding partial data ATM, remove break when data can be used */
    … …  
    23412344          case 1011:
    23422345#ifdef BNC_DEBUG_OBS
    2343             emit(newMessage(QString("%1: Block %2 contain partial data! Ignored!")
    2344                  .arg(_staID).arg(id).toLatin1(), true));
     2346            emit(newLogRecord(t_logRecord::debugMessage("obs", QString("%1: Block %2 contain partial data! Ignored!")
     2347                 .arg(_staID).arg(id).toLatin1()), true));
    23452348#endif
    23462349            break; /* no use decoding partial data ATM, remove break when data can be used */
    … …  
    24912494  if (!_prnOutOfRangeLogged.contains(prnStr)) {
    24922495    _prnOutOfRangeLogged.insert(prnStr);
    2493     emit newMessage(QString("%1: satellite %2 outside the range supported by BNC - not usable for processing")
    2494                     .arg(_staID).arg(prnStr).toLatin1(), true);
     2496    emit newLogRecord(t_logRecord::message(t_logRecord::warning, QString("%1: satellite %2 outside the range supported by BNC - not usable for processing")
     2497                    .arg(_staID).arg(prnStr).toLatin1()), true);
    24952498  }
    24962499}
Note: See TracChangeset for help on using the changeset viewer.