Changeset 11191 in ntrip for trunk/BNC/src/bncgetthread.cpp
- Timestamp:
- Nov 10, 2026, 12:11:31 PM (73 minutes ago)
- File:
-
- 1 edited
-
trunk/BNC/src/bncgetthread.cpp (modified) (12 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/bncgetthread.cpp
r11190 r11191 909 909 } 910 910 if (!allFound) { 911 GPSDecoder::t_typeInfo source; // message with the new type(s) 912 source._type = obs._type; 913 source._size = obs._size; 911 914 QString msg; 912 915 QTextStream str(&msg); … … 915 918 str << " " << rnxTypes[iType]; 916 919 } 917 emitContent(_staID + ": Observation Types: " + msg.toLatin1(), true); 920 emitContent(_staID + ": Observation Types: " + msg.toLatin1(), true, source); 918 921 } 919 922 } … … 923 926 for (int ii = 0; ii < decoder()->_antType.size(); ii++) { 924 927 QString ant1 = QString(": Antenna Descriptor: %1 ").arg(decoder()->_antType[ii]._descriptor); 925 emitContent(_staID + ant1.toLatin1(), true); 928 emitContent(_staID + ant1.toLatin1(), true, decoder()->_antType[ii]._source); 926 929 if (strlen(decoder()->_antType[ii]._serialnumber)) { 927 930 QString ant2 = QString(": Antenna Serial Number: %1 ").arg(decoder()->_antType[ii]._serialnumber); 928 emitContent(_staID + ant2.toLatin1(), true); 931 emitContent(_staID + ant2.toLatin1(), true, decoder()->_antType[ii]._source); 929 932 } 930 933 } … … 943 946 ant2 = QString("%1 ").arg(decoder()->_antList[ii]._yy, 0, 'f', 4).toLatin1(); 944 947 ant3 = QString("%1 ").arg(decoder()->_antList[ii]._zz, 0, 'f', 4).toLatin1(); 945 emitContent(_staID + ": " + antT + " (ITRF) X " + ant1 + "m", true); 946 emitContent(_staID + ": " + antT + " (ITRF) Y " + ant2 + "m", true); 947 emitContent(_staID + ": " + antT + " (ITRF) Z " + ant3 + "m", true); 948 emitContent(_staID + ": " + antT + " (ITRF) X " + ant1 + "m", true, decoder()->_antList[ii]._source); 949 emitContent(_staID + ": " + antT + " (ITRF) Y " + ant2 + "m", true, decoder()->_antList[ii]._source); 950 emitContent(_staID + ": " + antT + " (ITRF) Z " + ant3 + "m", true, decoder()->_antList[ii]._source); 948 951 double hh = 0.0; 949 952 if (decoder()->_antList[ii]._height_f) { … … 951 954 QByteArray ant4 = QString("%1 ").arg(hh, 0, 'f', 4).toLatin1(); 952 955 emitContent( 953 _staID + ": Antenna height above marker " + ant4 + "m", true); 956 _staID + ": Antenna height above marker " + ant4 + "m", true, 957 decoder()->_antList[ii]._source); 954 958 } 955 959 emit(newAntCrd(_staID, decoder()->_antList[ii]._xx, … … 963 967 QString rec2 = QString(": Receiver Firmware Version: %1 ").arg(decoder()->_recType[ii]._firmware); 964 968 QString rec3 = QString(": Receiver Serial Number: %1 ").arg(decoder()->_recType[ii]._serialnumber); 965 emitContent(_staID + rec1.toLatin1(), true); 966 emitContent(_staID + rec2.toLatin1(), true); 967 emitContent(_staID + rec3.toLatin1(), true); 969 emitContent(_staID + rec1.toLatin1(), true, decoder()->_recType[ii]._source); 970 emitContent(_staID + rec2.toLatin1(), true, decoder()->_recType[ii]._source); 971 emitContent(_staID + rec3.toLatin1(), true, decoder()->_recType[ii]._source); 968 972 } 969 973 … … 982 986 emitContent( 983 987 _staID + ": GLONASS Slot:Freq " + _gloSlots.join(" ").toLatin1(), 984 true); 988 true, decoder()->_gloFrqSource); 985 989 } 986 990 } … … 990 994 if (decoder()->_gloBiasInfo.changed()) { 991 995 QString gloCodePhaseBiases = decoder()->_gloBiasInfo.toString(); 992 emitContent(_staID + gloCodePhaseBiases.toLatin1(), true); 996 emitContent(_staID + gloCodePhaseBiases.toLatin1(), true, decoder()->_gloBiasSource); 993 997 decoder()->_gloBiasInfo.setChanged(false); 994 998 } … … 999 1003 // Service CRS 1000 1004 for (int ii = 0; ii < decoder()->_serviceCrs.size(); ii++) { 1005 GPSDecoder::t_typeInfo source; 1006 source._type = decoder()->_serviceCrs[ii]._msgType; 1007 source._size = decoder()->_serviceCrs[ii]._msgSize; 1001 1008 QString servicecrsname = QString(": Service CRS Name: %1 ").arg(decoder()->_serviceCrs[ii]._name); 1002 1009 QString coordinateEpoch = QString(": Service CRS Coordinate Epoch: %1 ").arg(decoder()->_serviceCrs[ii]._coordinateEpoch); 1003 1010 //QString ce = QString(": CE: %1 ").arg(decoder()->_serviceCrs[ii]._CE); 1004 emitContent(_staID + servicecrsname.toLatin1(), true); 1005 emitContent(_staID + coordinateEpoch.toLatin1(), true); 1011 emitContent(_staID + servicecrsname.toLatin1(), true, source); 1012 emitContent(_staID + coordinateEpoch.toLatin1(), true, source); 1006 1013 //emitContent(_staID + ce.toLatin1(), true); 1007 1014 } 1008 1015 // RTCM CRS 1009 1016 for (int ii = 0; ii < decoder()->_rtcmCrs.size(); ii++) { 1017 GPSDecoder::t_typeInfo source; 1018 source._type = decoder()->_rtcmCrs[ii]._msgType; 1019 source._size = decoder()->_rtcmCrs[ii]._msgSize; 1010 1020 QString rtcmcrsname = QString(": RTCM CRS Name: %1 ").arg(decoder()->_rtcmCrs[ii]._name); 1011 1021 QString anchor = QString(": RTCM CRS Anchor: %1 ").arg(decoder()->_rtcmCrs[ii]._anchor); 1012 1022 QString platenumber = QString(": RTCM CRS Plate Number: %1 ").arg(decoder()->_rtcmCrs[ii]._plateNumber); 1013 emitContent(_staID + rtcmcrsname.toLatin1(), true); 1014 emitContent(_staID + anchor.toLatin1(), true); 1015 emitContent(_staID + platenumber.toLatin1(), true); 1023 emitContent(_staID + rtcmcrsname.toLatin1(), true, source); 1024 emitContent(_staID + anchor.toLatin1(), true, source); 1025 emitContent(_staID + platenumber.toLatin1(), true, source); 1016 1026 for (int i = 0; i<decoder()->_rtcmCrs[ii]._databaseLinks.size(); i++) { 1017 1027 QString dblink = QString(": Database Link: %1 ").arg(decoder()->_rtcmCrs[ii]._databaseLinks[i]); 1018 emitContent(_staID + dblink.toLatin1(), true); 1028 emitContent(_staID + dblink.toLatin1(), true, source); 1019 1029 } 1020 1030 } … … 1024 1034 for (int ii = 0; ii < decoder()->_helmertPar.size(); ii++) { 1025 1035 t_helmertPar& helmertPar = decoder()->_helmertPar[ii]; 1036 GPSDecoder::t_typeInfo source; 1037 source._type = helmertPar._msgType; 1038 source._size = helmertPar._msgSize; 1026 1039 bncTime t; t.setmjd(0, helmertPar._mjd); QString dateStr = QString::fromStdString(t.datestr()); 1027 1040 QString sourcename = QString(": MT1301 Source Name: %1 ").arg(helmertPar._sourceName); … … 1037 1050 .arg(helmertPar._oxr).arg(helmertPar._oyr).arg(helmertPar._ozr); 1038 1051 QString parscale = QString(": MT1301 Helmert Par Scale: sc = %1, scr = %2").arg(helmertPar._sc).arg(helmertPar._scr); 1039 emitContent(_staID + sourcename.toLatin1(), true); 1040 emitContent(_staID + targetname.toLatin1(), true); 1041 emitContent(_staID + sysidentnum.toLatin1(), true); 1042 emitContent(_staID + trafomessageind.toLatin1(), true); 1043 emitContent(_staID + epoch.toLatin1(), true); 1044 emitContent(_staID + partrans.toLatin1(), true); 1045 emitContent(_staID + parrot.toLatin1(), true); 1046 emitContent(_staID + parscale.toLatin1(), true); 1052 emitContent(_staID + sourcename.toLatin1(), true, source); 1053 emitContent(_staID + targetname.toLatin1(), true, source); 1054 emitContent(_staID + sysidentnum.toLatin1(), true, source); 1055 emitContent(_staID + trafomessageind.toLatin1(), true, source); 1056 emitContent(_staID + epoch.toLatin1(), true, source); 1057 emitContent(_staID + partrans.toLatin1(), true, source); 1058 emitContent(_staID + parrot.toLatin1(), true, source); 1059 emitContent(_staID + parscale.toLatin1(), true, source); 1047 1060 } 1048 1061 } … … 1163 1176 } 1164 1177 1165 // Content of the stream found by the RTCM scan (miscScanRTCM) 1178 // Content of the stream found by the RTCM scan (miscScanRTCM), with type 1179 // and size of the RTCM message carrying the information 1166 1180 //////////////////////////////////////////////////////////////////////////// 1167 void bncGetThread::emitContent(const QByteArray& msg, bool showOnScreen) { 1168 emit newLogRecord(t_logRecord(t_logRecord::info, "stream", "stream_content", _staID, msg), 1169 showOnScreen); 1170 } 1181 void bncGetThread::emitContent(const QByteArray& msg, bool showOnScreen, 1182 const GPSDecoder::t_typeInfo& source) { 1183 t_logRecord rec(t_logRecord::info, "stream", "stream_content", _staID, msg); 1184 if (source._type) { 1185 rec.add("message_type", source._type); 1186 } 1187 if (source._size) { 1188 rec.add("size", int(source._size)); 1189 } 1190 emit newLogRecord(rec, showOnScreen); 1191 }
Note:
See TracChangeset
for help on using the changeset viewer.
