gnss-js 2.9.0 → 2.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1566,6 +1566,21 @@ function writeRinexObsBlob(header, epochs, obsTypes) {
1566
1566
  comment: "Merged from multiple RINEX files"
1567
1567
  });
1568
1568
  }
1569
+ function modalIntervalS(epochs) {
1570
+ const counts = /* @__PURE__ */ new Map();
1571
+ for (let i = 1; i < epochs.length; i++) {
1572
+ const d = Math.round(epochs[i].time - epochs[i - 1].time);
1573
+ if (d > 0) counts.set(d, (counts.get(d) ?? 0) + 1);
1574
+ }
1575
+ let best = null;
1576
+ let bestN = 0;
1577
+ for (const [d, n] of counts)
1578
+ if (n > bestN || n === bestN && best !== null && d < best) {
1579
+ best = d;
1580
+ bestN = n;
1581
+ }
1582
+ return best === null ? null : best / 1e3;
1583
+ }
1569
1584
  async function writeModernObsBlob(header, epochs, obsTypes, opts) {
1570
1585
  if (epochs.length === 0) return new Blob([], { type: "application/gzip" });
1571
1586
  const sink = createGzipLineSink();
@@ -1612,11 +1627,9 @@ async function writeModernObsBlob(header, epochs, obsTypes, opts) {
1612
1627
  "TIME OF LAST OBS"
1613
1628
  )
1614
1629
  );
