1 | /* -------------------------------------------------------------------------
|
---|
2 | * BKG NTRIP Server
|
---|
3 | * -------------------------------------------------------------------------
|
---|
4 | *
|
---|
5 | * Class: bncRtnetUploadCaster
|
---|
6 | *
|
---|
7 | * Purpose: Connection to NTRIP Caster
|
---|
8 | *
|
---|
9 | * Author: L. Mervart
|
---|
10 | *
|
---|
11 | * Created: 29-Mar-2011
|
---|
12 | *
|
---|
13 | * Changes:
|
---|
14 | *
|
---|
15 | * -----------------------------------------------------------------------*/
|
---|
16 |
|
---|
17 | #include <math.h>
|
---|
18 | #include "bncrtnetuploadcaster.h"
|
---|
19 | #include "bncsettings.h"
|
---|
20 | #include "bncephuser.h"
|
---|
21 | #include "bncclockrinex.h"
|
---|
22 | #include "bncsp3.h"
|
---|
23 | #include "gnss.h"
|
---|
24 |
|
---|
25 | using namespace std;
|
---|
26 |
|
---|
27 | // Constructor
|
---|
28 | ////////////////////////////////////////////////////////////////////////////
|
---|
29 | bncRtnetUploadCaster::bncRtnetUploadCaster(const QString& mountpoint,
|
---|
30 | const QString& outHost, int outPort, const QString& password,
|
---|
31 | const QString& crdTrafo, bool CoM, const QString& sp3FileName,
|
---|
32 | const QString& rnxFileName, int PID, int SID, int IOD, int iRow) :
|
---|
33 | bncUploadCaster(mountpoint, outHost, outPort, password, iRow, 0) {
|
---|
34 |
|
---|
35 | if (!mountpoint.isEmpty()) {
|
---|
36 | _casterID += mountpoint;
|
---|
37 | }
|
---|
38 | if (!outHost.isEmpty()) {
|
---|
39 | _casterID += " " + outHost;
|
---|
40 | if (outPort) {
|
---|
41 | _casterID += ":" + QString("%1").arg(outPort, 10);
|
---|
42 | }
|
---|
43 | }
|
---|
44 | if (!crdTrafo.isEmpty()) {
|
---|
45 | _casterID += " " + crdTrafo;
|
---|
46 | }
|
---|
47 | if (!sp3FileName.isEmpty()) {
|
---|
48 | _casterID += " " + sp3FileName;
|
---|
49 | }
|
---|
50 | if (!rnxFileName.isEmpty()) {
|
---|
51 | _casterID += " " + rnxFileName;
|
---|
52 | }
|
---|
53 |
|
---|
54 | _crdTrafo = crdTrafo;
|
---|
55 | _CoM = CoM;
|
---|
56 | _PID = PID;
|
---|
57 | _SID = SID;
|
---|
58 | _IOD = IOD;
|
---|
59 |
|
---|
60 | // Member that receives the ephemeris
|
---|
61 | // ----------------------------------
|
---|
62 | _ephUser = new bncEphUser(true);
|
---|
63 |
|
---|
64 | bncSettings settings;
|
---|
65 | QString intr = settings.value("uploadIntr").toString();
|
---|
66 | QStringList hlp = settings.value("cmbStreams").toStringList();
|
---|
67 | _samplRtcmEphCorr = settings.value("uploadSamplRtcmEphCorr").toDouble();
|
---|
68 | if (hlp.size() > 1) { // combination stream upload
|
---|
69 | _samplRtcmClkCorr = settings.value("cmbSampl").toInt();
|
---|
70 | }
|
---|
71 | else { // single stream upload or sp3 file generation
|
---|
72 | _samplRtcmClkCorr = 5; // default
|
---|
73 | }
|
---|
74 | int samplClkRnx = settings.value("uploadSamplClkRnx").toInt();
|
---|
75 | int samplSp3 = settings.value("uploadSamplSp3").toInt() * 60;
|
---|
76 |
|
---|
77 | if (_samplRtcmEphCorr == 0.0) {
|
---|
78 | _usedEph = 0;
|
---|
79 | }
|
---|
80 | else {
|
---|
81 | _usedEph = new QMap<QString, const t_eph*>;
|
---|
82 | }
|
---|
83 |
|
---|
84 | // RINEX writer
|
---|
85 | // ------------
|
---|
86 | if (!rnxFileName.isEmpty()) {
|
---|
87 | _rnx = new bncClockRinex(rnxFileName, intr, samplClkRnx);
|
---|
88 | }
|
---|
89 | else {
|
---|
90 | _rnx = 0;
|
---|
91 | }
|
---|
92 |
|
---|
93 | // SP3 writer
|
---|
94 | // ----------
|
---|
95 | if (!sp3FileName.isEmpty()) {
|
---|
96 | _sp3 = new bncSP3(sp3FileName, intr, samplSp3);
|
---|
97 | }
|
---|
98 | else {
|
---|
99 | _sp3 = 0;
|
---|
100 | }
|
---|
101 |
|
---|
102 | // Set Transformation Parameters
|
---|
103 | // -----------------------------
|
---|
104 | // Transformation Parameters from ITRF2014 to ETRF2000
|
---|
105 | if (_crdTrafo == "ETRF2000") {
|
---|
106 | _dx = 0.0537;
|
---|
107 | _dy = 0.0512;
|
---|
108 | _dz = -0.0551;
|
---|
109 | _dxr = 0.0001;
|
---|
110 | _dyr = 0.0001;
|
---|
111 | _dzr = -0.0019;
|
---|
112 | _ox = -0.000891;
|
---|
113 | _oy = -0.005390;
|
---|
114 | _oz = 0.008712;
|
---|
115 | _oxr = -0.000081;
|
---|
116 | _oyr = -0.000490;
|
---|
117 | _ozr = +0.000792;
|
---|
118 | _sc = 1.02;
|
---|
119 | _scr = 0.11;
|
---|
120 | _t0 = 2000.0;
|
---|
121 | }
|
---|
122 | // Transformation Parameters from ITRF2014 to GDA2020 (Ryan Ruddick, GA)
|
---|
123 | else if (_crdTrafo == "GDA2020") {
|
---|
124 | _dx = 0.0;
|
---|
125 | _dy = 0.0;
|
---|
126 | _dz = 0.0;
|
---|
127 | _dxr = 0.0;
|
---|
128 | _dyr = 0.0;
|
---|
129 | _dzr = 0.0;
|
---|
130 | _ox = 0.0;
|
---|
131 | _oy = 0.0;
|
---|
132 | _oz = 0.0;
|
---|
133 | _oxr = 0.00150379;
|
---|
134 | _oyr = 0.00118346;
|
---|
135 | _ozr = 0.00120716;
|
---|
136 | _sc = 0.0;
|
---|
137 | _scr = 0.0;
|
---|
138 | _t0 = 2020.0;
|
---|
139 | }
|
---|
140 | // Transformation Parameters from IGb14 to SIRGAS2000 (Sonia Costa, BRA)
|
---|
141 | else if (_crdTrafo == "SIRGAS2000") {
|
---|
142 | _dx = 0.0026;
|
---|
143 | _dy = 0.0018;
|
---|
144 | _dz = -0.0061;
|
---|
145 | _dxr = 0.0000;
|
---|
146 | _dyr = 0.0000;
|
---|
147 | _dzr = 0.0000;
|
---|
148 | _ox = 0.000170;
|
---|
149 | _oy = -0.000030;
|
---|
150 | _oz = 0.000070;
|
---|
151 | _oxr = 0.000000;
|
---|
152 | _oyr = 0.000000;
|
---|
153 | _ozr = 0.000000;
|
---|
154 | _sc = -1.000;
|
---|
155 | _scr = 0.000;
|
---|
156 | _t0 = 2000.4;
|
---|
157 | }
|
---|
158 | // Transformation Parameters from ITRF2014 to DREF91
|
---|
159 | else if (_crdTrafo == "DREF91") {
|
---|
160 | _dx = 0.0537;
|
---|
161 | _dy = 0.0512;
|
---|
162 | _dz = -0.0551;
|
---|
163 | _dxr = 0.0001;
|
---|
164 | _dyr = 0.0001;
|
---|
165 | _dzr = -0.0019;
|
---|
166 | _ox = -0.000233;
|
---|
167 | _oy = -0.005598;
|
---|
168 | _oz = 0.009467;
|
---|
169 | _oxr = -0.000081;
|
---|
170 | _oyr = -0.000490;
|
---|
171 | _ozr = 0.000792;
|
---|
172 | _sc = 1.02;
|
---|
173 | _scr = 0.11;
|
---|
174 | _t0 = 2000.0;
|
---|
175 | }
|
---|
176 | else if (_crdTrafo == "Custom") {
|
---|
177 | _dx = settings.value("trafo_dx").toDouble();
|
---|
178 | _dy = settings.value("trafo_dy").toDouble();
|
---|
179 | _dz = settings.value("trafo_dz").toDouble();
|
---|
180 | _dxr = settings.value("trafo_dxr").toDouble();
|
---|
181 | _dyr = settings.value("trafo_dyr").toDouble();
|
---|
182 | _dzr = settings.value("trafo_dzr").toDouble();
|
---|
183 | _ox = settings.value("trafo_ox").toDouble();
|
---|
184 | _oy = settings.value("trafo_oy").toDouble();
|
---|
185 | _oz = settings.value("trafo_oz").toDouble();
|
---|
186 | _oxr = settings.value("trafo_oxr").toDouble();
|
---|
187 | _oyr = settings.value("trafo_oyr").toDouble();
|
---|
188 | _ozr = settings.value("trafo_ozr").toDouble();
|
---|
189 | _sc = settings.value("trafo_sc").toDouble();
|
---|
190 | _scr = settings.value("trafo_scr").toDouble();
|
---|
191 | _t0 = settings.value("trafo_t0").toDouble();
|
---|
192 | }
|
---|
193 | }
|
---|
194 |
|
---|
195 | // Destructor
|
---|
196 | ////////////////////////////////////////////////////////////////////////////
|
---|
197 | bncRtnetUploadCaster::~bncRtnetUploadCaster() {
|
---|
198 | if (isRunning()) {
|
---|
199 | wait();
|
---|
200 | }
|
---|
201 | delete _rnx;
|
---|
202 | delete _sp3;
|
---|
203 | delete _ephUser;
|
---|
204 | delete _usedEph;
|
---|
205 | }
|
---|
206 |
|
---|
207 | //
|
---|
208 | ////////////////////////////////////////////////////////////////////////////
|
---|
209 | void bncRtnetUploadCaster::decodeRtnetStream(char* buffer, int bufLen) {
|
---|
210 |
|
---|
211 | QMutexLocker locker(&_mutex);
|
---|
212 |
|
---|
213 | // Append to internal buffer
|
---|
214 | // -------------------------
|
---|
215 | _rtnetStreamBuffer.append(QByteArray(buffer, bufLen));
|
---|
216 |
|
---|
217 | // Select buffer part that contains last epoch
|
---|
218 | // -------------------------------------------
|
---|
219 | QStringList lines;
|
---|
220 | int iEpoBeg = _rtnetStreamBuffer.lastIndexOf('*'); // begin of last epoch
|
---|
221 | if (iEpoBeg == -1) {
|
---|
222 | _rtnetStreamBuffer.clear();
|
---|
223 | return;
|
---|
224 | }
|
---|
225 | int iEpoBegEarlier = _rtnetStreamBuffer.indexOf('*');
|
---|
226 | if (iEpoBegEarlier != -1 && iEpoBegEarlier < iEpoBeg) { // are there more epoch lines in buffer?
|
---|
227 | _rtnetStreamBuffer = _rtnetStreamBuffer.mid(iEpoBegEarlier);
|
---|
228 | }
|
---|
229 | else {
|
---|
230 | _rtnetStreamBuffer = _rtnetStreamBuffer.mid(iEpoBeg);
|
---|
231 | }
|
---|
232 |
|
---|
233 | int iEpoEnd = _rtnetStreamBuffer.indexOf("EOE"); // end of first epoch
|
---|
234 | if (iEpoEnd == -1) {
|
---|
235 | return;
|
---|
236 | }
|
---|
237 | else {
|
---|
238 | lines = _rtnetStreamBuffer.left(iEpoEnd).split('\n',
|
---|
239 | QString::SkipEmptyParts);
|
---|
240 | _rtnetStreamBuffer = _rtnetStreamBuffer.mid(iEpoEnd + 3);
|
---|
241 | }
|
---|
242 |
|
---|
243 | if (lines.size() < 2) {
|
---|
244 | return;
|
---|
245 | }
|
---|
246 |
|
---|
247 | // Read first line (with epoch time)
|
---|
248 | // ---------------------------------
|
---|
249 | QTextStream in(lines[0].toAscii());
|
---|
250 | QString hlp;
|
---|
251 | int year, month, day, hour, min;
|
---|
252 | double sec;
|
---|
253 | in >> hlp >> year >> month >> day >> hour >> min >> sec;
|
---|
254 | bncTime epoTime;
|
---|
255 | epoTime.set(year, month, day, hour, min, sec);
|
---|
256 |
|
---|
257 | emit(newMessage(
|
---|
258 | "bncRtnetUploadCaster: decode " + QByteArray(epoTime.datestr().c_str())
|
---|
259 | + " " + QByteArray(epoTime.timestr().c_str()) + " "
|
---|
260 | + _casterID.toAscii(), false));
|
---|
261 |
|
---|
262 | struct ClockOrbit co;
|
---|
263 | memset(&co, 0, sizeof(co));
|
---|
264 | co.EpochTime[CLOCKORBIT_SATGPS] = static_cast<int>(epoTime.gpssec());
|
---|
265 | double gt = epoTime.gpssec() + 3 * 3600 - gnumleap(year, month, day);
|
---|
266 | co.EpochTime[CLOCKORBIT_SATGLONASS] = static_cast<int>(fmod(gt, 86400.0));
|
---|
267 | co.EpochTime[CLOCKORBIT_SATGALILEO] = static_cast<int>(epoTime.gpssec());
|
---|
268 | co.EpochTime[CLOCKORBIT_SATQZSS] = static_cast<int>(epoTime.gpssec());
|
---|
269 | co.EpochTime[CLOCKORBIT_SATSBAS] = static_cast<int>(epoTime.gpssec());
|
---|
270 | co.EpochTime[CLOCKORBIT_SATBDS] = static_cast<int>(epoTime.bdssec());
|
---|
271 | co.Supplied[COBOFS_CLOCK] = 1;
|
---|
272 | co.Supplied[COBOFS_ORBIT] = 1;
|
---|
273 | co.SatRefDatum = DATUM_ITRF;
|
---|
274 | co.SSRIOD = _IOD;
|
---|
275 | co.SSRProviderID = _PID; // 256 .. BKG, 257 ... EUREF
|
---|
276 | co.SSRSolutionID = _SID;
|
---|
277 |
|
---|
278 | struct CodeBias bias;
|
---|
279 | memset(&bias, 0, sizeof(bias));
|
---|
280 | bias.EpochTime[CLOCKORBIT_SATGPS] = co.EpochTime[CLOCKORBIT_SATGPS];
|
---|
281 | bias.EpochTime[CLOCKORBIT_SATGLONASS] = co.EpochTime[CLOCKORBIT_SATGLONASS];
|
---|
282 | bias.EpochTime[CLOCKORBIT_SATGALILEO] = co.EpochTime[CLOCKORBIT_SATGALILEO];
|
---|
283 | bias.EpochTime[CLOCKORBIT_SATQZSS] = co.EpochTime[CLOCKORBIT_SATQZSS];
|
---|
284 | bias.EpochTime[CLOCKORBIT_SATSBAS] = co.EpochTime[CLOCKORBIT_SATSBAS];
|
---|
285 | bias.EpochTime[CLOCKORBIT_SATBDS] = co.EpochTime[CLOCKORBIT_SATBDS];
|
---|
286 | bias.SSRIOD = _IOD;
|
---|
287 | bias.SSRProviderID = _PID;
|
---|
288 | bias.SSRSolutionID = _SID;
|
---|
289 |
|
---|
290 | struct PhaseBias phasebias;
|
---|
291 | memset(&phasebias, 0, sizeof(phasebias));
|
---|
292 | unsigned int dispersiveBiasConsistenyIndicator = 0;
|
---|
293 | unsigned int mwConsistencyIndicator = 0;
|
---|
294 | phasebias.EpochTime[CLOCKORBIT_SATGPS] = co.EpochTime[CLOCKORBIT_SATGPS];
|
---|
295 | phasebias.EpochTime[CLOCKORBIT_SATGLONASS] = co.EpochTime[CLOCKORBIT_SATGLONASS];
|
---|
296 | phasebias.EpochTime[CLOCKORBIT_SATGALILEO] = co.EpochTime[CLOCKORBIT_SATGALILEO];
|
---|
297 | phasebias.EpochTime[CLOCKORBIT_SATQZSS] = co.EpochTime[CLOCKORBIT_SATQZSS];
|
---|
298 | phasebias.EpochTime[CLOCKORBIT_SATSBAS] = co.EpochTime[CLOCKORBIT_SATSBAS];
|
---|
299 | phasebias.EpochTime[CLOCKORBIT_SATBDS] = co.EpochTime[CLOCKORBIT_SATBDS];
|
---|
300 | phasebias.SSRIOD = _IOD;
|
---|
301 | phasebias.SSRProviderID = _PID;
|
---|
302 | phasebias.SSRSolutionID = _SID;
|
---|
303 |
|
---|
304 | struct VTEC vtec;
|
---|
305 | memset(&vtec, 0, sizeof(vtec));
|
---|
306 | vtec.EpochTime = static_cast<int>(epoTime.gpssec());
|
---|
307 | vtec.SSRIOD = _IOD;
|
---|
308 | vtec.SSRProviderID = _PID;
|
---|
309 | vtec.SSRSolutionID = _SID;
|
---|
310 |
|
---|
311 | // Default Update Interval
|
---|
312 | // -----------------------
|
---|
313 | int clkUpdInd = 2; // 5 sec
|
---|
314 | int ephUpdInd = clkUpdInd; // default
|
---|
315 |
|
---|
316 | if (_samplRtcmClkCorr > 5.0 && _samplRtcmEphCorr <= 5.0) { // combined orb and clock
|
---|
317 | ephUpdInd = determineUpdateInd(_samplRtcmClkCorr);
|
---|
318 | }
|
---|
319 | if (_samplRtcmClkCorr > 5.0) {
|
---|
320 | clkUpdInd = determineUpdateInd(_samplRtcmClkCorr);
|
---|
321 | }
|
---|
322 | if (_samplRtcmEphCorr > 5.0) {
|
---|
323 | ephUpdInd = determineUpdateInd(_samplRtcmEphCorr);
|
---|
324 | }
|
---|
325 |
|
---|
326 | co.UpdateInterval = clkUpdInd;
|
---|
327 | bias.UpdateInterval = clkUpdInd;
|
---|
328 | phasebias.UpdateInterval = clkUpdInd;
|
---|
329 |
|
---|
330 | for (int ii = 1; ii < lines.size(); ii++) {
|
---|
331 | QString key; // prn or key VTEC, IND (phase bias indicators)
|
---|
332 | double rtnUra = 0.0; // [m]
|
---|
333 | ColumnVector rtnAPC; rtnAPC.ReSize(3); rtnAPC = 0.0; // [m, m, m]
|
---|
334 | ColumnVector rtnVel; rtnVel.ReSize(3); rtnVel = 0.0; // [m/s, m/s, m/s]]
|
---|
335 | ColumnVector rtnCoM; rtnCoM.ReSize(3); rtnCoM = 0.0; // [m, m, m]
|
---|
336 | ColumnVector rtnClk; rtnClk.ReSize(3); rtnClk = 0.0; // [m, m/s, m/s²]
|
---|
337 | ColumnVector rtnClkSig; rtnClkSig.ReSize(3); rtnClkSig = 0.0; // [m, m/s, m/s²]
|
---|
338 | t_prn prn;
|
---|
339 |
|
---|
340 | QTextStream in(lines[ii].toAscii());
|
---|
341 | in >> key;
|
---|
342 |
|
---|
343 | // non-satellite specific parameters
|
---|
344 | if (key.contains("IND", Qt::CaseSensitive)) {
|
---|
345 | in >> dispersiveBiasConsistenyIndicator >> mwConsistencyIndicator;
|
---|
346 | continue;
|
---|
347 | }
|
---|
348 |
|
---|
349 | // non-satellite specific parameters
|
---|
350 | if (key.contains("VTEC", Qt::CaseSensitive)) {
|
---|
351 | double ui;
|
---|
352 | in >> ui >> vtec.NumLayers;
|
---|
353 | vtec.UpdateInterval = (unsigned int) determineUpdateInd(ui);
|
---|
354 | for (unsigned ll = 0; ll < vtec.NumLayers; ll++) {
|
---|
355 | int dummy;
|
---|
356 | in >> dummy >> vtec.Layers[ll].Degree >> vtec.Layers[ll].Order
|
---|
357 | >> vtec.Layers[ll].Height;
|
---|
358 | for (unsigned iDeg = 0; iDeg <= vtec.Layers[ll].Degree; iDeg++) {
|
---|
359 | for (unsigned iOrd = 0; iOrd <= vtec.Layers[ll].Order; iOrd++) {
|
---|
360 | in >> vtec.Layers[ll].Cosinus[iDeg][iOrd];
|
---|
361 | }
|
---|
362 | }
|
---|
363 | for (unsigned iDeg = 0; iDeg <= vtec.Layers[ll].Degree; iDeg++) {
|
---|
364 | for (unsigned iOrd = 0; iOrd <= vtec.Layers[ll].Order; iOrd++) {
|
---|
365 | in >> vtec.Layers[ll].Sinus[iDeg][iOrd];
|
---|
366 | }
|
---|
367 | }
|
---|
368 | }
|
---|
369 | continue;
|
---|
370 | }
|
---|
371 |
|
---|
372 | // satellite specific parameters
|
---|
373 | char sys = key.mid(0, 1).at(0).toAscii();
|
---|
374 | int number = key.mid(1, 2).toInt();
|
---|
375 | int flags = 0;
|
---|
376 | if (sys == 'E') { // I/NAV
|
---|
377 | flags = 1;
|
---|
378 | }
|
---|
379 | prn.set(sys, number, flags);
|
---|
380 | QString prnInternalStr = QString::fromStdString(prn.toInternalString());
|
---|
381 | QString prnStr = QString::fromStdString(prn.toString());
|
---|
382 |
|
---|
383 | const t_eph* ephLast = _ephUser->ephLast(prnInternalStr);
|
---|
384 | const t_eph* ephPrev = _ephUser->ephPrev(prnInternalStr);
|
---|
385 | const t_eph* eph = ephLast;
|
---|
386 |
|
---|
387 | if (eph) {
|
---|
388 |
|
---|
389 | // Use previous ephemeris if the last one is too recent
|
---|
390 | // ----------------------------------------------------
|
---|
391 | const int MINAGE = 60; // seconds
|
---|
392 | if (ephPrev && eph->receptDateTime().isValid()
|
---|
393 | && eph->receptDateTime().secsTo(currentDateAndTimeGPS()) < MINAGE) {
|
---|
394 | eph = ephPrev;
|
---|
395 | }
|
---|
396 |
|
---|
397 | // Make sure the clock messages refer to same IOD as orbit messages
|
---|
398 | // ----------------------------------------------------------------
|
---|
399 | if (_usedEph) {
|
---|
400 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
401 | (*_usedEph)[prnInternalStr] = eph;
|
---|
402 | }
|
---|
403 | else {
|
---|
404 | eph = 0;
|
---|
405 | if (_usedEph->contains(prnInternalStr)) {
|
---|
406 | const t_eph* usedEph = _usedEph->value(prnInternalStr);
|
---|
407 | if (usedEph == ephLast) {
|
---|
408 | eph = ephLast;
|
---|
409 | }
|
---|
410 | else if (usedEph == ephPrev) {
|
---|
411 | eph = ephPrev;
|
---|
412 | }
|
---|
413 | }
|
---|
414 | }
|
---|
415 | }
|
---|
416 | }
|
---|
417 |
|
---|
418 | if (eph &&
|
---|
419 | eph->checkState() != t_eph::bad &&
|
---|
420 | eph->checkState() != t_eph::unhealthy ) {
|
---|
421 | QMap<QString, double> codeBiases;
|
---|
422 | QList<phaseBiasSignal> phaseBiasList;
|
---|
423 | phaseBiasesSat pbSat;
|
---|
424 |
|
---|
425 | while (true) {
|
---|
426 | QString key;
|
---|
427 | int numVal = 0;
|
---|
428 | in >> key;
|
---|
429 | if (in.status() != QTextStream::Ok) {
|
---|
430 | break;
|
---|
431 | }
|
---|
432 | if (key == "APC") {
|
---|
433 | in >> numVal;
|
---|
434 | rtnAPC.ReSize(3); rtnAPC = 0.0;
|
---|
435 | for (int ii = 0; ii < numVal; ii++) {
|
---|
436 | in >> rtnAPC[ii];
|
---|
437 | }
|
---|
438 | }
|
---|
439 | else if (key == "Ura") {
|
---|
440 | in >> numVal;
|
---|
441 | if (numVal == 1)
|
---|
442 | in >> rtnUra;
|
---|
443 | }
|
---|
444 | else if (key == "Clk") {
|
---|
445 | in >> numVal;
|
---|
446 | rtnClk.ReSize(3); rtnClk = 0.0;
|
---|
447 | for (int ii = 0; ii < numVal; ii++) {
|
---|
448 | in >> rtnClk[ii];
|
---|
449 | }
|
---|
450 | }
|
---|
451 | else if (key == "ClkSig") {
|
---|
452 | in >> numVal;
|
---|
453 | rtnClkSig.ReSize(3); rtnClkSig = 0.0;
|
---|
454 | for (int ii = 0; ii < numVal; ii++) {
|
---|
455 | in >> rtnClkSig[ii];
|
---|
456 | }
|
---|
457 | }
|
---|
458 | else if (key == "Vel") {
|
---|
459 | in >> numVal;
|
---|
460 | rtnVel.ReSize(3); rtnVel = 0.0;
|
---|
461 | for (int ii = 0; ii < numVal; ii++) {
|
---|
462 | in >> rtnVel[ii];
|
---|
463 | }
|
---|
464 | }
|
---|
465 | else if (key == "CoM") {
|
---|
466 | in >> numVal;
|
---|
467 | rtnCoM.ReSize(3); rtnCoM = 0.0;
|
---|
468 | for (int ii = 0; ii < numVal; ii++) {
|
---|
469 | in >> rtnCoM[ii];
|
---|
470 | }
|
---|
471 | }
|
---|
472 | else if (key == "CodeBias") {
|
---|
473 | in >> numVal;
|
---|
474 | for (int ii = 0; ii < numVal; ii++) {
|
---|
475 | QString type;
|
---|
476 | double value;
|
---|
477 | in >> type >> value;
|
---|
478 | codeBiases[type] = value;
|
---|
479 | }
|
---|
480 | }
|
---|
481 | else if (key == "YawAngle") {
|
---|
482 | in >> numVal >> pbSat.yawAngle;
|
---|
483 | if (pbSat.yawAngle < 0.0) {
|
---|
484 | pbSat.yawAngle += (2*M_PI);
|
---|
485 | }
|
---|
486 | else if (pbSat.yawAngle > 2*M_PI) {
|
---|
487 | pbSat.yawAngle -= (2*M_PI);
|
---|
488 | }
|
---|
489 | }
|
---|
490 | else if (key == "YawRate") {
|
---|
491 | in >> numVal >> pbSat.yawRate;
|
---|
492 | }
|
---|
493 | else if (key == "PhaseBias") {
|
---|
494 | in >> numVal;
|
---|
495 | for (int ii = 0; ii < numVal; ii++) {
|
---|
496 | phaseBiasSignal pb;
|
---|
497 | in >> pb.type >> pb.bias >> pb.integerIndicator
|
---|
498 | >> pb.wlIndicator >> pb.discontinuityCounter;
|
---|
499 | phaseBiasList.append(pb);
|
---|
500 | }
|
---|
501 | }
|
---|
502 | else {
|
---|
503 | emit(newMessage(" RTNET format error: "
|
---|
504 | + lines[ii].toAscii(), false));
|
---|
505 | }
|
---|
506 | }
|
---|
507 |
|
---|
508 | struct ClockOrbit::SatData* sd = 0;
|
---|
509 | if (prn.system() == 'G') {
|
---|
510 | sd = co.Sat + co.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
511 | ++co.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
512 | }
|
---|
513 | else if (prn.system() == 'R') {
|
---|
514 | sd = co.Sat + CLOCKORBIT_NUMGPS + co.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
515 | ++co.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
516 | }
|
---|
517 | else if (prn.system() == 'E') {
|
---|
518 | sd = co.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
519 | + co.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
520 | ++co.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
521 | }
|
---|
522 | else if (prn.system() == 'J') {
|
---|
523 | sd = co.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
524 | + CLOCKORBIT_NUMGALILEO + co.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
525 | ++co.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
526 | }
|
---|
527 | else if (prn.system() == 'S') {
|
---|
528 | sd = co.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
529 | + CLOCKORBIT_NUMGALILEO + CLOCKORBIT_NUMQZSS
|
---|
530 | + co.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
531 | ++co.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
532 | }
|
---|
533 | else if (prn.system() == 'C') {
|
---|
534 | sd = co.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
535 | + CLOCKORBIT_NUMGALILEO + CLOCKORBIT_NUMQZSS + CLOCKORBIT_NUMSBAS
|
---|
536 | + co.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
537 | ++co.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
538 | }
|
---|
539 | if (sd) {
|
---|
540 | QString outLine;
|
---|
541 | t_irc irc = processSatellite(eph, epoTime.gpsw(), epoTime.gpssec(), prnStr, rtnAPC,
|
---|
542 | rtnUra, rtnClk, rtnVel, rtnCoM, rtnClkSig, sd, outLine);
|
---|
543 | if (irc != success) {
|
---|
544 | // very few cases: check states bad and unhealthy are excluded earlier
|
---|
545 | sd->ID = prnStr.mid(1).toInt(); // to prevent G00, R00 entries
|
---|
546 | sd->IOD = eph->IOD();
|
---|
547 | }
|
---|
548 | }
|
---|
549 |
|
---|
550 | // Code Biases
|
---|
551 | // -----------
|
---|
552 | struct CodeBias::BiasSat* biasSat = 0;
|
---|
553 | if (!codeBiases.isEmpty()) {
|
---|
554 | if (prn.system() == 'G') {
|
---|
555 | biasSat = bias.Sat + bias.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
556 | ++bias.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
557 | }
|
---|
558 | else if (prn.system() == 'R') {
|
---|
559 | biasSat = bias.Sat + CLOCKORBIT_NUMGPS
|
---|
560 | + bias.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
561 | ++bias.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
562 | }
|
---|
563 | else if (prn.system() == 'E') {
|
---|
564 | biasSat = bias.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
565 | + bias.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
566 | ++bias.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
567 | }
|
---|
568 | else if (prn.system() == 'J') {
|
---|
569 | biasSat = bias.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
570 | + CLOCKORBIT_NUMGALILEO + bias.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
571 | ++bias.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
572 | }
|
---|
573 | else if (prn.system() == 'S') {
|
---|
574 | biasSat = bias.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
575 | + CLOCKORBIT_NUMGALILEO + CLOCKORBIT_NUMQZSS
|
---|
576 | + bias.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
577 | ++bias.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
578 | }
|
---|
579 | else if (prn.system() == 'C') {
|
---|
580 | biasSat = bias.Sat + CLOCKORBIT_NUMGPS + CLOCKORBIT_NUMGLONASS
|
---|
581 | + CLOCKORBIT_NUMGALILEO + CLOCKORBIT_NUMQZSS + CLOCKORBIT_NUMSBAS
|
---|
582 | + bias.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
583 | ++bias.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
584 | }
|
---|
585 | }
|
---|
586 |
|
---|
587 | if (biasSat) {
|
---|
588 | biasSat->ID = prn.number();
|
---|
589 | biasSat->NumberOfCodeBiases = 0;
|
---|
590 | if (prn.system() == 'G') {
|
---|
591 | QMapIterator<QString, double> it(codeBiases);
|
---|
592 | while (it.hasNext()) {
|
---|
593 | it.next();
|
---|
594 | if (it.key() == "1C") {
|
---|
595 | int ii = biasSat->NumberOfCodeBiases;
|
---|
596 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
597 | break;
|
---|
598 | biasSat->NumberOfCodeBiases += 1;
|
---|
599 | biasSat->Biases[ii].Type = CODETYPEGPS_L1_CA;
|
---|
600 | biasSat->Biases[ii].Bias = it.value();
|
---|
601 | }
|
---|
602 | else if (it.key() == "1S") {
|
---|
603 | int ii = biasSat->NumberOfCodeBiases;
|
---|
604 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
605 | break;
|
---|
606 | biasSat->NumberOfCodeBiases += 1;
|
---|
607 | biasSat->Biases[ii].Type = CODETYPEGPS_L1C_D;
|
---|
608 | biasSat->Biases[ii].Bias = it.value();
|
---|
609 | }
|
---|
610 | else if (it.key() == "1L") {
|
---|
611 | int ii = biasSat->NumberOfCodeBiases;
|
---|
612 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
613 | break;
|
---|
614 | biasSat->NumberOfCodeBiases += 1;
|
---|
615 | biasSat->Biases[ii].Type = CODETYPEGPS_L1C_P;
|
---|
616 | biasSat->Biases[ii].Bias = it.value();
|
---|
617 | }
|
---|
618 | else if (it.key() == "1X") {
|
---|
619 | int ii = biasSat->NumberOfCodeBiases;
|
---|
620 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
621 | break;
|
---|
622 | biasSat->NumberOfCodeBiases += 1;
|
---|
623 | biasSat->Biases[ii].Type = CODETYPEGPS_L1C_DP;
|
---|
624 | biasSat->Biases[ii].Bias = it.value();
|
---|
625 | }
|
---|
626 | else if (it.key() == "1P") {
|
---|
627 | int ii = biasSat->NumberOfCodeBiases;
|
---|
628 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
629 | break;
|
---|
630 | biasSat->NumberOfCodeBiases += 1;
|
---|
631 | biasSat->Biases[ii].Type = CODETYPEGPS_L1_P;
|
---|
632 | biasSat->Biases[ii].Bias = it.value();
|
---|
633 | }
|
---|
634 | else if (it.key() == "1W") {
|
---|
635 | int ii = biasSat->NumberOfCodeBiases;
|
---|
636 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
637 | break;
|
---|
638 | biasSat->NumberOfCodeBiases += 1;
|
---|
639 | biasSat->Biases[ii].Type = CODETYPEGPS_L1_Z;
|
---|
640 | biasSat->Biases[ii].Bias = it.value();
|
---|
641 | }
|
---|
642 | else if (it.key() == "2C") {
|
---|
643 | int ii = biasSat->NumberOfCodeBiases;
|
---|
644 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
645 | break;
|
---|
646 | biasSat->NumberOfCodeBiases += 1;
|
---|
647 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_CA;
|
---|
648 | biasSat->Biases[ii].Bias = it.value();
|
---|
649 | }
|
---|
650 | else if (it.key() == "2D") {
|
---|
651 | int ii = biasSat->NumberOfCodeBiases;
|
---|
652 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
653 | break;
|
---|
654 | biasSat->NumberOfCodeBiases += 1;
|
---|
655 | biasSat->Biases[ii].Type = CODETYPEGPS_SEMI_CODELESS;
|
---|
656 | biasSat->Biases[ii].Bias = it.value();
|
---|
657 | }
|
---|
658 | else if (it.key() == "2S") {
|
---|
659 | int ii = biasSat->NumberOfCodeBiases;
|
---|
660 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
661 | break;
|
---|
662 | biasSat->NumberOfCodeBiases += 1;
|
---|
663 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_CM;
|
---|
664 | biasSat->Biases[ii].Bias = it.value();
|
---|
665 | }
|
---|
666 | else if (it.key() == "2L") {
|
---|
667 | int ii = biasSat->NumberOfCodeBiases;
|
---|
668 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
669 | break;
|
---|
670 | biasSat->NumberOfCodeBiases += 1;
|
---|
671 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_CL;
|
---|
672 | biasSat->Biases[ii].Bias = it.value();
|
---|
673 | }
|
---|
674 | else if (it.key() == "2X") {
|
---|
675 | int ii = biasSat->NumberOfCodeBiases;
|
---|
676 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
677 | break;
|
---|
678 | biasSat->NumberOfCodeBiases += 1;
|
---|
679 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_CML;
|
---|
680 | biasSat->Biases[ii].Bias = it.value();
|
---|
681 | }
|
---|
682 | else if (it.key() == "2P") {
|
---|
683 | int ii = biasSat->NumberOfCodeBiases;
|
---|
684 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
685 | break;
|
---|
686 | biasSat->NumberOfCodeBiases += 1;
|
---|
687 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_P;
|
---|
688 | biasSat->Biases[ii].Bias = it.value();
|
---|
689 | }
|
---|
690 | else if (it.key() == "2W") {
|
---|
691 | int ii = biasSat->NumberOfCodeBiases;
|
---|
692 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
693 | break;
|
---|
694 | biasSat->NumberOfCodeBiases += 1;
|
---|
695 | biasSat->Biases[ii].Type = CODETYPEGPS_L2_Z;
|
---|
696 | biasSat->Biases[ii].Bias = it.value();
|
---|
697 | }
|
---|
698 | else if (it.key() == "5I") {
|
---|
699 | int ii = biasSat->NumberOfCodeBiases;
|
---|
700 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
701 | break;
|
---|
702 | biasSat->NumberOfCodeBiases += 1;
|
---|
703 | biasSat->Biases[ii].Type = CODETYPEGPS_L5_I;
|
---|
704 | biasSat->Biases[ii].Bias = it.value();
|
---|
705 | }
|
---|
706 | else if (it.key() == "5Q") {
|
---|
707 | int ii = biasSat->NumberOfCodeBiases;
|
---|
708 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
709 | break;
|
---|
710 | biasSat->NumberOfCodeBiases += 1;
|
---|
711 | biasSat->Biases[ii].Type = CODETYPEGPS_L5_Q;
|
---|
712 | biasSat->Biases[ii].Bias = it.value();
|
---|
713 | }
|
---|
714 | else if (it.key() == "5X") {
|
---|
715 | int ii = biasSat->NumberOfCodeBiases;
|
---|
716 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
717 | break;
|
---|
718 | biasSat->NumberOfCodeBiases += 1;
|
---|
719 | biasSat->Biases[ii].Type = CODETYPEGPS_L5_IQ;
|
---|
720 | biasSat->Biases[ii].Bias = it.value();
|
---|
721 | }
|
---|
722 | }
|
---|
723 | }
|
---|
724 | else if (prn.system() == 'R') {
|
---|
725 | QMapIterator<QString, double> it(codeBiases);
|
---|
726 | while (it.hasNext()) {
|
---|
727 | it.next();
|
---|
728 | if (it.key() == "1C") {
|
---|
729 | int ii = biasSat->NumberOfCodeBiases;
|
---|
730 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
731 | break;
|
---|
732 | biasSat->NumberOfCodeBiases += 1;
|
---|
733 | biasSat->Biases[ii].Type = CODETYPEGLONASS_L1_CA;
|
---|
734 | biasSat->Biases[ii].Bias = it.value();
|
---|
735 | }
|
---|
736 | else if (it.key() == "1P") {
|
---|
737 | int ii = biasSat->NumberOfCodeBiases;
|
---|
738 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
739 | break;
|
---|
740 | biasSat->NumberOfCodeBiases += 1;
|
---|
741 | biasSat->Biases[ii].Type = CODETYPEGLONASS_L1_P;
|
---|
742 | biasSat->Biases[ii].Bias = it.value();
|
---|
743 | }
|
---|
744 | else if (it.key() == "2C") {
|
---|
745 | int ii = biasSat->NumberOfCodeBiases;
|
---|
746 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
747 | break;
|
---|
748 | biasSat->NumberOfCodeBiases += 1;
|
---|
749 | biasSat->Biases[ii].Type = CODETYPEGLONASS_L2_CA;
|
---|
750 | biasSat->Biases[ii].Bias = it.value();
|
---|
751 | }
|
---|
752 | else if (it.key() == "2P") {
|
---|
753 | int ii = biasSat->NumberOfCodeBiases;
|
---|
754 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
755 | break;
|
---|
756 | biasSat->NumberOfCodeBiases += 1;
|
---|
757 | biasSat->Biases[ii].Type = CODETYPEGLONASS_L2_P;
|
---|
758 | biasSat->Biases[ii].Bias = it.value();
|
---|
759 | }
|
---|
760 | }
|
---|
761 | }
|
---|
762 | else if (prn.system() == 'E') {
|
---|
763 | QMapIterator<QString, double> it(codeBiases);
|
---|
764 | while (it.hasNext()) {
|
---|
765 | it.next();
|
---|
766 | if (it.key() == "1A") {
|
---|
767 | int ii = biasSat->NumberOfCodeBiases;
|
---|
768 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
769 | break;
|
---|
770 | biasSat->NumberOfCodeBiases += 1;
|
---|
771 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E1_A;
|
---|
772 | biasSat->Biases[ii].Bias = it.value();
|
---|
773 | }
|
---|
774 | else if (it.key() == "1B") {
|
---|
775 | int ii = biasSat->NumberOfCodeBiases;
|
---|
776 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
777 | break;
|
---|
778 | biasSat->NumberOfCodeBiases += 1;
|
---|
779 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E1_B;
|
---|
780 | biasSat->Biases[ii].Bias = it.value();
|
---|
781 | }
|
---|
782 | else if (it.key() == "1C") {
|
---|
783 | int ii = biasSat->NumberOfCodeBiases;
|
---|
784 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
785 | break;
|
---|
786 | biasSat->NumberOfCodeBiases += 1;
|
---|
787 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E1_C;
|
---|
788 | biasSat->Biases[ii].Bias = it.value();
|
---|
789 | }
|
---|
790 | else if (it.key() == "1X") {
|
---|
791 | int ii = biasSat->NumberOfCodeBiases;
|
---|
792 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
793 | break;
|
---|
794 | biasSat->NumberOfCodeBiases += 1;
|
---|
795 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E1_BC;
|
---|
796 | biasSat->Biases[ii].Bias = it.value();
|
---|
797 | }
|
---|
798 | else if (it.key() == "1Z") {
|
---|
799 | int ii = biasSat->NumberOfCodeBiases;
|
---|
800 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
801 | break;
|
---|
802 | biasSat->NumberOfCodeBiases += 1;
|
---|
803 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E1_ABC;
|
---|
804 | biasSat->Biases[ii].Bias = it.value();
|
---|
805 | }
|
---|
806 | else if (it.key() == "5I") {
|
---|
807 | int ii = biasSat->NumberOfCodeBiases;
|
---|
808 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
809 | break;
|
---|
810 | biasSat->NumberOfCodeBiases += 1;
|
---|
811 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_I;
|
---|
812 | biasSat->Biases[ii].Bias = it.value();
|
---|
813 | }
|
---|
814 | else if (it.key() == "5Q") {
|
---|
815 | int ii = biasSat->NumberOfCodeBiases;
|
---|
816 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
817 | break;
|
---|
818 | biasSat->NumberOfCodeBiases += 1;
|
---|
819 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_Q;
|
---|
820 | biasSat->Biases[ii].Bias = it.value();
|
---|
821 | }
|
---|
822 | else if (it.key() == "5X") {
|
---|
823 | int ii = biasSat->NumberOfCodeBiases;
|
---|
824 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
825 | break;
|
---|
826 | biasSat->NumberOfCodeBiases += 1;
|
---|
827 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_IQ;
|
---|
828 | biasSat->Biases[ii].Bias = it.value();
|
---|
829 | }
|
---|
830 | else if (it.key() == "7I") {
|
---|
831 | int ii = biasSat->NumberOfCodeBiases;
|
---|
832 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
833 | break;
|
---|
834 | biasSat->NumberOfCodeBiases += 1;
|
---|
835 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_I;
|
---|
836 | biasSat->Biases[ii].Bias = it.value();
|
---|
837 | }
|
---|
838 | else if (it.key() == "7Q") {
|
---|
839 | int ii = biasSat->NumberOfCodeBiases;
|
---|
840 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
841 | break;
|
---|
842 | biasSat->NumberOfCodeBiases += 1;
|
---|
843 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_Q;
|
---|
844 | biasSat->Biases[ii].Bias = it.value();
|
---|
845 | }
|
---|
846 | else if (it.key() == "7X") {
|
---|
847 | int ii = biasSat->NumberOfCodeBiases;
|
---|
848 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
849 | break;
|
---|
850 | biasSat->NumberOfCodeBiases += 1;
|
---|
851 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_IQ;
|
---|
852 | biasSat->Biases[ii].Bias = it.value();
|
---|
853 | }
|
---|
854 | else if (it.key() == "8I") {
|
---|
855 | int ii = biasSat->NumberOfCodeBiases;
|
---|
856 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
857 | break;
|
---|
858 | biasSat->NumberOfCodeBiases += 1;
|
---|
859 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5_I;
|
---|
860 | biasSat->Biases[ii].Bias = it.value();
|
---|
861 | }
|
---|
862 | else if (it.key() == "8Q") {
|
---|
863 | int ii = biasSat->NumberOfCodeBiases;
|
---|
864 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
865 | break;
|
---|
866 | biasSat->NumberOfCodeBiases += 1;
|
---|
867 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5_Q;
|
---|
868 | biasSat->Biases[ii].Bias = it.value();
|
---|
869 | }
|
---|
870 | else if (it.key() == "8X") {
|
---|
871 | int ii = biasSat->NumberOfCodeBiases;
|
---|
872 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
873 | break;
|
---|
874 | biasSat->NumberOfCodeBiases += 1;
|
---|
875 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E5_IQ;
|
---|
876 | biasSat->Biases[ii].Bias = it.value();
|
---|
877 | }
|
---|
878 | else if (it.key() == "6A") {
|
---|
879 | int ii = biasSat->NumberOfCodeBiases;
|
---|
880 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
881 | break;
|
---|
882 | biasSat->NumberOfCodeBiases += 1;
|
---|
883 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E6_A;
|
---|
884 | biasSat->Biases[ii].Bias = it.value();
|
---|
885 | }
|
---|
886 | else if (it.key() == "6B") {
|
---|
887 | int ii = biasSat->NumberOfCodeBiases;
|
---|
888 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
889 | break;
|
---|
890 | biasSat->NumberOfCodeBiases += 1;
|
---|
891 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E6_B;
|
---|
892 | biasSat->Biases[ii].Bias = it.value();
|
---|
893 | }
|
---|
894 | else if (it.key() == "6C") {
|
---|
895 | int ii = biasSat->NumberOfCodeBiases;
|
---|
896 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
897 | break;
|
---|
898 | biasSat->NumberOfCodeBiases += 1;
|
---|
899 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E6_C;
|
---|
900 | biasSat->Biases[ii].Bias = it.value();
|
---|
901 | }
|
---|
902 | else if (it.key() == "6X") {
|
---|
903 | int ii = biasSat->NumberOfCodeBiases;
|
---|
904 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
905 | break;
|
---|
906 | biasSat->NumberOfCodeBiases += 1;
|
---|
907 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E6_BC;
|
---|
908 | biasSat->Biases[ii].Bias = it.value();
|
---|
909 | }
|
---|
910 | else if (it.key() == "6Z") {
|
---|
911 | int ii = biasSat->NumberOfCodeBiases;
|
---|
912 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
913 | break;
|
---|
914 | biasSat->NumberOfCodeBiases += 1;
|
---|
915 | biasSat->Biases[ii].Type = CODETYPEGALILEO_E6_ABC;
|
---|
916 | biasSat->Biases[ii].Bias = it.value();
|
---|
917 | }
|
---|
918 | }
|
---|
919 | }
|
---|
920 | else if (prn.system() == 'J') {
|
---|
921 | QMapIterator<QString, double> it(codeBiases);
|
---|
922 | while (it.hasNext()) {
|
---|
923 | it.next();
|
---|
924 | if (it.key() == "1C") {
|
---|
925 | int ii = biasSat->NumberOfCodeBiases;
|
---|
926 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
927 | break;
|
---|
928 | biasSat->NumberOfCodeBiases += 1;
|
---|
929 | biasSat->Biases[ii].Type = CODETYPEQZSS_L1_CA;
|
---|
930 | biasSat->Biases[ii].Bias = it.value();
|
---|
931 | }
|
---|
932 | else if (it.key() == "1S") {
|
---|
933 | int ii = biasSat->NumberOfCodeBiases;
|
---|
934 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
935 | break;
|
---|
936 | biasSat->NumberOfCodeBiases += 1;
|
---|
937 | biasSat->Biases[ii].Type = CODETYPEQZSS_L1C_D;
|
---|
938 | biasSat->Biases[ii].Bias = it.value();
|
---|
939 | }
|
---|
940 | else if (it.key() == "1L") {
|
---|
941 | int ii = biasSat->NumberOfCodeBiases;
|
---|
942 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
943 | break;
|
---|
944 | biasSat->NumberOfCodeBiases += 1;
|
---|
945 | biasSat->Biases[ii].Type = CODETYPEQZSS_L1C_P;
|
---|
946 | biasSat->Biases[ii].Bias = it.value();
|
---|
947 | }
|
---|
948 | else if (it.key() == "1X") {
|
---|
949 | int ii = biasSat->NumberOfCodeBiases;
|
---|
950 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
951 | break;
|
---|
952 | biasSat->NumberOfCodeBiases += 1;
|
---|
953 | biasSat->Biases[ii].Type = CODETYPEQZSS_L1C_DP;
|
---|
954 | biasSat->Biases[ii].Bias = it.value();
|
---|
955 | }
|
---|
956 | else if (it.key() == "2S") {
|
---|
957 | int ii = biasSat->NumberOfCodeBiases;
|
---|
958 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
959 | break;
|
---|
960 | biasSat->NumberOfCodeBiases += 1;
|
---|
961 | biasSat->Biases[ii].Type = CODETYPEQZSS_L2C_M;
|
---|
962 | biasSat->Biases[ii].Bias = it.value();
|
---|
963 | }
|
---|
964 | else if (it.key() == "2L") {
|
---|
965 | int ii = biasSat->NumberOfCodeBiases;
|
---|
966 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
967 | break;
|
---|
968 | biasSat->NumberOfCodeBiases += 1;
|
---|
969 | biasSat->Biases[ii].Type = CODETYPEQZSS_L2C_L;
|
---|
970 | biasSat->Biases[ii].Bias = it.value();
|
---|
971 | }
|
---|
972 | else if (it.key() == "2X") {
|
---|
973 | int ii = biasSat->NumberOfCodeBiases;
|
---|
974 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
975 | break;
|
---|
976 | biasSat->NumberOfCodeBiases += 1;
|
---|
977 | biasSat->Biases[ii].Type = CODETYPEQZSS_L2C_ML;
|
---|
978 | biasSat->Biases[ii].Bias = it.value();
|
---|
979 | }
|
---|
980 | else if (it.key() == "5I") {
|
---|
981 | int ii = biasSat->NumberOfCodeBiases;
|
---|
982 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
983 | break;
|
---|
984 | biasSat->NumberOfCodeBiases += 1;
|
---|
985 | biasSat->Biases[ii].Type = CODETYPEQZSS_L5_I;
|
---|
986 | biasSat->Biases[ii].Bias = it.value();
|
---|
987 | }
|
---|
988 | else if (it.key() == "5Q") {
|
---|
989 | int ii = biasSat->NumberOfCodeBiases;
|
---|
990 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
991 | break;
|
---|
992 | biasSat->NumberOfCodeBiases += 1;
|
---|
993 | biasSat->Biases[ii].Type = CODETYPEQZSS_L5_Q;
|
---|
994 | biasSat->Biases[ii].Bias = it.value();
|
---|
995 | }
|
---|
996 | else if (it.key() == "5X") {
|
---|
997 | int ii = biasSat->NumberOfCodeBiases;
|
---|
998 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
999 | break;
|
---|
1000 | biasSat->NumberOfCodeBiases += 1;
|
---|
1001 | biasSat->Biases[ii].Type = CODETYPEQZSS_L5_IQ;
|
---|
1002 | biasSat->Biases[ii].Bias = it.value();
|
---|
1003 | }
|
---|
1004 | else if (it.key() == "6S") {
|
---|
1005 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1006 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1007 | break;
|
---|
1008 | biasSat->NumberOfCodeBiases += 1;
|
---|
1009 | biasSat->Biases[ii].Type = CODETYPEQZSS_LEX_S;
|
---|
1010 | biasSat->Biases[ii].Bias = it.value();
|
---|
1011 | }
|
---|
1012 | else if (it.key() == "6L") {
|
---|
1013 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1014 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1015 | break;
|
---|
1016 | biasSat->NumberOfCodeBiases += 1;
|
---|
1017 | biasSat->Biases[ii].Type = CODETYPEQZSS_LEX_L;
|
---|
1018 | biasSat->Biases[ii].Bias = it.value();
|
---|
1019 | }
|
---|
1020 | else if (it.key() == "6X") {
|
---|
1021 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1022 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1023 | break;
|
---|
1024 | biasSat->NumberOfCodeBiases += 1;
|
---|
1025 | biasSat->Biases[ii].Type = CODETYPEQZSS_LEX_SL;
|
---|
1026 | biasSat->Biases[ii].Bias = it.value();
|
---|
1027 | }
|
---|
1028 | }
|
---|
1029 | }
|
---|
1030 | else if (prn.system() == 'S') {
|
---|
1031 | QMapIterator<QString, double> it(codeBiases);
|
---|
1032 | while (it.hasNext()) {
|
---|
1033 | it.next();
|
---|
1034 | if (it.key() == "1C") {
|
---|
1035 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1036 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1037 | break;
|
---|
1038 | biasSat->NumberOfCodeBiases += 1;
|
---|
1039 | biasSat->Biases[ii].Type = CODETYPE_SBAS_L1_CA;
|
---|
1040 | biasSat->Biases[ii].Bias = it.value();
|
---|
1041 | }
|
---|
1042 | else if (it.key() == "5I") {
|
---|
1043 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1044 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1045 | break;
|
---|
1046 | biasSat->NumberOfCodeBiases += 1;
|
---|
1047 | biasSat->Biases[ii].Type = CODETYPE_SBAS_L5_I;
|
---|
1048 | biasSat->Biases[ii].Bias = it.value();
|
---|
1049 | }
|
---|
1050 | else if (it.key() == "5Q") {
|
---|
1051 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1052 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1053 | break;
|
---|
1054 | biasSat->NumberOfCodeBiases += 1;
|
---|
1055 | biasSat->Biases[ii].Type = CODETYPE_SBAS_L5_Q;
|
---|
1056 | biasSat->Biases[ii].Bias = it.value();
|
---|
1057 | }
|
---|
1058 | else if (it.key() == "5X") {
|
---|
1059 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1060 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1061 | break;
|
---|
1062 | biasSat->NumberOfCodeBiases += 1;
|
---|
1063 | biasSat->Biases[ii].Type = CODETYPE_SBAS_L5_IQ;
|
---|
1064 | biasSat->Biases[ii].Bias = it.value();
|
---|
1065 | }
|
---|
1066 | }
|
---|
1067 | }
|
---|
1068 | else if (prn.system() == 'C') {
|
---|
1069 | QMapIterator<QString, double> it(codeBiases);
|
---|
1070 | while (it.hasNext()) {
|
---|
1071 | it.next();
|
---|
1072 | if (it.key() == "2I") {
|
---|
1073 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1074 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1075 | break;
|
---|
1076 | biasSat->NumberOfCodeBiases += 1;
|
---|
1077 | biasSat->Biases[ii].Type = CODETYPE_BDS_B1_I;
|
---|
1078 | biasSat->Biases[ii].Bias = it.value();
|
---|
1079 | }
|
---|
1080 | else if (it.key() == "2Q") {
|
---|
1081 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1082 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1083 | break;
|
---|
1084 | biasSat->NumberOfCodeBiases += 1;
|
---|
1085 | biasSat->Biases[ii].Type = CODETYPE_BDS_B1_Q;
|
---|
1086 | biasSat->Biases[ii].Bias = it.value();
|
---|
1087 | }
|
---|
1088 | else if (it.key() == "2X") {
|
---|
1089 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1090 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1091 | break;
|
---|
1092 | biasSat->NumberOfCodeBiases += 1;
|
---|
1093 | biasSat->Biases[ii].Type = CODETYPE_BDS_B1_IQ;
|
---|
1094 | biasSat->Biases[ii].Bias = it.value();
|
---|
1095 | }
|
---|
1096 | else if (it.key() == "6I") {
|
---|
1097 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1098 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1099 | break;
|
---|
1100 | biasSat->NumberOfCodeBiases += 1;
|
---|
1101 | biasSat->Biases[ii].Type = CODETYPE_BDS_B3_I;
|
---|
1102 | biasSat->Biases[ii].Bias = it.value();
|
---|
1103 | }
|
---|
1104 | else if (it.key() == "6Q") {
|
---|
1105 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1106 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1107 | break;
|
---|
1108 | biasSat->NumberOfCodeBiases += 1;
|
---|
1109 | biasSat->Biases[ii].Type = CODETYPE_BDS_B3_Q;
|
---|
1110 | biasSat->Biases[ii].Bias = it.value();
|
---|
1111 | }
|
---|
1112 | else if (it.key() == "6X") {
|
---|
1113 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1114 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1115 | break;
|
---|
1116 | biasSat->NumberOfCodeBiases += 1;
|
---|
1117 | biasSat->Biases[ii].Type = CODETYPE_BDS_B3_IQ;
|
---|
1118 | biasSat->Biases[ii].Bias = it.value();
|
---|
1119 | }
|
---|
1120 | else if (it.key() == "7I") {
|
---|
1121 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1122 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1123 | break;
|
---|
1124 | biasSat->NumberOfCodeBiases += 1;
|
---|
1125 | biasSat->Biases[ii].Type = CODETYPE_BDS_B2_I;
|
---|
1126 | biasSat->Biases[ii].Bias = it.value();
|
---|
1127 | }
|
---|
1128 | else if (it.key() == "7Q") {
|
---|
1129 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1130 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1131 | break;
|
---|
1132 | biasSat->NumberOfCodeBiases += 1;
|
---|
1133 | biasSat->Biases[ii].Type = CODETYPE_BDS_B2_Q;
|
---|
1134 | biasSat->Biases[ii].Bias = it.value();
|
---|
1135 | }
|
---|
1136 | else if (it.key() == "7X") {
|
---|
1137 | int ii = biasSat->NumberOfCodeBiases;
|
---|
1138 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1139 | break;
|
---|
1140 | biasSat->NumberOfCodeBiases += 1;
|
---|
1141 | biasSat->Biases[ii].Type = CODETYPE_BDS_B2_IQ;
|
---|
1142 | biasSat->Biases[ii].Bias = it.value();
|
---|
1143 | }
|
---|
1144 | }
|
---|
1145 | }
|
---|
1146 | }
|
---|
1147 | // Phase Biases
|
---|
1148 | // ------------
|
---|
1149 | struct PhaseBias::PhaseBiasSat* phasebiasSat = 0;
|
---|
1150 | if (!phaseBiasList.isEmpty()) {
|
---|
1151 | if (prn.system() == 'G') {
|
---|
1152 | phasebiasSat = phasebias.Sat
|
---|
1153 | + phasebias.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
1154 | ++phasebias.NumberOfSat[CLOCKORBIT_SATGPS];
|
---|
1155 | }
|
---|
1156 | else if (prn.system() == 'R') {
|
---|
1157 | phasebiasSat = phasebias.Sat + CLOCKORBIT_NUMGPS
|
---|
1158 | + phasebias.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
1159 | ++phasebias.NumberOfSat[CLOCKORBIT_SATGLONASS];
|
---|
1160 | }
|
---|
1161 | else if (prn.system() == 'E') {
|
---|
1162 | phasebiasSat = phasebias.Sat + CLOCKORBIT_NUMGPS
|
---|
1163 | + CLOCKORBIT_NUMGLONASS
|
---|
1164 | + phasebias.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
1165 | ++phasebias.NumberOfSat[CLOCKORBIT_SATGALILEO];
|
---|
1166 | }
|
---|
1167 | else if (prn.system() == 'J') {
|
---|
1168 | phasebiasSat = phasebias.Sat + CLOCKORBIT_NUMGPS
|
---|
1169 | + CLOCKORBIT_NUMGLONASS + CLOCKORBIT_NUMGALILEO
|
---|
1170 | + phasebias.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
1171 | ++phasebias.NumberOfSat[CLOCKORBIT_SATQZSS];
|
---|
1172 | }
|
---|
1173 | else if (prn.system() == 'S') {
|
---|
1174 | phasebiasSat = phasebias.Sat + CLOCKORBIT_NUMGPS
|
---|
1175 | + CLOCKORBIT_NUMGLONASS + CLOCKORBIT_NUMGALILEO
|
---|
1176 | + CLOCKORBIT_NUMQZSS + phasebias.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
1177 | ++phasebias.NumberOfSat[CLOCKORBIT_SATSBAS];
|
---|
1178 | }
|
---|
1179 | else if (prn.system() == 'C') {
|
---|
1180 | phasebiasSat = phasebias.Sat + CLOCKORBIT_NUMGPS
|
---|
1181 | + CLOCKORBIT_NUMGLONASS + CLOCKORBIT_NUMGALILEO
|
---|
1182 | + CLOCKORBIT_NUMQZSS + CLOCKORBIT_NUMSBAS
|
---|
1183 | + phasebias.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
1184 | ++phasebias.NumberOfSat[CLOCKORBIT_SATBDS];
|
---|
1185 | }
|
---|
1186 | }
|
---|
1187 |
|
---|
1188 | if (phasebiasSat) {
|
---|
1189 | phasebias.DispersiveBiasConsistencyIndicator = dispersiveBiasConsistenyIndicator;
|
---|
1190 | phasebias.MWConsistencyIndicator = mwConsistencyIndicator;
|
---|
1191 | phasebiasSat->ID = prn.number();
|
---|
1192 | phasebiasSat->NumberOfPhaseBiases = 0;
|
---|
1193 | phasebiasSat->YawAngle = pbSat.yawAngle;
|
---|
1194 | phasebiasSat->YawRate = pbSat.yawRate;
|
---|
1195 | if (prn.system() == 'G') {
|
---|
1196 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1197 | while (it.hasNext()) {
|
---|
1198 | const phaseBiasSignal &pbSig = it.next();
|
---|
1199 | if (pbSig.type == "1C") {
|
---|
1200 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1201 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1202 | break;
|
---|
1203 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1204 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1_CA;
|
---|
1205 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1206 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1207 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1208 | pbSig.wlIndicator;
|
---|
1209 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1210 | pbSig.discontinuityCounter;
|
---|
1211 | }
|
---|
1212 | else if (pbSig.type == "1S") {
|
---|
1213 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1214 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1215 | break;
|
---|
1216 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1217 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1C_D;
|
---|
1218 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1219 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1220 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1221 | pbSig.wlIndicator;
|
---|
1222 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1223 | pbSig.discontinuityCounter;
|
---|
1224 | }
|
---|
1225 | else if (pbSig.type == "1L") {
|
---|
1226 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1227 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1228 | break;
|
---|
1229 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1230 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1C_P;
|
---|
1231 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1232 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1233 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1234 | pbSig.wlIndicator;
|
---|
1235 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1236 | pbSig.discontinuityCounter;
|
---|
1237 | }
|
---|
1238 | else if (pbSig.type == "1X") {
|
---|
1239 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1240 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1241 | break;
|
---|
1242 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1243 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1C_P;
|
---|
1244 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1245 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1246 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1247 | pbSig.wlIndicator;
|
---|
1248 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1249 | pbSig.discontinuityCounter;
|
---|
1250 | }
|
---|
1251 | else if (pbSig.type == "1P") {
|
---|
1252 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1253 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1254 | break;
|
---|
1255 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1256 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1_P;
|
---|
1257 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1258 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1259 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1260 | pbSig.wlIndicator;
|
---|
1261 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1262 | pbSig.discontinuityCounter;
|
---|
1263 | }
|
---|
1264 | else if (pbSig.type == "1W") {
|
---|
1265 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1266 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1267 | break;
|
---|
1268 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1269 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L1_Z;
|
---|
1270 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1271 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1272 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1273 | pbSig.wlIndicator;
|
---|
1274 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1275 | pbSig.discontinuityCounter;
|
---|
1276 | }
|
---|
1277 | else if (pbSig.type == "2C") {
|
---|
1278 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1279 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1280 | break;
|
---|
1281 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1282 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_CA;
|
---|
1283 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1284 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1285 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1286 | pbSig.wlIndicator;
|
---|
1287 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1288 | pbSig.discontinuityCounter;
|
---|
1289 | }
|
---|
1290 | else if (pbSig.type == "2D") {
|
---|
1291 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1292 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1293 | break;
|
---|
1294 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1295 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_SEMI_CODELESS;
|
---|
1296 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1297 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1298 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1299 | pbSig.wlIndicator;
|
---|
1300 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1301 | pbSig.discontinuityCounter;
|
---|
1302 | }
|
---|
1303 | else if (pbSig.type == "2S") {
|
---|
1304 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1305 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1306 | break;
|
---|
1307 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1308 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_CM;
|
---|
1309 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1310 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1311 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1312 | pbSig.wlIndicator;
|
---|
1313 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1314 | pbSig.discontinuityCounter;
|
---|
1315 | }
|
---|
1316 | else if (pbSig.type == "2L") {
|
---|
1317 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1318 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1319 | break;
|
---|
1320 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1321 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_CL;
|
---|
1322 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1323 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1324 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1325 | pbSig.wlIndicator;
|
---|
1326 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1327 | pbSig.discontinuityCounter;
|
---|
1328 | }
|
---|
1329 | else if (pbSig.type == "2X") {
|
---|
1330 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1331 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1332 | break;
|
---|
1333 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1334 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_CML;
|
---|
1335 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1336 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1337 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1338 | pbSig.wlIndicator;
|
---|
1339 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1340 | pbSig.discontinuityCounter;
|
---|
1341 | }
|
---|
1342 | else if (pbSig.type == "2P") {
|
---|
1343 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1344 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1345 | break;
|
---|
1346 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1347 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_P;
|
---|
1348 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1349 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1350 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1351 | pbSig.wlIndicator;
|
---|
1352 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1353 | pbSig.discontinuityCounter;
|
---|
1354 | }
|
---|
1355 | else if (pbSig.type == "2W") {
|
---|
1356 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1357 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1358 | break;
|
---|
1359 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1360 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L2_Z;
|
---|
1361 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1362 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1363 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1364 | pbSig.wlIndicator;
|
---|
1365 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1366 | pbSig.discontinuityCounter;
|
---|
1367 | }
|
---|
1368 | else if (pbSig.type == "5I") {
|
---|
1369 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1370 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1371 | break;
|
---|
1372 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1373 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L5_I;
|
---|
1374 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1375 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1376 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1377 | pbSig.wlIndicator;
|
---|
1378 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1379 | pbSig.discontinuityCounter;
|
---|
1380 | }
|
---|
1381 | else if (pbSig.type == "5Q") {
|
---|
1382 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1383 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1384 | break;
|
---|
1385 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1386 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L5_Q;
|
---|
1387 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1388 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1389 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1390 | pbSig.wlIndicator;
|
---|
1391 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1392 | pbSig.discontinuityCounter;
|
---|
1393 | }
|
---|
1394 | else if (pbSig.type == "5X") {
|
---|
1395 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1396 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1397 | break;
|
---|
1398 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1399 | phasebiasSat->Biases[ii].Type = CODETYPEGPS_L5_IQ;
|
---|
1400 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1401 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1402 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1403 | pbSig.wlIndicator;
|
---|
1404 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1405 | pbSig.discontinuityCounter;
|
---|
1406 | }
|
---|
1407 | }
|
---|
1408 | }
|
---|
1409 | if (prn.system() == 'R') {
|
---|
1410 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1411 | while (it.hasNext()) {
|
---|
1412 | const phaseBiasSignal &pbSig = it.next();
|
---|
1413 | if (pbSig.type == "1C") {
|
---|
1414 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1415 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1416 | break;
|
---|
1417 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1418 | phasebiasSat->Biases[ii].Type = CODETYPEGLONASS_L1_CA;
|
---|
1419 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1420 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1421 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1422 | pbSig.wlIndicator;
|
---|
1423 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1424 | pbSig.discontinuityCounter;
|
---|
1425 | }
|
---|
1426 | else if (pbSig.type == "1P") {
|
---|
1427 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1428 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1429 | break;
|
---|
1430 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1431 | phasebiasSat->Biases[ii].Type = CODETYPEGLONASS_L1_P;
|
---|
1432 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1433 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1434 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1435 | pbSig.wlIndicator;
|
---|
1436 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1437 | pbSig.discontinuityCounter;
|
---|
1438 | }
|
---|
1439 | else if (pbSig.type == "2C") {
|
---|
1440 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1441 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1442 | break;
|
---|
1443 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1444 | phasebiasSat->Biases[ii].Type = CODETYPEGLONASS_L2_CA;
|
---|
1445 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1446 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1447 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1448 | pbSig.wlIndicator;
|
---|
1449 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1450 | pbSig.discontinuityCounter;
|
---|
1451 | }
|
---|
1452 | else if (pbSig.type == "2P") {
|
---|
1453 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1454 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1455 | break;
|
---|
1456 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1457 | phasebiasSat->Biases[ii].Type = CODETYPEGLONASS_L2_P;
|
---|
1458 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1459 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1460 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1461 | pbSig.wlIndicator;
|
---|
1462 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1463 | pbSig.discontinuityCounter;
|
---|
1464 | }
|
---|
1465 | }
|
---|
1466 | }
|
---|
1467 | if (prn.system() == 'E') {
|
---|
1468 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1469 | while (it.hasNext()) {
|
---|
1470 | const phaseBiasSignal &pbSig = it.next();
|
---|
1471 | if (pbSig.type == "1A") {
|
---|
1472 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1473 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1474 | break;
|
---|
1475 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1476 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E1_A;
|
---|
1477 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1478 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1479 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1480 | pbSig.wlIndicator;
|
---|
1481 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1482 | pbSig.discontinuityCounter;
|
---|
1483 | }
|
---|
1484 | else if (pbSig.type == "1B") {
|
---|
1485 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1486 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1487 | break;
|
---|
1488 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1489 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E1_B;
|
---|
1490 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1491 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1492 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1493 | pbSig.wlIndicator;
|
---|
1494 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1495 | pbSig.discontinuityCounter;
|
---|
1496 | }
|
---|
1497 | else if (pbSig.type == "1C") {
|
---|
1498 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1499 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1500 | break;
|
---|
1501 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1502 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E1_C;
|
---|
1503 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1504 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1505 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1506 | pbSig.wlIndicator;
|
---|
1507 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1508 | pbSig.discontinuityCounter;
|
---|
1509 | }
|
---|
1510 | else if (pbSig.type == "1X") {
|
---|
1511 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1512 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1513 | break;
|
---|
1514 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1515 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E1_BC;
|
---|
1516 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1517 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1518 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1519 | pbSig.wlIndicator;
|
---|
1520 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1521 | pbSig.discontinuityCounter;
|
---|
1522 | }
|
---|
1523 | else if (pbSig.type == "1Z") {
|
---|
1524 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1525 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1526 | break;
|
---|
1527 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1528 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E1_ABC;
|
---|
1529 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1530 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1531 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1532 | pbSig.wlIndicator;
|
---|
1533 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1534 | pbSig.discontinuityCounter;
|
---|
1535 | }
|
---|
1536 | else if (pbSig.type == "5I") {
|
---|
1537 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1538 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1539 | break;
|
---|
1540 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1541 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_I;
|
---|
1542 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1543 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1544 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1545 | pbSig.wlIndicator;
|
---|
1546 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1547 | pbSig.discontinuityCounter;
|
---|
1548 | }
|
---|
1549 | else if (pbSig.type == "5Q") {
|
---|
1550 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1551 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1552 | break;
|
---|
1553 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1554 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_Q;
|
---|
1555 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1556 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1557 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1558 | pbSig.wlIndicator;
|
---|
1559 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1560 | pbSig.discontinuityCounter;
|
---|
1561 | }
|
---|
1562 | else if (pbSig.type == "5X") {
|
---|
1563 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1564 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1565 | break;
|
---|
1566 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1567 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5A_IQ;
|
---|
1568 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1569 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1570 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1571 | pbSig.wlIndicator;
|
---|
1572 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1573 | pbSig.discontinuityCounter;
|
---|
1574 | }
|
---|
1575 | else if (pbSig.type == "7I") {
|
---|
1576 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1577 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1578 | break;
|
---|
1579 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1580 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_I;
|
---|
1581 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1582 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1583 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1584 | pbSig.wlIndicator;
|
---|
1585 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1586 | pbSig.discontinuityCounter;
|
---|
1587 | }
|
---|
1588 | else if (pbSig.type == "7Q") {
|
---|
1589 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1590 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1591 | break;
|
---|
1592 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1593 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_Q;
|
---|
1594 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1595 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1596 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1597 | pbSig.wlIndicator;
|
---|
1598 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1599 | pbSig.discontinuityCounter;
|
---|
1600 | }
|
---|
1601 | else if (pbSig.type == "7X") {
|
---|
1602 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1603 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1604 | break;
|
---|
1605 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1606 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5B_IQ;
|
---|
1607 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1608 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1609 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1610 | pbSig.wlIndicator;
|
---|
1611 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1612 | pbSig.discontinuityCounter;
|
---|
1613 | }
|
---|
1614 | else if (pbSig.type == "8I") {
|
---|
1615 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1616 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1617 | break;
|
---|
1618 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1619 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5_I;
|
---|
1620 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1621 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1622 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1623 | pbSig.wlIndicator;
|
---|
1624 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1625 | pbSig.discontinuityCounter;
|
---|
1626 | }
|
---|
1627 | else if (pbSig.type == "8Q") {
|
---|
1628 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1629 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1630 | break;
|
---|
1631 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1632 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5_Q;
|
---|
1633 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1634 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1635 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1636 | pbSig.wlIndicator;
|
---|
1637 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1638 | pbSig.discontinuityCounter;
|
---|
1639 | }
|
---|
1640 | else if (pbSig.type == "8X") {
|
---|
1641 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1642 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1643 | break;
|
---|
1644 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1645 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E5_IQ;
|
---|
1646 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1647 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1648 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1649 | pbSig.wlIndicator;
|
---|
1650 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1651 | pbSig.discontinuityCounter;
|
---|
1652 | }
|
---|
1653 | else if (pbSig.type == "6A") {
|
---|
1654 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1655 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1656 | break;
|
---|
1657 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1658 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E6_A;
|
---|
1659 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1660 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1661 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1662 | pbSig.wlIndicator;
|
---|
1663 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1664 | pbSig.discontinuityCounter;
|
---|
1665 | }
|
---|
1666 | else if (pbSig.type == "6B") {
|
---|
1667 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1668 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1669 | break;
|
---|
1670 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1671 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E6_B;
|
---|
1672 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1673 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1674 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1675 | pbSig.wlIndicator;
|
---|
1676 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1677 | pbSig.discontinuityCounter;
|
---|
1678 | }
|
---|
1679 | else if (pbSig.type == "6C") {
|
---|
1680 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1681 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1682 | break;
|
---|
1683 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1684 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E6_C;
|
---|
1685 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1686 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1687 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1688 | pbSig.wlIndicator;
|
---|
1689 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1690 | pbSig.discontinuityCounter;
|
---|
1691 | }
|
---|
1692 | else if (pbSig.type == "6X") {
|
---|
1693 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1694 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1695 | break;
|
---|
1696 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1697 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E6_BC;
|
---|
1698 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1699 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1700 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1701 | pbSig.wlIndicator;
|
---|
1702 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1703 | pbSig.discontinuityCounter;
|
---|
1704 | }
|
---|
1705 | else if (pbSig.type == "6Z") {
|
---|
1706 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1707 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1708 | break;
|
---|
1709 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1710 | phasebiasSat->Biases[ii].Type = CODETYPEGALILEO_E6_ABC;
|
---|
1711 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1712 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1713 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1714 | pbSig.wlIndicator;
|
---|
1715 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1716 | pbSig.discontinuityCounter;
|
---|
1717 | }
|
---|
1718 | }
|
---|
1719 | }
|
---|
1720 | if (prn.system() == 'J') {
|
---|
1721 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1722 | while (it.hasNext()) {
|
---|
1723 | const phaseBiasSignal &pbSig = it.next();
|
---|
1724 | if (pbSig.type == "1C") {
|
---|
1725 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1726 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1727 | break;
|
---|
1728 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1729 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L1_CA;
|
---|
1730 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1731 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1732 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1733 | pbSig.wlIndicator;
|
---|
1734 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1735 | pbSig.discontinuityCounter;
|
---|
1736 | }
|
---|
1737 | else if (pbSig.type == "1S") {
|
---|
1738 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1739 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1740 | break;
|
---|
1741 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1742 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L1C_D;
|
---|
1743 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1744 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1745 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1746 | pbSig.wlIndicator;
|
---|
1747 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1748 | pbSig.discontinuityCounter;
|
---|
1749 | }
|
---|
1750 | else if (pbSig.type == "1L") {
|
---|
1751 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1752 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1753 | break;
|
---|
1754 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1755 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L1C_P;
|
---|
1756 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1757 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1758 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1759 | pbSig.wlIndicator;
|
---|
1760 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1761 | pbSig.discontinuityCounter;
|
---|
1762 | }
|
---|
1763 | else if (pbSig.type == "1X") {
|
---|
1764 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1765 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1766 | break;
|
---|
1767 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1768 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L1C_DP;
|
---|
1769 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1770 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1771 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1772 | pbSig.wlIndicator;
|
---|
1773 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1774 | pbSig.discontinuityCounter;
|
---|
1775 | }
|
---|
1776 | else if (pbSig.type == "2S") {
|
---|
1777 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1778 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1779 | break;
|
---|
1780 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1781 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L2C_M;
|
---|
1782 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1783 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1784 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1785 | pbSig.wlIndicator;
|
---|
1786 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1787 | pbSig.discontinuityCounter;
|
---|
1788 | }
|
---|
1789 | else if (pbSig.type == "2L") {
|
---|
1790 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1791 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1792 | break;
|
---|
1793 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1794 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L2C_L;
|
---|
1795 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1796 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1797 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1798 | pbSig.wlIndicator;
|
---|
1799 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1800 | pbSig.discontinuityCounter;
|
---|
1801 | }
|
---|
1802 | else if (pbSig.type == "2X") {
|
---|
1803 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1804 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1805 | break;
|
---|
1806 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1807 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L2C_ML;
|
---|
1808 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1809 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1810 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1811 | pbSig.wlIndicator;
|
---|
1812 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1813 | pbSig.discontinuityCounter;
|
---|
1814 | }
|
---|
1815 | else if (pbSig.type == "5I") {
|
---|
1816 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1817 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1818 | break;
|
---|
1819 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1820 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L5_I;
|
---|
1821 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1822 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1823 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1824 | pbSig.wlIndicator;
|
---|
1825 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1826 | pbSig.discontinuityCounter;
|
---|
1827 | }
|
---|
1828 | else if (pbSig.type == "5Q") {
|
---|
1829 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1830 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1831 | break;
|
---|
1832 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1833 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L5_Q;
|
---|
1834 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1835 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1836 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1837 | pbSig.wlIndicator;
|
---|
1838 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1839 | pbSig.discontinuityCounter;
|
---|
1840 | }
|
---|
1841 | else if (pbSig.type == "5X") {
|
---|
1842 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1843 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1844 | break;
|
---|
1845 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1846 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_L5_IQ;
|
---|
1847 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1848 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1849 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1850 | pbSig.wlIndicator;
|
---|
1851 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1852 | pbSig.discontinuityCounter;
|
---|
1853 | }
|
---|
1854 | else if (pbSig.type == "6S") {
|
---|
1855 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1856 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1857 | break;
|
---|
1858 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1859 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_LEX_S;
|
---|
1860 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1861 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1862 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1863 | pbSig.wlIndicator;
|
---|
1864 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1865 | pbSig.discontinuityCounter;
|
---|
1866 | }
|
---|
1867 | else if (pbSig.type == "6L") {
|
---|
1868 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1869 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1870 | break;
|
---|
1871 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1872 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_LEX_L;
|
---|
1873 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1874 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1875 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1876 | pbSig.wlIndicator;
|
---|
1877 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1878 | pbSig.discontinuityCounter;
|
---|
1879 | }
|
---|
1880 | else if (pbSig.type == "6X") {
|
---|
1881 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1882 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1883 | break;
|
---|
1884 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1885 | phasebiasSat->Biases[ii].Type = CODETYPEQZSS_LEX_SL;
|
---|
1886 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1887 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1888 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1889 | pbSig.wlIndicator;
|
---|
1890 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1891 | pbSig.discontinuityCounter;
|
---|
1892 | }
|
---|
1893 | }
|
---|
1894 | }
|
---|
1895 | if (prn.system() == 'S') {
|
---|
1896 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1897 | while (it.hasNext()) {
|
---|
1898 | const phaseBiasSignal &pbSig = it.next();
|
---|
1899 | if (pbSig.type == "1C") {
|
---|
1900 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1901 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1902 | break;
|
---|
1903 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1904 | phasebiasSat->Biases[ii].Type = CODETYPE_SBAS_L1_CA;
|
---|
1905 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1906 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1907 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1908 | pbSig.wlIndicator;
|
---|
1909 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1910 | pbSig.discontinuityCounter;
|
---|
1911 | }
|
---|
1912 | else if (pbSig.type == "5I") {
|
---|
1913 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1914 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1915 | break;
|
---|
1916 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1917 | phasebiasSat->Biases[ii].Type = CODETYPE_SBAS_L5_I;
|
---|
1918 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1919 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1920 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1921 | pbSig.wlIndicator;
|
---|
1922 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1923 | pbSig.discontinuityCounter;
|
---|
1924 | }
|
---|
1925 | else if (pbSig.type == "5Q") {
|
---|
1926 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1927 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1928 | break;
|
---|
1929 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1930 | phasebiasSat->Biases[ii].Type = CODETYPE_SBAS_L5_Q;
|
---|
1931 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1932 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1933 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1934 | pbSig.wlIndicator;
|
---|
1935 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1936 | pbSig.discontinuityCounter;
|
---|
1937 | }
|
---|
1938 | else if (pbSig.type == "5X") {
|
---|
1939 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1940 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1941 | break;
|
---|
1942 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1943 | phasebiasSat->Biases[ii].Type = CODETYPE_SBAS_L5_IQ;
|
---|
1944 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1945 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1946 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1947 | pbSig.wlIndicator;
|
---|
1948 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1949 | pbSig.discontinuityCounter;
|
---|
1950 | }
|
---|
1951 | }
|
---|
1952 | }
|
---|
1953 | if (prn.system() == 'C') {
|
---|
1954 | QListIterator<phaseBiasSignal> it(phaseBiasList);
|
---|
1955 | while (it.hasNext()) {
|
---|
1956 | const phaseBiasSignal &pbSig = it.next();
|
---|
1957 | if (pbSig.type == "2I") {
|
---|
1958 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1959 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1960 | break;
|
---|
1961 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1962 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B1_I;
|
---|
1963 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1964 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1965 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1966 | pbSig.wlIndicator;
|
---|
1967 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1968 | pbSig.discontinuityCounter;
|
---|
1969 | }
|
---|
1970 | else if (pbSig.type == "2Q") {
|
---|
1971 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1972 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1973 | break;
|
---|
1974 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1975 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B1_Q;
|
---|
1976 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1977 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1978 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1979 | pbSig.wlIndicator;
|
---|
1980 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1981 | pbSig.discontinuityCounter;
|
---|
1982 | }
|
---|
1983 | else if (pbSig.type == "2X") {
|
---|
1984 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1985 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1986 | break;
|
---|
1987 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
1988 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B1_IQ;
|
---|
1989 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
1990 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
1991 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
1992 | pbSig.wlIndicator;
|
---|
1993 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
1994 | pbSig.discontinuityCounter;
|
---|
1995 | }
|
---|
1996 | else if (pbSig.type == "6I") {
|
---|
1997 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
1998 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
1999 | break;
|
---|
2000 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2001 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B3_I;
|
---|
2002 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2003 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2004 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2005 | pbSig.wlIndicator;
|
---|
2006 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2007 | pbSig.discontinuityCounter;
|
---|
2008 | }
|
---|
2009 | else if (pbSig.type == "6Q") {
|
---|
2010 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
2011 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
2012 | break;
|
---|
2013 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2014 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B3_Q;
|
---|
2015 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2016 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2017 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2018 | pbSig.wlIndicator;
|
---|
2019 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2020 | pbSig.discontinuityCounter;
|
---|
2021 | }
|
---|
2022 | else if (pbSig.type == "6X") {
|
---|
2023 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
2024 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
2025 | break;
|
---|
2026 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2027 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B3_IQ;
|
---|
2028 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2029 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2030 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2031 | pbSig.wlIndicator;
|
---|
2032 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2033 | pbSig.discontinuityCounter;
|
---|
2034 | }
|
---|
2035 | else if (pbSig.type == "7I") {
|
---|
2036 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
2037 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
2038 | break;
|
---|
2039 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2040 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B2_I;
|
---|
2041 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2042 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2043 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2044 | pbSig.wlIndicator;
|
---|
2045 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2046 | pbSig.discontinuityCounter;
|
---|
2047 | }
|
---|
2048 | else if (pbSig.type == "7Q") {
|
---|
2049 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
2050 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
2051 | break;
|
---|
2052 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2053 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B2_Q;
|
---|
2054 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2055 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2056 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2057 | pbSig.wlIndicator;
|
---|
2058 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2059 | pbSig.discontinuityCounter;
|
---|
2060 | }
|
---|
2061 | else if (pbSig.type == "7X") {
|
---|
2062 | int ii = phasebiasSat->NumberOfPhaseBiases;
|
---|
2063 | if (ii >= CLOCKORBIT_NUMBIAS)
|
---|
2064 | break;
|
---|
2065 | phasebiasSat->NumberOfPhaseBiases += 1;
|
---|
2066 | phasebiasSat->Biases[ii].Type = CODETYPE_BDS_B2_IQ;
|
---|
2067 | phasebiasSat->Biases[ii].Bias = pbSig.bias;
|
---|
2068 | phasebiasSat->Biases[ii].SignalIntegerIndicator = pbSig.integerIndicator;
|
---|
2069 | phasebiasSat->Biases[ii].SignalsWideLaneIntegerIndicator =
|
---|
2070 | pbSig.wlIndicator;
|
---|
2071 | phasebiasSat->Biases[ii].SignalDiscontinuityCounter =
|
---|
2072 | pbSig.discontinuityCounter;
|
---|
2073 | }
|
---|
2074 | }
|
---|
2075 | }
|
---|
2076 | }
|
---|
2077 | }
|
---|
2078 | }
|
---|
2079 |
|
---|
2080 | QByteArray hlpBufferCo;
|
---|
2081 |
|
---|
2082 | // Orbit and Clock Corrections together
|
---|
2083 | // ------------------------------------
|
---|
2084 | if (_samplRtcmEphCorr == 0.0) {
|
---|
2085 | if (co.NumberOfSat[CLOCKORBIT_SATGPS] > 0
|
---|
2086 | || co.NumberOfSat[CLOCKORBIT_SATGLONASS] > 0
|
---|
2087 | || co.NumberOfSat[CLOCKORBIT_SATGALILEO] > 0
|
---|
2088 | || co.NumberOfSat[CLOCKORBIT_SATQZSS] > 0
|
---|
2089 | || co.NumberOfSat[CLOCKORBIT_SATSBAS] > 0
|
---|
2090 | || co.NumberOfSat[CLOCKORBIT_SATBDS] > 0) {
|
---|
2091 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2092 | int len = MakeClockOrbit(&co, COTYPE_AUTO, 0, obuffer, sizeof(obuffer));
|
---|
2093 | if (len > 0) {
|
---|
2094 | hlpBufferCo = QByteArray(obuffer, len);
|
---|
2095 | }
|
---|
2096 | }
|
---|
2097 | }
|
---|
2098 |
|
---|
2099 | // Orbit and Clock Corrections separately
|
---|
2100 | // --------------------------------------
|
---|
2101 | else {
|
---|
2102 | if (co.NumberOfSat[CLOCKORBIT_SATGPS] > 0) {
|
---|
2103 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2104 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2105 | co.UpdateInterval = ephUpdInd;
|
---|
2106 | int len1 = MakeClockOrbit(&co, COTYPE_GPSORBIT, 1, obuffer,
|
---|
2107 | sizeof(obuffer));
|
---|
2108 | co.UpdateInterval = clkUpdInd;
|
---|
2109 | if (len1 > 0) {
|
---|
2110 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2111 | }
|
---|
2112 | }
|
---|
2113 | int mmsg = (co.NumberOfSat[CLOCKORBIT_SATGLONASS] > 0) ? 1 : 0;
|
---|
2114 | int len2 = MakeClockOrbit(&co, COTYPE_GPSCLOCK, mmsg, obuffer,
|
---|
2115 | sizeof(obuffer));
|
---|
2116 | if (len2 > 0) {
|
---|
2117 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2118 | }
|
---|
2119 | }
|
---|
2120 | if (co.NumberOfSat[CLOCKORBIT_SATGLONASS] > 0) {
|
---|
2121 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2122 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2123 | co.UpdateInterval = ephUpdInd;
|
---|
2124 | int len1 = MakeClockOrbit(&co, COTYPE_GLONASSORBIT, 1, obuffer,
|
---|
2125 | sizeof(obuffer));
|
---|
2126 | co.UpdateInterval = clkUpdInd;
|
---|
2127 | if (len1 > 0) {
|
---|
2128 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2129 | }
|
---|
2130 | }
|
---|
2131 | int mmsg = (co.NumberOfSat[CLOCKORBIT_SATGALILEO] > 0) ? 1 : 0;
|
---|
2132 | int len2 = MakeClockOrbit(&co, COTYPE_GLONASSCLOCK, mmsg, obuffer,
|
---|
2133 | sizeof(obuffer));
|
---|
2134 | if (len2 > 0) {
|
---|
2135 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2136 | }
|
---|
2137 | }
|
---|
2138 | if (co.NumberOfSat[CLOCKORBIT_SATGALILEO] > 0) {
|
---|
2139 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2140 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2141 | co.UpdateInterval = ephUpdInd;
|
---|
2142 | int len1 = MakeClockOrbit(&co, COTYPE_GALILEOORBIT, 1, obuffer,
|
---|
2143 | sizeof(obuffer));
|
---|
2144 | co.UpdateInterval = clkUpdInd;
|
---|
2145 | if (len1 > 0) {
|
---|
2146 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2147 | }
|
---|
2148 | }
|
---|
2149 | int mmsg = (co.NumberOfSat[CLOCKORBIT_SATQZSS] > 0) ? 1 : 0;
|
---|
2150 | int len2 = MakeClockOrbit(&co, COTYPE_GALILEOCLOCK, mmsg, obuffer,
|
---|
2151 | sizeof(obuffer));
|
---|
2152 | if (len2 > 0) {
|
---|
2153 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2154 | }
|
---|
2155 | }
|
---|
2156 | if (co.NumberOfSat[CLOCKORBIT_SATQZSS] > 0) {
|
---|
2157 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2158 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2159 | co.UpdateInterval = ephUpdInd;
|
---|
2160 | int len1 = MakeClockOrbit(&co, COTYPE_QZSSORBIT, 1, obuffer,
|
---|
2161 | sizeof(obuffer));
|
---|
2162 | co.UpdateInterval = clkUpdInd;
|
---|
2163 | if (len1 > 0) {
|
---|
2164 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2165 | }
|
---|
2166 | }
|
---|
2167 | int mmsg = (co.NumberOfSat[CLOCKORBIT_SATSBAS] > 0) ? 1 : 0;
|
---|
2168 | int len2 = MakeClockOrbit(&co, COTYPE_QZSSCLOCK, mmsg, obuffer,
|
---|
2169 | sizeof(obuffer));
|
---|
2170 | if (len2 > 0) {
|
---|
2171 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2172 | }
|
---|
2173 | }
|
---|
2174 | if (co.NumberOfSat[CLOCKORBIT_SATSBAS] > 0) {
|
---|
2175 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2176 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2177 | co.UpdateInterval = ephUpdInd;
|
---|
2178 | int len1 = MakeClockOrbit(&co, COTYPE_SBASORBIT, 1, obuffer,
|
---|
2179 | sizeof(obuffer));
|
---|
2180 | co.UpdateInterval = clkUpdInd;
|
---|
2181 | if (len1 > 0) {
|
---|
2182 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2183 | }
|
---|
2184 | }
|
---|
2185 | int mmsg = (co.NumberOfSat[CLOCKORBIT_SATBDS] > 0) ? 1 : 0;
|
---|
2186 | int len2 = MakeClockOrbit(&co, COTYPE_SBASCLOCK, mmsg, obuffer,
|
---|
2187 | sizeof(obuffer));
|
---|
2188 | if (len2 > 0) {
|
---|
2189 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2190 | }
|
---|
2191 | }
|
---|
2192 | if (co.NumberOfSat[CLOCKORBIT_SATBDS] > 0) {
|
---|
2193 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2194 | if (fmod(epoTime.gpssec(), _samplRtcmEphCorr) == 0.0) {
|
---|
2195 | co.UpdateInterval = ephUpdInd;
|
---|
2196 | int len1 = MakeClockOrbit(&co, COTYPE_BDSORBIT, 1, obuffer,
|
---|
2197 | sizeof(obuffer));
|
---|
2198 | co.UpdateInterval = clkUpdInd;
|
---|
2199 | if (len1 > 0) {
|
---|
2200 | hlpBufferCo += QByteArray(obuffer, len1);
|
---|
2201 | }
|
---|
2202 | }
|
---|
2203 | int len2 = MakeClockOrbit(&co, COTYPE_BDSCLOCK, 0, obuffer,
|
---|
2204 | sizeof(obuffer));
|
---|
2205 | if (len2 > 0) {
|
---|
2206 | hlpBufferCo += QByteArray(obuffer, len2);
|
---|
2207 | }
|
---|
2208 | }
|
---|
2209 | }
|
---|
2210 |
|
---|
2211 | // Code Biases
|
---|
2212 | // -----------
|
---|
2213 | QByteArray hlpBufferBias;
|
---|
2214 | if (bias.NumberOfSat[CLOCKORBIT_SATGPS] > 0
|
---|
2215 | || bias.NumberOfSat[CLOCKORBIT_SATGLONASS] > 0
|
---|
2216 | || bias.NumberOfSat[CLOCKORBIT_SATGALILEO] > 0
|
---|
2217 | || bias.NumberOfSat[CLOCKORBIT_SATQZSS] > 0
|
---|
2218 | || bias.NumberOfSat[CLOCKORBIT_SATSBAS] > 0
|
---|
2219 | || bias.NumberOfSat[CLOCKORBIT_SATBDS] > 0) {
|
---|
2220 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2221 | int len = MakeCodeBias(&bias, BTYPE_AUTO, 0, obuffer, sizeof(obuffer));
|
---|
2222 | if (len > 0) {
|
---|
2223 | hlpBufferBias = QByteArray(obuffer, len);
|
---|
2224 | }
|
---|
2225 | }
|
---|
2226 |
|
---|
2227 | // Phase Biases
|
---|
2228 | // ------------
|
---|
2229 | QByteArray hlpBufferPhaseBias;
|
---|
2230 | if (phasebias.NumberOfSat[CLOCKORBIT_SATGPS] > 0
|
---|
2231 | || phasebias.NumberOfSat[CLOCKORBIT_SATGLONASS] > 0
|
---|
2232 | || phasebias.NumberOfSat[CLOCKORBIT_SATGALILEO] > 0
|
---|
2233 | || phasebias.NumberOfSat[CLOCKORBIT_SATQZSS] > 0
|
---|
2234 | || phasebias.NumberOfSat[CLOCKORBIT_SATSBAS] > 0
|
---|
2235 | || phasebias.NumberOfSat[CLOCKORBIT_SATBDS] > 0) {
|
---|
2236 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2237 | int len = MakePhaseBias(&phasebias, PBTYPE_AUTO, 0, obuffer,
|
---|
2238 | sizeof(obuffer));
|
---|
2239 | if (len > 0) {
|
---|
2240 | hlpBufferPhaseBias = QByteArray(obuffer, len);
|
---|
2241 | }
|
---|
2242 | }
|
---|
2243 |
|
---|
2244 | // VTEC
|
---|
2245 | // ----
|
---|
2246 | QByteArray hlpBufferVtec;
|
---|
2247 | if (vtec.NumLayers > 0) {
|
---|
2248 | char obuffer[CLOCKORBIT_BUFFERSIZE];
|
---|
2249 | int len = MakeVTEC(&vtec, 0, obuffer, sizeof(obuffer));
|
---|
2250 | if (len > 0) {
|
---|
2251 | hlpBufferVtec = QByteArray(obuffer, len);
|
---|
2252 | }
|
---|
2253 | }
|
---|
2254 |
|
---|
2255 | _outBuffer += hlpBufferCo + hlpBufferBias + hlpBufferPhaseBias
|
---|
2256 | + hlpBufferVtec;
|
---|
2257 | }
|
---|
2258 |
|
---|
2259 | //
|
---|
2260 | ////////////////////////////////////////////////////////////////////////////
|
---|
2261 | t_irc bncRtnetUploadCaster::processSatellite(const t_eph* eph, int GPSweek,
|
---|
2262 | double GPSweeks, const QString& prn, const ColumnVector& rtnAPC,
|
---|
2263 | double rtnUra, const ColumnVector& rtnClk, const ColumnVector& rtnVel,
|
---|
2264 | const ColumnVector& rtnCoM, const ColumnVector& rtnClkSig,
|
---|
2265 | struct ClockOrbit::SatData* sd, QString& outLine) {
|
---|
2266 |
|
---|
2267 | // Broadcast Position and Velocity
|
---|
2268 | // -------------------------------
|
---|
2269 | ColumnVector xB(6);
|
---|
2270 | ColumnVector vB(3);
|
---|
2271 | t_irc irc = eph->getCrd(bncTime(GPSweek, GPSweeks), xB, vB, false);
|
---|
2272 |
|
---|
2273 | if (irc != success) {
|
---|
2274 | return irc;
|
---|
2275 | }
|
---|
2276 |
|
---|
2277 | // Precise Position
|
---|
2278 | // ----------------
|
---|
2279 | ColumnVector xP = _CoM ? rtnCoM : rtnAPC;
|
---|
2280 |
|
---|
2281 | if (xP.size() == 0) {
|
---|
2282 | return failure;
|
---|
2283 | }
|
---|
2284 |
|
---|
2285 | double dc = 0.0;
|
---|
2286 | if (_crdTrafo != "IGS14") {
|
---|
2287 | crdTrafo(GPSweek, xP, dc);
|
---|
2288 | }
|
---|
2289 |
|
---|
2290 | // Difference in xyz
|
---|
2291 | // -----------------
|
---|
2292 | ColumnVector dx = xB.Rows(1, 3) - xP;
|
---|
2293 | ColumnVector dv = vB - rtnVel;
|
---|
2294 |
|
---|
2295 | // Difference in RSW
|
---|
2296 | // -----------------
|
---|
2297 | ColumnVector rsw(3);
|
---|
2298 | XYZ_to_RSW(xB.Rows(1, 3), vB, dx, rsw);
|
---|
2299 |
|
---|
2300 | ColumnVector dotRsw(3);
|
---|
2301 | XYZ_to_RSW(xB.Rows(1, 3), vB, dv, dotRsw);
|
---|
2302 |
|
---|
2303 | // Clock Correction
|
---|
2304 | // ----------------
|
---|
2305 | double dClkA0 = rtnClk(1) - (xB(4) - dc) * t_CST::c;
|
---|
2306 | double dClkA1 = 0.0;
|
---|
2307 | if (rtnClk(2)) {
|
---|
2308 | dClkA1 = rtnClk(2) - xB(5) * t_CST::c;
|
---|
2309 | }
|
---|
2310 | double dClkA2 = 0.0;
|
---|
2311 | if (rtnClk(3)) {
|
---|
2312 | dClkA2 = rtnClk(3) - xB(6) * t_CST::c;
|
---|
2313 | }
|
---|
2314 |
|
---|
2315 | if (sd) {
|
---|
2316 | sd->ID = prn.mid(1).toInt();
|
---|
2317 | sd->IOD = eph->IOD();
|
---|
2318 | sd->Clock.DeltaA0 = dClkA0;
|
---|
2319 | sd->Clock.DeltaA1 = dClkA1;
|
---|
2320 | sd->Clock.DeltaA2 = dClkA2;
|
---|
2321 | sd->UserRangeAccuracy = rtnUra;
|
---|
2322 | sd->Orbit.DeltaRadial = rsw(1);
|
---|
2323 | sd->Orbit.DeltaAlongTrack = rsw(2);
|
---|
2324 | sd->Orbit.DeltaCrossTrack = rsw(3);
|
---|
2325 | sd->Orbit.DotDeltaRadial = dotRsw(1);
|
---|
2326 | sd->Orbit.DotDeltaAlongTrack = dotRsw(2);
|
---|
2327 | sd->Orbit.DotDeltaCrossTrack = dotRsw(3);
|
---|
2328 | }
|
---|
2329 |
|
---|
2330 | outLine.sprintf("%d %.1f %s %u %10.3f %8.3f %8.3f %8.3f %8.3f %8.3f\n", GPSweek,
|
---|
2331 | GPSweeks, eph->prn().toString().c_str(), eph->IOD(), dClkA0, dClkA1, dClkA2,
|
---|
2332 | rsw(1), rsw(2), rsw(3));
|
---|
2333 |
|
---|
2334 | // RTNET full clock for RINEX and SP3 file
|
---|
2335 | // ---------------------------------------
|
---|
2336 | double relativity = -2.0 * DotProduct(xP, rtnVel) / t_CST::c;
|
---|
2337 | double clkRnx = (rtnClk[0] - relativity) / t_CST::c; // [s]
|
---|
2338 | double clkRnxRate = rtnClk[1] / t_CST::c; // [s/s = -]
|
---|
2339 | double clkRnxAcc = rtnClk[2] / t_CST::c; // [s/s² ) -/s]
|
---|
2340 |
|
---|
2341 | if (_rnx) {
|
---|
2342 | double clkRnxSig, clkRnxRateSig, clkRnxAccSig;
|
---|
2343 | int s = rtnClkSig.size();
|
---|
2344 | switch (s) {
|
---|
2345 | case 1:
|
---|
2346 | clkRnxSig = rtnClkSig[0] / t_CST::c; // [s]
|
---|
2347 | clkRnxRateSig = 0.0; // [s/s = -]
|
---|
2348 | clkRnxAccSig = 0.0; // [s/s² ) -/s]
|
---|
2349 | break;
|
---|
2350 | case 2:
|
---|
2351 | clkRnxSig = rtnClkSig[0] / t_CST::c; // [s]
|
---|
2352 | clkRnxRateSig = rtnClkSig[1] / t_CST::c; // [s/s = -]
|
---|
2353 | clkRnxAccSig = 0.0; // [s/s² ) -/s]
|
---|
2354 | break;
|
---|
2355 | case 3:
|
---|
2356 | clkRnxSig = rtnClkSig[0] / t_CST::c; // [s]
|
---|
2357 | clkRnxRateSig = rtnClkSig[1] / t_CST::c; // [s/s = -]
|
---|
2358 | clkRnxAccSig = rtnClkSig[2] / t_CST::c; // [s/s² ) -/s]
|
---|
2359 | break;
|
---|
2360 | }
|
---|
2361 | _rnx->write(GPSweek, GPSweeks, prn, clkRnx, clkRnxRate, clkRnxAcc,
|
---|
2362 | clkRnxSig, clkRnxRateSig, clkRnxAccSig);
|
---|
2363 | }
|
---|
2364 | if (_sp3) {
|
---|
2365 | _sp3->write(GPSweek, GPSweeks, prn, rtnCoM, clkRnx, rtnVel, clkRnxRate);
|
---|
2366 | }
|
---|
2367 | return success;
|
---|
2368 | }
|
---|
2369 |
|
---|
2370 | // Transform Coordinates
|
---|
2371 | ////////////////////////////////////////////////////////////////////////////
|
---|
2372 | void bncRtnetUploadCaster::crdTrafo(int GPSWeek, ColumnVector& xyz,
|
---|
2373 | double& dc) {
|
---|
2374 |
|
---|
2375 | // Current epoch minus 2000.0 in years
|
---|
2376 | // ------------------------------------
|
---|
2377 | double dt = (GPSWeek - (1042.0 + 6.0 / 7.0)) / 365.2422 * 7.0 + 2000.0 - _t0;
|
---|
2378 |
|
---|
2379 | ColumnVector dx(3);
|
---|
2380 |
|
---|
2381 | dx(1) = _dx + dt * _dxr;
|
---|
2382 | dx(2) = _dy + dt * _dyr;
|
---|
2383 | dx(3) = _dz + dt * _dzr;
|
---|
2384 |
|
---|
2385 | static const double arcSec = 180.0 * 3600.0 / M_PI;
|
---|
2386 |
|
---|
2387 | double ox = (_ox + dt * _oxr) / arcSec;
|
---|
2388 | double oy = (_oy + dt * _oyr) / arcSec;
|
---|
2389 | double oz = (_oz + dt * _ozr) / arcSec;
|
---|
2390 |
|
---|
2391 | double sc = 1.0 + _sc * 1e-9 + dt * _scr * 1e-9;
|
---|
2392 |
|
---|
2393 | // Specify approximate center of area
|
---|
2394 | // ----------------------------------
|
---|
2395 | ColumnVector meanSta(3);
|
---|
2396 |
|
---|
2397 | if (_crdTrafo == "ETRF2000") {
|
---|
2398 | meanSta(1) = 3661090.0;
|
---|
2399 | meanSta(2) = 845230.0;
|
---|
2400 | meanSta(3) = 5136850.0;
|
---|
2401 | }
|
---|
2402 | else if (_crdTrafo == "GDA2020") {
|
---|
2403 | meanSta(1) = -4052050.0;
|
---|
2404 | meanSta(2) = 4212840.0;
|
---|
2405 | meanSta(3) = -2545110.0;
|
---|
2406 | }
|
---|
2407 | else if (_crdTrafo == "SIRGAS2000") {
|
---|
2408 | meanSta(1) = 3740860.0;
|
---|
2409 | meanSta(2) = -4964290.0;
|
---|
2410 | meanSta(3) = -1425420.0;
|
---|
2411 | }
|
---|
2412 | else if (_crdTrafo == "DREF91") {
|
---|
2413 | meanSta(1) = 3959579.0;
|
---|
2414 | meanSta(2) = 721719.0;
|
---|
2415 | meanSta(3) = 4931539.0;
|
---|
2416 | }
|
---|
2417 | else if (_crdTrafo == "Custom") {
|
---|
2418 | meanSta(1) = 0.0; // TODO
|
---|
2419 | meanSta(2) = 0.0; // TODO
|
---|
2420 | meanSta(3) = 0.0; // TODO
|
---|
2421 | }
|
---|
2422 |
|
---|
2423 | // Clock correction proportional to topocentric distance to satellites
|
---|
2424 | // -------------------------------------------------------------------
|
---|
2425 | double rho = (xyz - meanSta).norm_Frobenius();
|
---|
2426 | dc = rho * (sc - 1.0) / sc / t_CST::c;
|
---|
2427 |
|
---|
2428 | Matrix rMat(3, 3);
|
---|
2429 | rMat(1, 1) = 1.0;
|
---|
2430 | rMat(1, 2) = -oz;
|
---|
2431 | rMat(1, 3) = oy;
|
---|
2432 | rMat(2, 1) = oz;
|
---|
2433 | rMat(2, 2) = 1.0;
|
---|
2434 | rMat(2, 3) = -ox;
|
---|
2435 | rMat(3, 1) = -oy;
|
---|
2436 | rMat(3, 2) = ox;
|
---|
2437 | rMat(3, 3) = 1.0;
|
---|
2438 |
|
---|
2439 | xyz = sc * rMat * xyz + dx;
|
---|
2440 | }
|
---|
2441 |
|
---|
2442 | int bncRtnetUploadCaster::determineUpdateInd(double samplingRate) {
|
---|
2443 |
|
---|
2444 | if (samplingRate == 10.0) {
|
---|
2445 | return 3;
|
---|
2446 | }
|
---|
2447 | else if (samplingRate == 15.0) {
|
---|
2448 | return 4;
|
---|
2449 | }
|
---|
2450 | else if (samplingRate == 30.0) {
|
---|
2451 | return 5;
|
---|
2452 | }
|
---|
2453 | else if (samplingRate == 60.0) {
|
---|
2454 | return 6;
|
---|
2455 | }
|
---|
2456 | else if (samplingRate == 120.0) {
|
---|
2457 | return 7;
|
---|
2458 | }
|
---|
2459 | else if (samplingRate == 240.0) {
|
---|
2460 | return 8;
|
---|
2461 | }
|
---|
2462 | else if (samplingRate == 300.0) {
|
---|
2463 | return 9;
|
---|
2464 | }
|
---|
2465 | else if (samplingRate == 600.0) {
|
---|
2466 | return 10;
|
---|
2467 | }
|
---|
2468 | else if (samplingRate == 900.0) {
|
---|
2469 | return 11;
|
---|
2470 | }
|
---|
2471 | else if (samplingRate == 1800.0) {
|
---|
2472 | return 12;
|
---|
2473 | }
|
---|
2474 | else if (samplingRate == 3600.0) {
|
---|
2475 | return 13;
|
---|
2476 | }
|
---|
2477 | else if (samplingRate == 7200.0) {
|
---|
2478 | return 14;
|
---|
2479 | }
|
---|
2480 | else if (samplingRate == 10800.0) {
|
---|
2481 | return 15;
|
---|
2482 | }
|
---|
2483 | return 2; // default
|
---|
2484 | }
|
---|