gnss-js 1.60.0 → 1.61.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.
@@ -1421,14 +1421,17 @@ var SbasProcessor = class {
1421
1421
  }
1422
1422
  }
1423
1423
  decodeMask(msg) {
1424
- const sats = [];
1424
+ const iodp = getBitU(msg, 224, 2);
1425
+ const prns = [];
1425
1426
  for (let i = 1; i <= 210; i++) {
1426
- if (getBitU(msg, 13 + i, 1)) sats.push({ prn: maskPrn(i) });
1427
+ if (getBitU(msg, 13 + i, 1)) prns.push(maskPrn(i));
1427
1428
  }
1428
- this.iodp = getBitU(msg, 224, 2);
1429
- this.sats = sats;
1429
+ if (this.iodp === iodp && this.sats.length === prns.length && this.sats.every((s, k) => s.prn === prns[k]))
1430
+ return true;
1431
+ this.iodp = iodp;
1432
+ this.sats = prns.map((prn) => ({ prn }));
1430
1433
  this.satIdx.clear();
1431
- sats.forEach((s, k) => {
1434
+ this.sats.forEach((s, k) => {
1432
1435
  if (s.prn) this.satIdx.set(s.prn, k);
1433
1436
  });
1434
1437
  return true;
@@ -1648,7 +1651,11 @@ var SbasProcessor = class {
1648
1651
  break;
1649
1652
  }
1650
1653
  }
1651
- this.ion[band] = { iodi: getBitU(msg, 22, 2), igp };
1654
+ const iodi = getBitU(msg, 22, 2);
1655
+ const cur = this.ion[band];
1656
+ if (cur && cur.iodi === iodi && cur.igp.length === igp.length && cur.igp.every((g, k) => g.lat === igp[k].lat && g.lon === igp[k].lon))
1657
+ return true;
1658
+ this.ion[band] = { iodi, igp };
1652
1659
  return true;
1653
1660
  }
1654
1661
  decodeIgpDelay(msg, week, tow) {
package/dist/index.cjs CHANGED
@@ -13631,14 +13631,17 @@ var SbasProcessor = class {
13631
13631
  }
13632
13632
  }
13633
13633
  decodeMask(msg) {
13634
- const sats = [];
13634
+ const iodp = getBitU(msg, 224, 2);
13635
+ const prns = [];
13635
13636
  for (let i = 1; i <= 210; i++) {
13636
- if (getBitU(msg, 13 + i, 1)) sats.push({ prn: maskPrn(i) });
13637
+ if (getBitU(msg, 13 + i, 1)) prns.push(maskPrn(i));
13637
13638
  }
13638
- this.iodp = getBitU(msg, 224, 2);
13639
- this.sats = sats;
13639
+ if (this.iodp === iodp && this.sats.length === prns.length && this.sats.every((s, k) => s.prn === prns[k]))
13640
+ return true;
13641
+ this.iodp = iodp;
13642
+ this.sats = prns.map((prn) => ({ prn }));
13640
13643
  this.satIdx.clear();
13641
- sats.forEach((s, k) => {
13644
+ this.sats.forEach((s, k) => {
13642
13645
  if (s.prn) this.satIdx.set(s.prn, k);
13643
13646
  });
13644
13647
  return true;
@@ -13858,7 +13861,11 @@ var SbasProcessor = class {
13858
13861
  break;
13859
13862
  }
13860
13863
  }
13861
- this.ion[band] = { iodi: getBitU(msg, 22, 2), igp };
13864
+ const iodi = getBitU(msg, 22, 2);
13865
+ const cur = this.ion[band];
13866
+ if (cur && cur.iodi === iodi && cur.igp.length === igp.length && cur.igp.every((g, k) => g.lat === igp[k].lat && g.lon === igp[k].lon))
13867
+ return true;
13868
+ this.ion[band] = { iodi, igp };
13862
13869
  return true;
13863
13870
  }
13864
13871
  decodeIgpDelay(msg, week, tow) {
package/dist/index.js CHANGED
@@ -178,7 +178,7 @@ import {
178
178
  sunEcef,
179
179
  toRtkEpoch,
180
180
  wlWavelength
181
- } from "./chunk-4WNIGDNR.js";
181
+ } from "./chunk-GWN2F3PQ.js";
182
182
  import "./chunk-WQX354KD.js";
183
183
  import {
184
184
  almanacEpochMs,
@@ -1897,14 +1897,17 @@ var SbasProcessor = class {
1897
1897
  }
1898
1898
  }
1899
1899
  decodeMask(msg) {
1900
- const sats = [];
1900
+ const iodp = getBitU(msg, 224, 2);
1901
+ const prns = [];
1901
1902
  for (let i = 1; i <= 210; i++) {
1902
- if (getBitU(msg, 13 + i, 1)) sats.push({ prn: maskPrn(i) });
1903
+ if (getBitU(msg, 13 + i, 1)) prns.push(maskPrn(i));
1903
1904
  }
1904
- this.iodp = getBitU(msg, 224, 2);
1905
- this.sats = sats;
1905
+ if (this.iodp === iodp && this.sats.length === prns.length && this.sats.every((s, k) => s.prn === prns[k]))
1906
+ return true;
1907
+ this.iodp = iodp;
1908
+ this.sats = prns.map((prn) => ({ prn }));
1906
1909
  this.satIdx.clear();
1907
- sats.forEach((s, k) => {
1910
+ this.sats.forEach((s, k) => {
1908
1911
  if (s.prn) this.satIdx.set(s.prn, k);
1909
1912
  });
1910
1913
  return true;
@@ -2124,7 +2127,11 @@ var SbasProcessor = class {
2124
2127
  break;
2125
2128
  }
2126
2129
  }
2127
- this.ion[band] = { iodi: getBitU(msg, 22, 2), igp };
2130
+ const iodi = getBitU(msg, 22, 2);
2131
+ const cur = this.ion[band];
2132
+ if (cur && cur.iodi === iodi && cur.igp.length === igp.length && cur.igp.every((g, k) => g.lat === igp[k].lat && g.lon === igp[k].lon))
2133
+ return true;
2134
+ this.ion[band] = { iodi, igp };
2128
2135
  return true;
2129
2136
  }
2130
2137
  decodeIgpDelay(msg, week, tow) {
@@ -32,7 +32,7 @@ import {
32
32
  sunEcef,
33
33
  toRtkEpoch,
34
34
  wlWavelength
35
- } from "./chunk-4WNIGDNR.js";
35
+ } from "./chunk-GWN2F3PQ.js";
36
36
  import "./chunk-WQX354KD.js";
37
37
  import "./chunk-MHGNKSSH.js";
38
38
  import "./chunk-MIIM4LDY.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gnss-js",
3
- "version": "1.60.0",
3
+ "version": "1.61.0",
4
4
  "description": "Comprehensive GNSS library for JavaScript — time scales, coordinates, RINEX parsing, RTCM3 decoding, orbit computation, and signal analysis",
5
5
  "type": "module",
6
6
  "sideEffects": false,