1615
- if (epochs.length >= 2) {
1616
- const interval = (epochs[1].time - epochs[0].time) / 1e3;
1617
- if (interval > 0 && interval < 3600) {
1618
- sink.push(hdrLine(fmtF(interval, 10, 3), "INTERVAL"));
1619
- }
1630
+ const interval = modalIntervalS(epochs);
1631
+ if (interval !== null && interval < 3600) {
1632
+ sink.push(hdrLine(fmtF(interval, 10, 3), "INTERVAL"));
1620
1633
  }
1621
1634
  if (header.glonassSlots && Object.keys(header.glonassSlots).length > 0) {
1622
1635
  const entries = Object.entries(header.glonassSlots).sort(
@@ -1888,6 +1901,7 @@ export {
1888
1901
  createGzipLineSink,
1889
1902
  stationHeaderLines,
1890
1903
  writeRinexObsBlob,
1904
+ modalIntervalS,
1891
1905
  writeModernObsBlob,
1892
1906
  writeRinex2ObsBlob,
1893
1907
  writeRinex4ObsBlob
@@ -1621,6 +1621,66 @@ var ZeroBaselineEngine = class {
1621
1621
  }
1622
1622
  };
1623
1623
 
1624
+ // src/positioning/msm-resolve.ts
1625
+ var LIGHT_MS = C_LIGHT / 1e3;
1626
+ var MAX_FRACTION_MISFIT = 0.25;
1627
+ function predictedRange(eph, timeMs, rx) {
1628
+ let tau = 0.075;
1629
+ for (let i = 0; i < 2; i++) {
1630
+ const tEmit = timeMs - tau * 1e3;
1631
+ const p = computeSatPosition(eph, tEmit);
1632
+ if (!Number.isFinite(p.x)) return null;
1633
+ const rho = Math.hypot(p.x - rx[0], p.y - rx[1], p.z - rx[2]);
1634
+ tau = rho / C_LIGHT;
1635
+ if (i === 1) return rho - C_LIGHT * satClockCorrection(eph, tEmit);
1636
+ }
1637
+ return null;
1638
+ }
1639
+ function moduloRange(sat) {
1640
+ for (const s of sat.signals)
1641
+ if (s.pseudorange !== void 0) return s.pseudorange;
1642
+ for (const s of sat.signals)
1643
+ if (s.phase !== void 0 && s.wavelength > 0)
1644
+ return s.phase * s.wavelength;
1645
+ return null;
1646
+ }
1647
+ function resolveMsmRanges(epoch, opts) {
1648
+ if (!epoch.rangeModulo1ms) return epoch;
1649
+ const cand = [];
1650
+ for (const sat of epoch.observations) {
1651
+ const eph = opts.ephFor(sat.prn);
1652
+ const mod = moduloRange(sat);
1653
+ if (!eph || mod === null) continue;
1654
+ const pred = predictedRange(eph, opts.timeMs, opts.rxEcef);
1655
+ if (pred === null) continue;
1656
+ cand.push({ sat, k: (pred - mod) / LIGHT_MS });
1657
+ }
1658
+ const { rangeModulo1ms: _drop, ...rest } = epoch;
1659
+ if (cand.length === 0) return { ...rest, observations: [] };
1660
+ let sx = 0;
1661
+ let sy = 0;
1662
+ for (const c of cand) {
1663
+ sx += Math.cos(2 * Math.PI * c.k);
1664
+ sy += Math.sin(2 * Math.PI * c.k);
1665
+ }
1666
+ const b = Math.atan2(sy, sx) / (2 * Math.PI);
1667
+ const observations = [];
1668
+ for (const { sat, k } of cand) {
1669
+ const n = Math.round(k - b);
1670
+ if (Math.abs(k - b - n) > MAX_FRACTION_MISFIT) continue;
1671
+ const add = n * LIGHT_MS;
1672
+ observations.push({
1673
+ ...sat,
1674
+ signals: sat.signals.map((s) => ({
1675
+ ...s,
1676
+ ...s.pseudorange !== void 0 ? { pseudorange: s.pseudorange + add } : {},
1677
+ ...s.phase !== void 0 && s.wavelength > 0 ? { phase: s.phase + add / s.wavelength } : {}
1678
+ }))
1679
+ });
1680
+ }
1681
+ return { ...rest, observations };
1682
+ }
1683
+
1624
1684
  // src/positioning/sbas.ts
1625
1685
  var P2_11 = 2 ** -11;
1626
1686
  var P2_31 = 2 ** -31;
@@ -4011,6 +4071,7 @@ export {
4011
4071
  RtkFloatEngine,
4012
4072
  postProcessRtk,
4013
4073
  ZeroBaselineEngine,
4074
+ resolveMsmRanges,
4014
4075
  sbasLongTermDeg,
4015
4076
  sbasIonoDeg,
4016
4077
  SbasProcessor,
@@ -1138,12 +1138,14 @@ function satPrn(sys, satIdx1) {
1138
1138
  const num = sys === "S" ? satIdx1 + 119 : satIdx1;
1139
1139
  return `${prefix}${String(num).padStart(2, "0")}`;
1140
1140
  }
1141
- function decodeMsmFull(frame) {
1141
+ function decodeMsmFull(frame, opts = {}) {
1142
1142
  const type = frame.messageType;
1143
1143
  const sys = msmSystem(type);
1144
1144
  if (!sys) return null;
1145
1145
  const variant = type % 10;
1146
- if (variant < 4 || variant > 7) return null;
1146
+ if (variant < 1 || variant > 7) return null;
1147
+ const compact = variant <= 3;
1148
+ if (compact && !opts.compactMsm) return null;
1147
1149
  const payload = frame.payload;
1148
1150
  if (!payload || payload.length < 10) return null;
1149
1151
  try {
@@ -1188,7 +1190,9 @@ function decodeMsmFull(frame) {
1188
1190
  const rrmod = new Float64Array(numSat);
1189
1191
  const extsat = new Int8Array(numSat);
1190
1192
  const rdop = new Float64Array(numSat);
1191
- if (variant === 4 || variant === 6) {
1193
+ if (compact) {
1194
+ for (let j = 0; j < numSat; j++) rrmod[j] = bits.readU(10) / 1024;
1195
+ } else if (variant === 4 || variant === 6) {
1192
1196
  for (let j = 0; j < numSat; j++) rrint[j] = bits.readU(8);
1193
1197
  for (let j = 0; j < numSat; j++) rrmod[j] = bits.readU(10) / 1024;
1194
1198
  } else {
@@ -1214,7 +1218,18 @@ function decodeMsmFull(frame) {
1214
1218
  psr.fill(-1e30);
1215
1219
  cp.fill(-1e30);
1216
1220
  dop.fill(-1e30);
1217
- if (variant === 4) {
1221
+ if (variant === 1) {
1222
+ for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
1223
+ } else if (variant === 2) {
1224
+ for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
1225
+ for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
1226
+ for (let i = 0; i < activeCells; i++) hc[i] = bits.readU(1);
1227
+ } else if (variant === 3) {
1228
+ for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
1229
+ for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
1230
+ for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
1231
+ for (let i = 0; i < activeCells; i++) hc[i] = bits.readU(1);
1232
+ } else if (variant === 4) {
1218
1233
  for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
1219
1234
  for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
1220
1235
  for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
@@ -1290,8 +1305,10 @@ function decodeMsmFull(frame) {
1290
1305
  if (cnrVal > 0) {
1291
1306
  signal.cn0 = cnrVal;
1292
1307
  }
1293
- signal.lockTime = lockTimeSec(type, ll[cellIdx]);
1294
- signal.halfCycle = hc[cellIdx] === 1;
1308
+ if (variant !== 1) {
1309
+ signal.lockTime = lockTimeSec(type, ll[cellIdx]);
1310
+ signal.halfCycle = hc[cellIdx] === 1;
1311
+ }
1295
1312
  signals.push(signal);
1296
1313
  cellIdx++;
1297
1314
  }
@@ -1303,7 +1320,8 @@ function decodeMsmFull(frame) {
1303
1320
  messageType: type,
1304
1321
  epochMs,
1305
1322
  system: sys,
1306
- observations
1323
+ observations,
1324
+ ...compact ? { rangeModulo1ms: true } : {}
1307
1325
  };
1308
1326
  } catch (err) {
1309
1327
  reportDecodeError("msm", err);
@@ -1457,8 +1475,8 @@ function decodeLegacyObs(frame) {
1457
1475
  }
1458
1476
  return { messageType: type, epochMs, system, observations };
1459
1477
  }
1460
- function decodeObs(frame) {
1461
- return decodeMsmFull(frame) ?? decodeLegacyObs(frame);
1478
+ function decodeObs(frame, opts = {}) {
1479
+ return decodeMsmFull(frame, opts) ?? decodeLegacyObs(frame);
1462
1480
  }
1463
1481
 
1464
1482
  // src/rtcm3/ssr.ts
package/dist/index.cjs CHANGED
@@ -264,6 +264,7 @@ __export(src_exports, {
264
264
  looksLikeRtcm2: () => looksLikeRtcm2,
265
265
  maskRadForAzimuth: () => maskRadForAzimuth,
266
266
  meridianArc: () => meridianArc,
267
+ modalIntervalS: () => modalIntervalS,
267
268
  moonEcef: () => moonEcef,
268
269
  navTimesFromEph: () => navTimesFromEph,
269
270
  nearestValidEphemeris: () => nearestValidEphemeris,
@@ -323,6 +324,7 @@ __export(src_exports, {
323
324
  readString: () => readString,
324
325
  reportDecodeError: () => reportDecodeError,
325
326
  resetGloFreqCache: () => resetGloFreqCache,
327
+ resolveMsmRanges: () => resolveMsmRanges,
326
328
  resolvePppAmbiguities: () => resolvePppAmbiguities,
327
329
  rhumbLine: () => rhumbLine,
328
330
  rtcm2Dgps: () => rtcm2Dgps,
@@ -4259,6 +4261,21 @@ function writeRinexObsBlob(header, epochs, obsTypes) {
4259
4261
  comment: "Merged from multiple RINEX files"
4260
4262
  });
4261
4263
  }
4264
+ function modalIntervalS(epochs) {
4265
+ const counts = /* @__PURE__ */ new Map();
4266
+ for (let i = 1; i < epochs.length; i++) {
4267
+ const d = Math.round(epochs[i].time - epochs[i - 1].time);
4268
+ if (d > 0) counts.set(d, (counts.get(d) ?? 0) + 1);
4269
+ }
4270
+ let best = null;
4271
+ let bestN = 0;
4272
+ for (const [d, n] of counts)
4273
+ if (n > bestN || n === bestN && best !== null && d < best) {
4274
+ best = d;
4275
+ bestN = n;
4276
+ }
4277
+ return best === null ? null : best / 1e3;
4278
+ }
4262
4279
  async function writeModernObsBlob(header, epochs, obsTypes, opts) {
4263
4280
  if (epochs.length === 0) return new Blob([], { type: "application/gzip" });
4264
4281
  const sink = createGzipLineSink();
@@ -4305,11 +4322,9 @@ async function writeModernObsBlob(header, epochs, obsTypes, opts) {
4305
4322
  "TIME OF LAST OBS"
4306
4323
  )
4307
4324
  );
4308
- if (epochs.length >= 2) {
4309
- const interval = (epochs[1].time - epochs[0].time) / 1e3;
4310
- if (interval > 0 && interval < 3600) {
4311
- sink.push(hdrLine(fmtF(interval, 10, 3), "INTERVAL"));
4312
- }
4325
+ const interval = modalIntervalS(epochs);
4326
+ if (interval !== null && interval < 3600) {
4327
+ sink.push(hdrLine(fmtF(interval, 10, 3), "INTERVAL"));
4313
4328
  }
4314
4329
  if (header.glonassSlots && Object.keys(header.glonassSlots).length > 0) {
4315
4330
  const entries = Object.entries(header.glonassSlots).sort(
@@ -5944,12 +5959,14 @@ function satPrn(sys, satIdx1) {
5944
5959
  const num = sys === "S" ? satIdx1 + 119 : satIdx1;
5945
5960
  return `${prefix}${String(num).padStart(2, "0")}`;
5946
5961
  }
5947
- function decodeMsmFull(frame) {
5962
+ function decodeMsmFull(frame, opts = {}) {
5948
5963
  const type = frame.messageType;
5949
5964
  const sys = msmSystem(type);
5950
5965
  if (!sys) return null;
5951
5966
  const variant = type % 10;
5952
- if (variant < 4 || variant > 7) return null;
5967
+ if (variant < 1 || variant > 7) return null;
5968
+ const compact = variant <= 3;
5969
+ if (compact && !opts.compactMsm) return null;
5953
5970
  const payload = frame.payload;
5954
5971
  if (!payload || payload.length < 10) return null;
5955
5972
  try {
@@ -5994,7 +6011,9 @@ function decodeMsmFull(frame) {
5994
6011
  const rrmod = new Float64Array(numSat);
5995
6012
  const extsat = new Int8Array(numSat);
5996
6013
  const rdop = new Float64Array(numSat);
5997
- if (variant === 4 || variant === 6) {
6014
+ if (compact) {
6015
+ for (let j = 0; j < numSat; j++) rrmod[j] = bits.readU(10) / 1024;
6016
+ } else if (variant === 4 || variant === 6) {
5998
6017
  for (let j = 0; j < numSat; j++) rrint[j] = bits.readU(8);
5999
6018
  for (let j = 0; j < numSat; j++) rrmod[j] = bits.readU(10) / 1024;
6000
6019
  } else {
@@ -6020,7 +6039,18 @@ function decodeMsmFull(frame) {
6020
6039
  psr.fill(-1e30);
6021
6040
  cp.fill(-1e30);
6022
6041
  dop.fill(-1e30);
6023
- if (variant === 4) {
6042
+ if (variant === 1) {
6043
+ for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
6044
+ } else if (variant === 2) {
6045
+ for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
6046
+ for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
6047
+ for (let i = 0; i < activeCells; i++) hc[i] = bits.readU(1);
6048
+ } else if (variant === 3) {
6049
+ for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
6050
+ for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
6051
+ for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
6052
+ for (let i = 0; i < activeCells; i++) hc[i] = bits.readU(1);
6053
+ } else if (variant === 4) {
6024
6054
  for (let i = 0; i < activeCells; i++) psr[i] = bits.readS(15) / 2 ** 24;
6025
6055
  for (let i = 0; i < activeCells; i++) cp[i] = bits.readS(22) / 2 ** 29;
6026
6056
  for (let i = 0; i < activeCells; i++) ll[i] = bits.readU(4);
@@ -6096,8 +6126,10 @@ function decodeMsmFull(frame) {
6096
6126
  if (cnrVal > 0) {
6097
6127
  signal.cn0 = cnrVal;
6098
6128
  }
6099
- signal.lockTime = lockTimeSec(type, ll[cellIdx]);
6100
- signal.halfCycle = hc[cellIdx] === 1;
6129
+ if (variant !== 1) {
6130
+ signal.lockTime = lockTimeSec(type, ll[cellIdx]);
6131
+ signal.halfCycle = hc[cellIdx] === 1;
6132
+ }
6101
6133
  signals.push(signal);
6102
6134
  cellIdx++;
6103
6135
  }
@@ -6109,7 +6141,8 @@ function decodeMsmFull(frame) {
6109
6141
  messageType: type,
6110
6142
  epochMs,
6111
6143
  system: sys,
6112
- observations
6144
+ observations,
6145
+ ...compact ? { rangeModulo1ms: true } : {}
6113
6146
  };
6114
6147
  } catch (err) {
6115
6148
  reportDecodeError("msm", err);
@@ -6263,8 +6296,8 @@ function decodeLegacyObs(frame) {
6263
6296
  }
6264
6297
  return { messageType: type, epochMs, system, observations };
6265
6298
  }
6266
- function decodeObs(frame) {
6267
- return decodeMsmFull(frame) ?? decodeLegacyObs(frame);
6299
+ function decodeObs(frame, opts = {}) {
6300
+ return decodeMsmFull(frame, opts) ?? decodeLegacyObs(frame);
6268
6301
  }
6269
6302
 
6270
6303
  // src/rtcm3/ssr.ts
@@ -14898,6 +14931,66 @@ var ZeroBaselineEngine = class {
14898
14931
  }
14899
14932
  };
14900
14933
 
14934
+ // src/positioning/msm-resolve.ts
14935
+ var LIGHT_MS = C_LIGHT / 1e3;
14936
+ var MAX_FRACTION_MISFIT = 0.25;
14937
+ function predictedRange(eph, timeMs, rx) {
14938
+ let tau = 0.075;
14939
+ for (let i = 0; i < 2; i++) {
14940
+ const tEmit = timeMs - tau * 1e3;
14941
+ const p = computeSatPosition(eph, tEmit);
14942
+ if (!Number.isFinite(p.x)) return null;
14943
+ const rho = Math.hypot(p.x - rx[0], p.y - rx[1], p.z - rx[2]);
14944
+ tau = rho / C_LIGHT;
14945
+ if (i === 1) return rho - C_LIGHT * satClockCorrection(eph, tEmit);
14946
+ }
14947
+ return null;
14948
+ }
14949
+ function moduloRange(sat) {
14950
+ for (const s of sat.signals)
14951
+ if (s.pseudorange !== void 0) return s.pseudorange;
14952
+ for (const s of sat.signals)
14953
+ if (s.phase !== void 0 && s.wavelength > 0)
14954
+ return s.phase * s.wavelength;
14955
+ return null;
14956
+ }
14957
+ function resolveMsmRanges(epoch, opts) {
14958
+ if (!epoch.rangeModulo1ms) return epoch;
14959
+ const cand = [];
14960
+ for (const sat of epoch.observations) {
14961
+ const eph = opts.ephFor(sat.prn);
14962
+ const mod = moduloRange(sat);
14963
+ if (!eph || mod === null) continue;
14964
+ const pred = predictedRange(eph, opts.timeMs, opts.rxEcef);
14965
+ if (pred === null) continue;
14966
+ cand.push({ sat, k: (pred - mod) / LIGHT_MS });
14967
+ }
14968
+ const { rangeModulo1ms: _drop, ...rest } = epoch;
14969
+ if (cand.length === 0) return { ...rest, observations: [] };
14970
+ let sx = 0;
14971
+ let sy = 0;
14972
+ for (const c of cand) {
14973
+ sx += Math.cos(2 * Math.PI * c.k);
14974
+ sy += Math.sin(2 * Math.PI * c.k);
14975
+ }
14976
+ const b = Math.atan2(sy, sx) / (2 * Math.PI);
14977
+ const observations = [];
14978
+ for (const { sat, k } of cand) {
14979
+ const n = Math.round(k - b);
14980
+ if (Math.abs(k - b - n) > MAX_FRACTION_MISFIT) continue;
14981
+ const add = n * LIGHT_MS;
14982
+ observations.push({
14983
+ ...sat,
14984
+ signals: sat.signals.map((s) => ({
14985
+ ...s,
14986
+ ...s.pseudorange !== void 0 ? { pseudorange: s.pseudorange + add } : {},
14987
+ ...s.phase !== void 0 && s.wavelength > 0 ? { phase: s.phase + add / s.wavelength } : {}
14988
+ }))
14989
+ });
14990
+ }
14991
+ return { ...rest, observations };
14992
+ }
14993
+
14901
14994
  // src/positioning/sbas.ts
14902
14995
  var P2_11 = 2 ** -11;
14903
14996
  var P2_31 = 2 ** -31;
@@ -19778,6 +19871,7 @@ function computePsdDb(centerMHz, halfSpanChips, numPoints, psdFn, f0 = 1023e3, f
19778
19871
  looksLikeRtcm2,
19779
19872
  maskRadForAzimuth,
19780
19873
  meridianArc,
19874
+ modalIntervalS,
19781
19875
  moonEcef,
19782
19876
  navTimesFromEph,
19783
19877
  nearestValidEphemeris,
@@ -19837,6 +19931,7 @@ function computePsdDb(centerMHz, halfSpanChips, numPoints, psdFn, f0 = 1023e3, f
19837
19931
  readString,
19838
19932
  reportDecodeError,
19839
19933
  resetGloFreqCache,
19934
+ resolveMsmRanges,
19840
19935
  resolvePppAmbiguities,
19841
19936
  rhumbLine,
19842
19937
  rtcm2Dgps,
package/dist/index.d.cts CHANGED
@@ -5,13 +5,14 @@ export { A as ARC_GAP_FACTOR, B as BAND_LABELS, a as BDS_SATELLITES, b as BdsSat
5
5
  export { Scale, getBdsTime, getDateFromBdsTime, getDateFromDayOfWeek, getDateFromDayOfYear, getDateFromGalTime, getDateFromGloN, getDateFromGpsData, getDateFromGpsTime, getDateFromHourCode, getDateFromJulianDate, getDateFromMJD, getDateFromMJD2000, getDateFromRINEX, getDateFromTai, getDateFromTimeOfDay, getDateFromTt, getDateFromUnixTime, getDateFromUtc, getDayOfWeek, getDayOfYear, getGalTime, getGloN4, getGloNA, getGpsLeap, getGpsTime, getHourCode, getHoursFromTimeDifference, getJulianDate, getLeap, getMJD, getMJD2000, getMinutesFromTimeDifference, getNtpTime, getRINEX, getSecondsFromTimeDifference, getTaiDate, getTimeDifference, getTimeDifferenceFromDays, getTimeDifferenceFromHours, getTimeDifferenceFromMinutes, getTimeDifferenceFromObject, getTimeDifferenceFromSeconds, getTimeOfDay, getTimeOfWeek, getTotalDaysFromTimeDifference, getTtDate, getUnixTime, getUtcDate, getWeekNumber, getWeekOfYear } from './time.cjs';
6
6
  export { deg2dms, deg2rad, euclidean3D, geodeticToGeohash, geodeticToMaidenhead, geodeticToUtm, greatCircleMidpoint, horizonDistance, meridianArc, rad2deg, rhumbLine, vincenty, vincentyDirect } from './coordinates.cjs';
7
7
  export { c as clampUnit, e as ecefToGeodetic, g as geodeticToEcef, a as getAer, b as getEnuDifference } from './ecef-CF0uAysr.cjs';
8
- export { BiasRecord, BiasSinex, CompactEpoch, CrxField, DiffState, EMPTY_WARNINGS, Nav4Input, RinexWarning, RinexWarnings, WarningAccumulator, WarningSeverity, WriteCrxOptions, biasMetres, createGzipLineSink, crxDecompress, crxRepair, findSatBias, fmtD, fmtF, hdrLine, padL, padR, parseBiasSinex, parseCrxDataLine, stationHeaderLines, writeCrx, writeModernObsBlob, writeRinex2ObsBlob, writeRinex4ObsBlob, writeRinexNav, writeRinexNav4, writeRinexObsBlob } from './rinex.cjs';
8
+ export { BiasRecord, BiasSinex, CompactEpoch, CrxField, DiffState, EMPTY_WARNINGS, Nav4Input, RinexWarning, RinexWarnings, WarningAccumulator, WarningSeverity, WriteCrxOptions, biasMetres, createGzipLineSink, crxDecompress, crxRepair, findSatBias, fmtD, fmtF, hdrLine, modalIntervalS, padL, padR, parseBiasSinex, parseCrxDataLine, stationHeaderLines, writeCrx, writeModernObsBlob, writeRinex2ObsBlob, writeRinex4ObsBlob, writeRinexNav, writeRinexNav4, writeRinexObsBlob } from './rinex.cjs';
9
9
  export { E as EpochSummary, P as ParseOptions, R as RinexHeader, a as RinexResult, b as RinexStats, S as SYSTEM_ORDER, c as SatObsCallback, p as parseRinexStream, s as systemCmp, d as systemName } from './parser-JPjjFgeP.cjs';
10
10
  export { C as CnavEphemeris, E as Ephemeris, G as GlonassEphemeris, K as KeplerEphemeris, N as NavHeader, a as NavResult, R as RinexCnavEphemeris, p as parseNavFile } from './nav-DImXUdbp.cjs';
11
11
  export { C as ClkFile, I as IonexGrid, S as Sp3File, a as Sp3Sample, c as clkBias, p as parseClk, b as parseIonex, d as parseSp3, s as sp3Position } from './clk-DGVBGRzA.cjs';
12
12
  export { RTCM2_MESSAGE_NAMES, Rtcm2Correction, Rtcm2Decoder, Rtcm2Frame, Rtcm2ObsRecord, Rtcm2Station, looksLikeRtcm2, rtcm2Dgps, rtcm2Observation, rtcm2Station, rtcm2Text, rtcm2Time } from './rtcm2.cjs';
13
13
  export { B as BitReader, E as EphemerisInfo, R as Rtcm3DebugHandler, a as Rtcm3Decoder, b as Rtcm3Frame, d as decodeEphemeris, r as readString, c as reportDecodeError, s as setRtcm3DebugHandler } from './ephemeris-BAnBLLB9.cjs';
14
- export { IgsSsrIonoLayer, IgsSsrMessage, MessageTypeStats, ObsEpoch, ObsSatObs, ObsSignal, RTCM3_MESSAGE_NAMES, SatCn0, SignalCn0, SsrCodeBias, SsrKind, SsrMessage, SsrPhaseBias, SsrSatCorrection, StationMeta, StreamStats, SystemParams, SystemParamsMessage, createStationMeta, createStreamStats, decodeIgsSsr, decodeLegacyObs, decodeMsmFull, decodeObs, decodeSsr, decodeSystemParams, isSsrMessage, obsEpochToDate, resetGloFreqCache, rtcm3Constellation, setGloFreqNumber, updateStationMeta, updateStreamStats } from './rtcm3.cjs';
14
+ export { IgsSsrIonoLayer, IgsSsrMessage, MessageTypeStats, RTCM3_MESSAGE_NAMES, SatCn0, SignalCn0, SsrCodeBias, SsrKind, SsrMessage, SsrPhaseBias, SsrSatCorrection, StationMeta, StreamStats, SystemParams, SystemParamsMessage, createStationMeta, createStreamStats, decodeIgsSsr, decodeLegacyObs, decodeObs, decodeSsr, decodeSystemParams, isSsrMessage, rtcm3Constellation, updateStationMeta, updateStreamStats } from './rtcm3.cjs';
15
+ export { O as ObsDecodeOptions, a as ObsEpoch, b as ObsSatObs, c as ObsSignal, d as decodeMsmFull, o as obsEpochToDate, r as resetGloFreqCache, s as setGloFreqNumber } from './msm-DWtoTvx2.cjs';
15
16
  export { UbxCnavResult, UbxFrame, UbxIonoUtcResult, UbxMeasurement, UbxNavOptions, UbxNavResult, UbxParseResult, UbxPvtResult, UbxRawNavOptions, UbxRawNavResult, UbxRawxEpoch, parseUbxCnav, parseUbxIonoUtc, parseUbxNav, parseUbxPvt, parseUbxRawNav, parseUbxRawx, ubxFrames } from './ubx.cjs';
16
17
  export { DfmcCensus, DfmcMessageCb, GeoL5Result, SBAS_L5_MT_NAMES, SBAS_L5_PREAMBLE_UW, SbasMessageCb, SbfBdsNavResult, SbfCnavEphemeris, SbfCnavResult, SbfGalEphemeris, SbfGalNavResult, SbfGeoL5Result, SbfGeoNavResult, SbfGloNavResult, SbfGpsNavResult, SbfHasMessage, SbfHasResult, SbfIonoUtcResult, SbfMeasEpoch, SbfMeasurement, SbfNavCounts, SbfNavicResult, SbfNavigation, SbfParseResult, SbfPvt, SbfPvtResult, SbfReceiverSetup, decodeSbfNavigation, extractSbfNavicSubframe, feedGeoBlock, feedGeoL5Block, feedNavicBlock, isSbasL1Preamble, isSbasL5Correction, parseSbfBdsNav, parseSbfCnav, parseSbfGalNav, parseSbfGeoL5, parseSbfGeoNav, parseSbfGloNav, parseSbfGpsNav, parseSbfHas, parseSbfIonoUtc, parseSbfMeas, parseSbfNavic, parseSbfPvt, parseSbfReceiverSetup, sbasL5MessageName, sbasL5MessageType, sbfCrc16, scanSbfFrames } from './sbf.cjs';
17
18
  export { NovatelEpoch, NovatelMeasurement, NovatelNavResult, NovatelParseResult, NovatelPvtResult, OEM4_HLEN, Oem4Frame, crc32, oem4Frames, parseNovatelNav, parseNovatelPvt, parseNovatelRange } from './novatel.cjs';
@@ -19,7 +20,7 @@ export { TrimbleEpoch, TrimbleFrame, TrimbleMeasurement, TrimbleNavResult, Trimb
19
20
  export { BinexEpoch, BinexMeasurement, BinexParseResult, BinexRecord, binexCrc16, binexCrc32, binexCsum8, binexRecords, decodeBinexEph, getBnxi, parseBinex } from './binex.cjs';
20
21
  export { AllPositionsData, AlmanacPosition, DopValues, EPHEMERIS_VALIDITY_MS, EpochSkyData, SatAzEl, SatPoint, SatPosition, VisibilityPass, VisibilityResult, almanacEpochMs, almanacSatPosition, computeAllPositions, computeDop, computeLiveSkyPositions, computeSatPosition, computeVisibility, computeVisibilityFromPositions, dopplerHz, ecefToAzEl, ephInfoToEphemeris, glonassAlmanacEpochMs, glonassAlmanacPosition, glonassPosition, isEphemerisValid, keplerPosition, maskRadForAzimuth, navTimesFromEph, nearestValidEphemeris, rangeRate, selectEphemeris } from './orbit.cjs';
21
22
  export { Helmert14, REFERENCE_FRAMES, ReferenceFrame, applyHelmert, dateToEpoch, transformFrame } from './frames.cjs';
22
- export { AntennaOffset, AppliedOrbitClock, ArFixedSat, ArOptions, ArResult, ArSat, CorrectionResult, Degradation, DgnssOptions, DgnssSolution, EphemerisSource, FixedPositionResult, IONO_L1_M_PER_TECU, KlobucharCoeffs, LambdaResult, NetworkFcbResult, NetworkFcbSummary, NlArc, NlFcbResult, OrbitClockCorrection, PppAntennaModel, PppArc, PppCorrectionConfig, PppCorrections, PppEngine, PppEphemerisSource, PppEpoch, PppEpochContext, PppEpochResult, PppFixState, PppOptions, PppSatObs, PppSolution, RawObservation, ReceiverBias, ReceiverClockSample, RtkAntennaConfig, RtkAntennaModel, RtkAntennaOffset, RtkEpochMeasurements, RtkFloatEngine, RtkFloatOptions, RtkFloatSolution, RtkMeasurement, RtkObsEpoch, RtkObsInput, RtkPostProcessOptions, RtkPostProcessResult, RtkReceiverAntenna, RtkTrackPoint, SatGeom, SatSample, SbasCorrectionSource, SbasIgp, SbasIonoDelay, SbasProcessor, SbasSatCorrection, Sp3EphemerisSource, SppOptions, SppSolution, TropoMapping, WlArc, WlFcbOptions, WlFcbResult, WlObs, ZeroBaselineEngine, ZeroBaselineOptions, antexFreqOfGroup, applyOrbitClock, buildPppAntenna, buildRtkAntenna, createPppCorrections, estimateNarrowlaneFcb, estimateNetworkFcbs, estimateWidelaneFcb, extractWidelaneArcs, fixPppPosition, gimSlantIonoDelayL1, gimVerticalTec, gmst, hasToOrbitClock, ionoFree, klobucharDelay, lambdaReduction, lambdaSearch, moonEcef, niellMapping, nlWavelength, postProcessRtk, rcvAntennaRangeM, resolvePppAmbiguities, satClockCorrection, sbasIonoDeg, sbasLongTermDeg, sbasProtectionLevels, solidEarthTide, solveDgnss, solvePpp, solveSpp, sunEcef, toRtkEpoch, wlWavelength } from './positioning.cjs';
23
+ export { AntennaOffset, AppliedOrbitClock, ArFixedSat, ArOptions, ArResult, ArSat, CorrectionResult, Degradation, DgnssOptions, DgnssSolution, EphemerisSource, FixedPositionResult, IONO_L1_M_PER_TECU, KlobucharCoeffs, LambdaResult, MsmResolveOptions, NetworkFcbResult, NetworkFcbSummary, NlArc, NlFcbResult, OrbitClockCorrection, PppAntennaModel, PppArc, PppCorrectionConfig, PppCorrections, PppEngine, PppEphemerisSource, PppEpoch, PppEpochContext, PppEpochResult, PppFixState, PppOptions, PppSatObs, PppSolution, RawObservation, ReceiverBias, ReceiverClockSample, RtkAntennaConfig, RtkAntennaModel, RtkAntennaOffset, RtkEpochMeasurements, RtkFloatEngine, RtkFloatOptions, RtkFloatSolution, RtkMeasurement, RtkObsEpoch, RtkObsInput, RtkPostProcessOptions, RtkPostProcessResult, RtkReceiverAntenna, RtkTrackPoint, SatGeom, SatSample, SbasCorrectionSource, SbasIgp, SbasIonoDelay, SbasProcessor, SbasSatCorrection, Sp3EphemerisSource, SppOptions, SppSolution, TropoMapping, WlArc, WlFcbOptions, WlFcbResult, WlObs, ZeroBaselineEngine, ZeroBaselineOptions, antexFreqOfGroup, applyOrbitClock, buildPppAntenna, buildRtkAntenna, createPppCorrections, estimateNarrowlaneFcb, estimateNetworkFcbs, estimateWidelaneFcb, extractWidelaneArcs, fixPppPosition, gimSlantIonoDelayL1, gimVerticalTec, gmst, hasToOrbitClock, ionoFree, klobucharDelay, lambdaReduction, lambdaSearch, moonEcef, niellMapping, nlWavelength, postProcessRtk, rcvAntennaRangeM, resolveMsmRanges, resolvePppAmbiguities, satClockCorrection, sbasIonoDeg, sbasLongTermDeg, sbasProtectionLevels, solidEarthTide, solveDgnss, solvePpp, solveSpp, sunEcef, toRtkEpoch, wlWavelength } from './positioning.cjs';
23
24
  export { NtripCaster, NtripConnectionInfo, NtripNetwork, NtripStream, NtripStreamConnection, NtripVersion, Sourcetable, SourcetableEntry, connectToMountpoint, fetchSourcetable, parseSourcetable } from './ntrip.cjs';
24
25
  export { CompleteSatSignal, CompleteSignalStats, CompletenessAccumulator, CompletenessResult, CycleSlipAccumulator, CycleSlipEvent, CycleSlipResult, CycleSlipSignalStats, IonoAccumulator, IonoDcbResult, IonoPoint, IonoRatePoint, IonoRateSeries, IonoResult, IonoSeries, MultipathAccumulator, MultipathPoint, MultipathResult, MultipathSeries, MultipathSignalStat, QualityResult, SatDcbMap, analyzeQuality, applyIonoDcb, computeIonoRate, detrendIonoArcs, parseSinexBiasDcb } from './analysis.cjs';
25
26
  export { AntennaEntry, AntexFile, FrequencyData, frequencyLabel, parseAntex } from './antex.cjs';
package/dist/index.d.ts CHANGED
@@ -5,13 +5,14 @@ export { A as ARC_GAP_FACTOR, B as BAND_LABELS, a as BDS_SATELLITES, b as BdsSat
5
5
  export { Scale, getBdsTime, getDateFromBdsTime, getDateFromDayOfWeek, getDateFromDayOfYear, getDateFromGalTime, getDateFromGloN, getDateFromGpsData, getDateFromGpsTime, getDateFromHourCode, getDateFromJulianDate, getDateFromMJD, getDateFromMJD2000, getDateFromRINEX, getDateFromTai, getDateFromTimeOfDay, getDateFromTt, getDateFromUnixTime, getDateFromUtc, getDayOfWeek, getDayOfYear, getGalTime, getGloN4, getGloNA, getGpsLeap, getGpsTime, getHourCode, getHoursFromTimeDifference, getJulianDate, getLeap, getMJD, getMJD2000, getMinutesFromTimeDifference, getNtpTime, getRINEX, getSecondsFromTimeDifference, getTaiDate, getTimeDifference, getTimeDifferenceFromDays, getTimeDifferenceFromHours, getTimeDifferenceFromMinutes, getTimeDifferenceFromObject, getTimeDifferenceFromSeconds, getTimeOfDay, getTimeOfWeek, getTotalDaysFromTimeDifference, getTtDate, getUnixTime, getUtcDate, getWeekNumber, getWeekOfYear } from './time.js';
6
6
  export { deg2dms, deg2rad, euclidean3D, geodeticToGeohash, geodeticToMaidenhead, geodeticToUtm, greatCircleMidpoint, horizonDistance, meridianArc, rad2deg, rhumbLine, vincenty, vincentyDirect } from './coordinates.js';
7
7
  export { c as clampUnit, e as ecefToGeodetic, g as geodeticToEcef, a as getAer, b as getEnuDifference } from './ecef-CF0uAysr.js';
8
- export { BiasRecord, BiasSinex, CompactEpoch, CrxField, DiffState, EMPTY_WARNINGS, Nav4Input, RinexWarning, RinexWarnings, WarningAccumulator, WarningSeverity, WriteCrxOptions, biasMetres, createGzipLineSink, crxDecompress, crxRepair, findSatBias, fmtD, fmtF, hdrLine, padL, padR, parseBiasSinex, parseCrxDataLine, stationHeaderLines, writeCrx, writeModernObsBlob, writeRinex2ObsBlob, writeRinex4ObsBlob, writeRinexNav, writeRinexNav4, writeRinexObsBlob } from './rinex.js';
8
+ export { BiasRecord, BiasSinex, CompactEpoch, CrxField, DiffState, EMPTY_WARNINGS, Nav4Input, RinexWarning, RinexWarnings, WarningAccumulator, WarningSeverity, WriteCrxOptions, biasMetres, createGzipLineSink, crxDecompress, crxRepair, findSatBias, fmtD, fmtF, hdrLine, modalIntervalS, padL, padR, parseBiasSinex, parseCrxDataLine, stationHeaderLines, writeCrx, writeModernObsBlob, writeRinex2ObsBlob, writeRinex4ObsBlob, writeRinexNav, writeRinexNav4, writeRinexObsBlob } from './rinex.js';
9
9
  export { E as EpochSummary, P as ParseOptions, R as RinexHeader, a as RinexResult, b as RinexStats, S as SYSTEM_ORDER, c as SatObsCallback, p as parseRinexStream, s as systemCmp, d as systemName } from './parser-JPjjFgeP.js';
10
10
  export { C as CnavEphemeris, E as Ephemeris, G as GlonassEphemeris, K as KeplerEphemeris, N as NavHeader, a as NavResult, R as RinexCnavEphemeris, p as parseNavFile } from './nav-DImXUdbp.js';
11
11
  export { C as ClkFile, I as IonexGrid, S as Sp3File, a as Sp3Sample, c as clkBias, p as parseClk, b as parseIonex, d as parseSp3, s as sp3Position } from './clk-DGVBGRzA.js';
12
12
  export { RTCM2_MESSAGE_NAMES, Rtcm2Correction, Rtcm2Decoder, Rtcm2Frame, Rtcm2ObsRecord, Rtcm2Station, looksLikeRtcm2, rtcm2Dgps, rtcm2Observation, rtcm2Station, rtcm2Text, rtcm2Time } from './rtcm2.js';
13
13
  export { B as BitReader, E as EphemerisInfo, R as Rtcm3DebugHandler, a as Rtcm3Decoder, b as Rtcm3Frame, d as decodeEphemeris, r as readString, c as reportDecodeError, s as setRtcm3DebugHandler } from './ephemeris-BAnBLLB9.js';
14
- export { IgsSsrIonoLayer, IgsSsrMessage, MessageTypeStats, ObsEpoch, ObsSatObs, ObsSignal, RTCM3_MESSAGE_NAMES, SatCn0, SignalCn0, SsrCodeBias, SsrKind, SsrMessage, SsrPhaseBias, SsrSatCorrection, StationMeta, StreamStats, SystemParams, SystemParamsMessage, createStationMeta, createStreamStats, decodeIgsSsr, decodeLegacyObs, decodeMsmFull, decodeObs, decodeSsr, decodeSystemParams, isSsrMessage, obsEpochToDate, resetGloFreqCache, rtcm3Constellation, setGloFreqNumber, updateStationMeta, updateStreamStats } from './rtcm3.js';
14
+ export { IgsSsrIonoLayer, IgsSsrMessage, MessageTypeStats, RTCM3_MESSAGE_NAMES, SatCn0, SignalCn0, SsrCodeBias, SsrKind, SsrMessage, SsrPhaseBias, SsrSatCorrection, StationMeta, StreamStats, SystemParams, SystemParamsMessage, createStationMeta, createStreamStats, decodeIgsSsr, decodeLegacyObs, decodeObs, decodeSsr, decodeSystemParams, isSsrMessage, rtcm3Constellation, updateStationMeta, updateStreamStats } from './rtcm3.js';
15
+ export { O as ObsDecodeOptions, a as ObsEpoch, b as ObsSatObs, c as ObsSignal, d as decodeMsmFull, o as obsEpochToDate, r as resetGloFreqCache, s as setGloFreqNumber } from './msm-CcQJV3PC.js';
15
16
  export { UbxCnavResult, UbxFrame, UbxIonoUtcResult, UbxMeasurement, UbxNavOptions, UbxNavResult, UbxParseResult, UbxPvtResult, UbxRawNavOptions, UbxRawNavResult, UbxRawxEpoch, parseUbxCnav, parseUbxIonoUtc, parseUbxNav, parseUbxPvt, parseUbxRawNav, parseUbxRawx, ubxFrames } from './ubx.js';
16
17
  export { DfmcCensus, DfmcMessageCb, GeoL5Result, SBAS_L5_MT_NAMES, SBAS_L5_PREAMBLE_UW, SbasMessageCb, SbfBdsNavResult, SbfCnavEphemeris, SbfCnavResult, SbfGalEphemeris, SbfGalNavResult, SbfGeoL5Result, SbfGeoNavResult, SbfGloNavResult, SbfGpsNavResult, SbfHasMessage, SbfHasResult, SbfIonoUtcResult, SbfMeasEpoch, SbfMeasurement, SbfNavCounts, SbfNavicResult, SbfNavigation, SbfParseResult, SbfPvt, SbfPvtResult, SbfReceiverSetup, decodeSbfNavigation, extractSbfNavicSubframe, feedGeoBlock, feedGeoL5Block, feedNavicBlock, isSbasL1Preamble, isSbasL5Correction, parseSbfBdsNav, parseSbfCnav, parseSbfGalNav, parseSbfGeoL5, parseSbfGeoNav, parseSbfGloNav, parseSbfGpsNav, parseSbfHas, parseSbfIonoUtc, parseSbfMeas, parseSbfNavic, parseSbfPvt, parseSbfReceiverSetup, sbasL5MessageName, sbasL5MessageType, sbfCrc16, scanSbfFrames } from './sbf.js';
17
18
  export { NovatelEpoch, NovatelMeasurement, NovatelNavResult, NovatelParseResult, NovatelPvtResult, OEM4_HLEN, Oem4Frame, crc32, oem4Frames, parseNovatelNav, parseNovatelPvt, parseNovatelRange } from './novatel.js';
@@ -19,7 +20,7 @@ export { TrimbleEpoch, TrimbleFrame, TrimbleMeasurement, TrimbleNavResult, Trimb
19
20
  export { BinexEpoch, BinexMeasurement, BinexParseResult, BinexRecord, binexCrc16, binexCrc32, binexCsum8, binexRecords, decodeBinexEph, getBnxi, parseBinex } from './binex.js';
20
21
  export { AllPositionsData, AlmanacPosition, DopValues, EPHEMERIS_VALIDITY_MS, EpochSkyData, SatAzEl, SatPoint, SatPosition, VisibilityPass, VisibilityResult, almanacEpochMs, almanacSatPosition, computeAllPositions, computeDop, computeLiveSkyPositions, computeSatPosition, computeVisibility, computeVisibilityFromPositions, dopplerHz, ecefToAzEl, ephInfoToEphemeris, glonassAlmanacEpochMs, glonassAlmanacPosition, glonassPosition, isEphemerisValid, keplerPosition, maskRadForAzimuth, navTimesFromEph, nearestValidEphemeris, rangeRate, selectEphemeris } from './orbit.js';
21
22
  export { Helmert14, REFERENCE_FRAMES, ReferenceFrame, applyHelmert, dateToEpoch, transformFrame } from './frames.js';
22
- export { AntennaOffset, AppliedOrbitClock, ArFixedSat, ArOptions, ArResult, ArSat, CorrectionResult, Degradation, DgnssOptions, DgnssSolution, EphemerisSource, FixedPositionResult, IONO_L1_M_PER_TECU, KlobucharCoeffs, LambdaResult, NetworkFcbResult, NetworkFcbSummary, NlArc, NlFcbResult, OrbitClockCorrection, PppAntennaModel, PppArc, PppCorrectionConfig, PppCorrections, PppEngine, PppEphemerisSource, PppEpoch, PppEpochContext, PppEpochResult, PppFixState, PppOptions, PppSatObs, PppSolution, RawObservation, ReceiverBias, ReceiverClockSample, RtkAntennaConfig, RtkAntennaModel, RtkAntennaOffset, RtkEpochMeasurements, RtkFloatEngine, RtkFloatOptions, RtkFloatSolution, RtkMeasurement, RtkObsEpoch, RtkObsInput, RtkPostProcessOptions, RtkPostProcessResult, RtkReceiverAntenna, RtkTrackPoint, SatGeom, SatSample, SbasCorrectionSource, SbasIgp, SbasIonoDelay, SbasProcessor, SbasSatCorrection, Sp3EphemerisSource, SppOptions, SppSolution, TropoMapping, WlArc, WlFcbOptions, WlFcbResult, WlObs, ZeroBaselineEngine, ZeroBaselineOptions, antexFreqOfGroup, applyOrbitClock, buildPppAntenna, buildRtkAntenna, createPppCorrections, estimateNarrowlaneFcb, estimateNetworkFcbs, estimateWidelaneFcb, extractWidelaneArcs, fixPppPosition, gimSlantIonoDelayL1, gimVerticalTec, gmst, hasToOrbitClock, ionoFree, klobucharDelay, lambdaReduction, lambdaSearch, moonEcef, niellMapping, nlWavelength, postProcessRtk, rcvAntennaRangeM, resolvePppAmbiguities, satClockCorrection, sbasIonoDeg, sbasLongTermDeg, sbasProtectionLevels, solidEarthTide, solveDgnss, solvePpp, solveSpp, sunEcef, toRtkEpoch, wlWavelength } from './positioning.js';
23
+ export { AntennaOffset, AppliedOrbitClock, ArFixedSat, ArOptions, ArResult, ArSat, CorrectionResult, Degradation, DgnssOptions, DgnssSolution, EphemerisSource, FixedPositionResult, IONO_L1_M_PER_TECU, KlobucharCoeffs, LambdaResult, MsmResolveOptions, NetworkFcbResult, NetworkFcbSummary, NlArc, NlFcbResult, OrbitClockCorrection, PppAntennaModel, PppArc, PppCorrectionConfig, PppCorrections, PppEngine, PppEphemerisSource, PppEpoch, PppEpochContext, PppEpochResult, PppFixState, PppOptions, PppSatObs, PppSolution, RawObservation, ReceiverBias, ReceiverClockSample, RtkAntennaConfig, RtkAntennaModel, RtkAntennaOffset, RtkEpochMeasurements, RtkFloatEngine, RtkFloatOptions, RtkFloatSolution, RtkMeasurement, RtkObsEpoch, RtkObsInput, RtkPostProcessOptions, RtkPostProcessResult, RtkReceiverAntenna, RtkTrackPoint, SatGeom, SatSample, SbasCorrectionSource, SbasIgp, SbasIonoDelay, SbasProcessor, SbasSatCorrection, Sp3EphemerisSource, SppOptions, SppSolution, TropoMapping, WlArc, WlFcbOptions, WlFcbResult, WlObs, ZeroBaselineEngine, ZeroBaselineOptions, antexFreqOfGroup, applyOrbitClock, buildPppAntenna, buildRtkAntenna, createPppCorrections, estimateNarrowlaneFcb, estimateNetworkFcbs, estimateWidelaneFcb, extractWidelaneArcs, fixPppPosition, gimSlantIonoDelayL1, gimVerticalTec, gmst, hasToOrbitClock, ionoFree, klobucharDelay, lambdaReduction, lambdaSearch, moonEcef, niellMapping, nlWavelength, postProcessRtk, rcvAntennaRangeM, resolveMsmRanges, resolvePppAmbiguities, satClockCorrection, sbasIonoDeg, sbasLongTermDeg, sbasProtectionLevels, solidEarthTide, solveDgnss, solvePpp, solveSpp, sunEcef, toRtkEpoch, wlWavelength } from './positioning.js';
23
24
  export { NtripCaster, NtripConnectionInfo, NtripNetwork, NtripStream, NtripStreamConnection, NtripVersion, Sourcetable, SourcetableEntry, connectToMountpoint, fetchSourcetable, parseSourcetable } from './ntrip.js';
24
25
  export { CompleteSatSignal, CompleteSignalStats, CompletenessAccumulator, CompletenessResult, CycleSlipAccumulator, CycleSlipEvent, CycleSlipResult, CycleSlipSignalStats, IonoAccumulator, IonoDcbResult, IonoPoint, IonoRatePoint, IonoRateSeries, IonoResult, IonoSeries, MultipathAccumulator, MultipathPoint, MultipathResult, MultipathSeries, MultipathSignalStat, QualityResult, SatDcbMap, analyzeQuality, applyIonoDcb, computeIonoRate, detrendIonoArcs, parseSinexBiasDcb } from './analysis.js';
25
26
  export { AntennaEntry, AntexFile, FrequencyData, frequencyLabel, parseAntex } from './antex.js';
package/dist/index.js CHANGED
@@ -77,7 +77,7 @@ import {
77
77
  setRtcm3DebugHandler,
78
78
  updateStationMeta,
79
79
  updateStreamStats
80
- } from "./chunk-7GNRNKBR.js";
80
+ } from "./chunk-N6GQUHM4.js";
81
81
  import {
82
82
  parseUbxCnav,
83
83
  parseUbxIonoUtc,
@@ -201,6 +201,7 @@ import {
201
201
  nlWavelength,
202
202
  postProcessRtk,
203
203
  rcvAntennaRangeM,
204
+ resolveMsmRanges,
204
205
  resolvePppAmbiguities,
205
206
  satClockCorrection,
206
207
  sbasIonoDeg,
@@ -213,7 +214,7 @@ import {
213
214
  sunEcef,
214
215
  toRtkEpoch,
215
216
  wlWavelength
216
- } from "./chunk-NOGA5KD7.js";
217
+ } from "./chunk-K3GLUWZI.js";
217
218
  import "./chunk-WQX354KD.js";
218
219
  import {
219
220
  EPHEMERIS_VALIDITY_MS,
@@ -337,6 +338,7 @@ import {
337
338
  fmtD,
338
339
  fmtF,
339
340
  hdrLine,
341
+ modalIntervalS,
340
342
  padL,
341
343
  padR,
342
344
  parseBiasSinex,
@@ -350,7 +352,7 @@ import {
350
352
  writeRinexNav,
351
353
  writeRinexNav4,
352
354
  writeRinexObsBlob
353
- } from "./chunk-6SWJTN6H.js";
355
+ } from "./chunk-56HM5B6T.js";
354
356
  import {
355
357
  SYSTEM_ORDER,
356
358
  crxDecompress,
@@ -646,6 +648,7 @@ export {
646
648
  looksLikeRtcm2,
647
649
  maskRadForAzimuth,
648
650
  meridianArc,
651
+ modalIntervalS,
649
652
  moonEcef,
650
653
  navTimesFromEph,
651
654
  nearestValidEphemeris,
@@ -705,6 +708,7 @@ export {
705
708
  readString,
706
709
  reportDecodeError,
707
710
  resetGloFreqCache,
711
+ resolveMsmRanges,
708
712
  resolvePppAmbiguities,
709
713
  rhumbLine,
710
714
  rtcm2Dgps,
@@ -0,0 +1,108 @@
1
+ import { b as Rtcm3Frame } from './ephemeris-BAnBLLB9.js';
2
+
3
+ /**
4
+ * Full RTCM3 MSM decoder — extracts pseudorange, carrier phase,
5
+ * Doppler, and C/N0 for every satellite × signal cell.
6
+ *
7
+ * Reference: BNC 2.13.4 RTCM3Decoder.cpp (BKG), RTKLIB rtcm3.c and
8
+ * RTCM 10403.3 §3.5.
9
+ *
10
+ * MSM4–7 carry full observations. MSM1–3 (compact: MSM1 code, MSM2 phase,
11
+ * MSM3 both; no C/N0, no Doppler) carry each satellite's rough range only
12
+ * modulo 1 ms (DF398, no DF397 integer milliseconds): their epochs come back
13
+ * with `rangeModulo1ms` set, ranges complete except for a whole number of
14
+ * light-milliseconds per satellite — see `resolveMsmRanges` (positioning).
15
+ */
16
+
17
+ /** Single signal observation for one satellite */
18
+ interface ObsSignal {
19
+ /** RINEX 2-char obs code, e.g. "1C", "5X" */
20
+ rinexCode: string;
21
+ /** Pseudorange in meters (undefined if invalid) */
22
+ pseudorange?: number;
23
+ /** Carrier phase in cycles (undefined if invalid) */
24
+ phase?: number;
25
+ /** Doppler in Hz (undefined if invalid) */
26
+ doppler?: number;
27
+ /** Signal-to-noise ratio in dB-Hz */
28
+ cn0?: number;
29
+ /** Lock time in seconds */
30
+ lockTime?: number;
31
+ /** Half-cycle ambiguity indicator */
32
+ halfCycle?: boolean;
33
+ /** Wavelength used (meters) — needed for RINEX phase */
34
+ wavelength: number;
35
+ }
36
+ /** All observations for one satellite in one epoch */
37
+ interface ObsSatObs {
38
+ /** PRN string, e.g. "G01", "R15", "E04" */
39
+ prn: string;
40
+ /** System letter: G, R, E, C, J, I, S */
41
+ system: string;
42
+ /** Signal observations */
43
+ signals: ObsSignal[];
44
+ }
45
+ /**
46
+ * One decoded observation epoch. Originally the MSM4–7 output shape, now the
47
+ * neutral shape every RTCM3 obs source fills: MSM (`decodeMsmFull`), legacy
48
+ * 1001–1012 (`decodeLegacyObs`), via the `decodeObs` dispatcher.
49
+ */
50
+ interface ObsEpoch {
51
+ /** Message type (1074, 1077, etc.) */
52
+ messageType: number;
53
+ /** Epoch time as GPS milliseconds of week (or GLONASS day-of-week ms, BDS SOW) */
54
+ epochMs: number;
55
+ /** System letter */
56
+ system: string;
57
+ /** Observations per satellite */
58
+ observations: ObsSatObs[];
59
+ /**
60
+ * Set for MSM1–3: every pseudorange and phase is short by an unknown whole
61
+ * number of light-milliseconds (~299.79 km) per satellite. Resolve with
62
+ * `resolveMsmRanges` before using the ranges.
63
+ */
64
+ rangeModulo1ms?: true;
65
+ }
66
+ /** Options for the RTCM3 observation decoders. */
67
+ interface ObsDecodeOptions {
68
+ /**
69
+ * Also decode compact MSM1–3. Their epochs carry `rangeModulo1ms`: every
70
+ * range is short by whole light-milliseconds until `resolveMsmRanges`
71
+ * completes it, so a consumer must opt in (default false → null, as
72
+ * before).
73
+ */
74
+ compactMsm?: boolean;
75
+ }
76
+ /**
77
+ * Decode a single RTCM3 MSM frame into observations: MSM4–7, and MSM1–3
78
+ * with `opts.compactMsm` (flagged `rangeModulo1ms`). Null otherwise.
79
+ */
80
+ declare function decodeMsmFull(frame: Rtcm3Frame, opts?: ObsDecodeOptions): ObsEpoch | null;
81
+ /**
82
+ * Convert an observation epoch timestamp to a Date.
83
+ * For GPS/Galileo/BDS/QZSS: epochMs is ms of GPS week.
84
+ * For GLONASS: epochMs is day-of-week × 86400000 + ms of day (UTC+3).
85
+ *
86
+ * Requires an approximate reference time to resolve the current week.
87
+ */
88
+ /**
89
+ * NOTE: returns a GPS-scale Date — the clock-face convention used by
90
+ * the RINEX parser and every consumer of epoch milliseconds in this
91
+ * library (satellite propagation, SPP, RINEX epoch tags). It is NOT
92
+ * UTC: converting to UTC here put every downstream satellite position
93
+ * 18 s (the current leap-second count) off — a ±14 km per-satellite
94
+ * range error that scattered live SPP solutions by kilometres.
95
+ */
96
+ declare function obsEpochToDate(sys: string, epochMs: number, refTime?: Date): Date;
97
+ /**
98
+ * Set a GLONASS FDMA frequency number (k = -7..+13) for a slot (1-24),
99
+ * e.g. from a decoded 1020 ephemeris. MSM4/6 carry no DF419, so without
100
+ * this the wavelength — and hence carrier phase — stays unknown.
101
+ */
102
+ declare function setGloFreqNumber(slot: number, k: number): void;
103
+ /**
104
+ * Reset the GLONASS frequency number cache (e.g., when switching mountpoints).
105
+ */
106
+ declare function resetGloFreqCache(): void;
107
+
108
+ export { type ObsDecodeOptions as O, type ObsEpoch as a, type ObsSatObs as b, type ObsSignal as c, decodeMsmFull as d, obsEpochToDate as o, resetGloFreqCache as r, setGloFreqNumber as s };