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