Index: /trunk/BNC/CHANGELOG.md
===================================================================
--- /trunk/BNC/CHANGELOG.md	(revision 11213)
+++ /trunk/BNC/CHANGELOG.md	(revision 11214)
@@ -1,4 +1,5 @@
 # Changelog
 ## 2.13.9 (unreleased)
+- ADDED: **SSR QC: code biases of APC and CoM streams.** For IGS-SSR and old RTCM-SSR (not new RTCM-SSR, which carries its own satellite antenna model), the code biases of an APC stream (SSRA...) are compared with those of the CoM stream of the same solution and format (SSRC...); following the IGS SSR convention (users reduce the satellite PCOs of all frequencies by the PCO of the reference frequency) they have to be equal. With 'QC ANTEX File' the differences are compared with the PCO differences z(f) - z(ref): 15 Oct 2026 SSRA00GMV0 GPS/Galileo/BDS biases shifted by z(f) - z(ref) (residuals 2/3/14 mm, up to 0.76 m, B_IF of GPS IIIA 0.78 m), GLONASS equal. New test case ssr_qc_apc_com
 - ADDED: **SSR QC: phase bias indicators and Melbourne-Wuebbena check.** Per stream and system the SSR format, the dispersive bias and MW consistency indicators, the integer and wide-lane integer indicators per signal and the satellites with discontinuity counter changes are reported. Every 300 s the MW combination of the phase and code biases of the reference signals (wide-lane cycles) is differenced with that of each other AC; the RMS of the fractional parts about the common offset shows whether the wide-lane biases are consistent (< 0.10 cycles) as required for a PPP-AR combination. 2 Oct 2026: MW consistency indicator 1 only for CNES and NRCan, CNES vs NRCan GPS 0.14 cycles (single satellites up to 0.3), all other pairs ~0.25 cycles (random). New test case ssr_qc_phase_bias
 - CHANGED: **Combination (Kalman filter): robust clock datum.** Per satellite, the satellite-specific clock difference of each AC referred to the reference signals is compared with the median of the ACs; an offset rejected as outlier for 60 s leaves the zero-sum conditions and absorbs the difference (any number of ACs, as long as another offset of the satellite stays in), with at least 3 ACs also an offset deviating by more than 'Maximal Residuum' (at most 0.5 m) for 60 s (largest deviations first, a majority of the ACs stays in); it rejoins after a deviation below half of the threshold without rejection for 10 min. During a data gap of an AC in the datum of a satellite (or if its correction is rejected), the sum of the present offsets is kept, so that the gap does not shift the combined clock; offsets out of the datum never define it. Before, such a difference either shifted the combined clock or the corrections were rejected in every epoch (outlier lock-in), depending on when the filter was started (e.g. SHA G26 2.4 m). Changes are logged, offsets out of the datum are listed in the hourly outlier report. Start-time test (7 ACs, start 2.5 min later): GPS max. difference 2.4 m -> 0.08 m
Index: /trunk/BNC/src/bnchelp.html
===================================================================
--- /trunk/BNC/src/bnchelp.html	(revision 11213)
+++ /trunk/BNC/src/bnchelp.html	(revision 11214)
@@ -5386,4 +5386,20 @@
 </pre>
       The latest code biases of each stream are used,</li>
+    <li>the code biases of an APC stream (SSRA...) compared with those of the CoM stream of the same solution and
+      format (SSRC..., e.g. SSRA00GMV0 and SSRC00GMV0), if both are decoded, for IGS-SSR and old RTCM-SSR only (new
+      RTCM-SSR carries its own satellite antenna model, the reference point is left to the provider). For an APC
+      reference, the user reduces
+      the satellite PCOs of all frequencies by the PCO of the reference frequency (IGS SSR v1.00, section 'Satellite
+      Reference Point'), so the code biases of both streams have to be equal (differences up to 0.02 m tolerated).
+      Otherwise the RMS and the maximum difference (with satellite and signal) are reported, and with a 'QC ANTEX
+      File' the differences are compared with the PCO differences z(f) - z(ref) of the file: if they match, the APC
+      stream carries the frequency-dependent PCO differences in its code biases, which a user following the
+      convention applies twice (ionosphere-free combination of the reference signal biases z(IF) - z(ref) instead
+      of zero, e.g. 0.78 m for GPS IIIA), e.g.
+      <pre>
+  G code biases differ from those of the CoM stream SSRC00GMV0: RMS 0.227 m, max -0.510 m (G28 C2P) (32 satellites, 237 biases)
+  G code bias differences APC - CoM equal the satellite PCO differences z(f) - z(ref) of the ANTEX file (RMS of the residuals 0.002 m, 226 biases): frequency-dependent PCOs in the biases of the APC stream, applied twice by users reducing the PCOs by the PCO of the reference frequency (IGS SSR convention)
+  R code biases equal to those of the CoM stream SSRC00GMV0 (21 satellites, 63 biases)
+</pre></li>
     <li>the phase bias signals provided,</li>
     <li>the phase bias indicators: the SSR format, for IGS-SSR and old RTCM-SSR the dispersive bias consistency
Index: /trunk/BNC/src/ssrQc.cpp
===================================================================
--- /trunk/BNC/src/ssrQc.cpp	(revision 11213)
+++ /trunk/BNC/src/ssrQc.cpp	(revision 11214)
@@ -259,5 +259,6 @@
            << " completeness w.r.t. healthy broadcast ephemerides," << endl
            << "IOD matching, code and phase bias signals, phase bias indicators, Melbourne-Wuebbena consistency"
-           << " with the other ACs, yaw angle, code biases of the reference signals, clock jumps > "
+           << " with the other ACs, yaw angle, code biases of the reference signals,"
+           << " code biases of APC and CoM streams, clock jumps > "
            << MAX_CLK_JUMP << " m, largest orbit corrections, VTEC models (system V)" << endl
            << "Reference signals of the clocks: " << t_ssrRefSig::currentString().toStdString() << endl;
@@ -457,4 +458,5 @@
       storeHist(&corr, 0);
     }
+    _orbFormat[QString::fromStdString(corr._staID)] = corr._ssrFormat;
     if (!selected(corr._staID)) continue;
     QString prn = QString::fromStdString(corr._prn.toString());
@@ -979,4 +981,105 @@
       }
       deviating(compare(1, QString()), QString("the median of the other ACs (at least %1 solutions)").arg(MIN_VOTE));
+    }
+  }
+}
+
+// Code biases of an APC stream compared with the CoM stream of the same
+// solution and format (SSRA00GMV0 / SSRC00GMV0), IGS-SSR and old RTCM-SSR
+// only (new RTCM-SSR carries its own satellite antenna model, and the
+// reference point is left to the provider). Following the IGS SSR
+// convention, users of an APC stream reduce the satellite PCOs of all
+// frequencies by the PCO of the reference frequency themselves, so the code
+// biases of both streams have to be equal. Differences equal to
+// z(f) - z(ref) of the ANTEX file show frequency-dependent PCO differences in
+// the biases of the APC stream, which such users apply twice (ionosphere-free
+// combination of the reference signal biases z(IF) - z(ref) instead of 0).
+////////////////////////////////////////////////////////////////////////////
+void t_ssrQc::compareApcComBiases(const QString& staID, char sys, const bncTime& tt, QStringList& lines) {
+  const double MAX_DIFF = 0.02;  // [m] equal biases (resolution 0.01 m, slightly different epochs)
+  if (!staID.startsWith("SSRA")) {
+    return;
+  }
+  const QString comID = "SSRC" + staID.mid(4);
+  if (!_cbLast.contains(staID) || !_cbLast.contains(comID)) {
+    return;
+  }
+  // format of the latest orbit corrections (IGS-SSR: ssrUnknown)
+  if (_orbFormat.value(staID, ssrUnknown) == ssrRtcmNew || _orbFormat.value(comID, ssrUnknown) == ssrRtcmNew) {
+    return;
+  }
+  // reference frequency of the APC (IGS SSR v1.00, table 2)
+  t_frequency::type refFrq;
+  switch (sys) {
+    case 'G': refFrq = t_frequency::G1; break;
+    case 'R': refFrq = t_frequency::R1; break;
+    case 'E': refFrq = t_frequency::E1; break;
+    case 'C': refFrq = t_frequency::C2; break;
+    case 'J': refFrq = t_frequency::J1; break;
+    case 'S': refFrq = t_frequency::S1; break;
+    case 'I': refFrq = t_frequency::I5; break;
+    default: return;
+  }
+  QSet<QString> sats;
+  unsigned numBias = 0, numPco = 0;
+  double   sumSqr = 0.0, sumSqrRes = 0.0, maxDiff = 0.0;
+  QString  maxStr;
+  const QMap<QString, QMap<QString, double> >& apc = _cbLast[staID];
+  const QMap<QString, QMap<QString, double> >& com = _cbLast[comID];
+  for (auto itP = apc.constBegin(); itP != apc.constEnd(); ++itP) {
+    const QString& prn = itP.key();
+    if (prn[0].toLatin1() != sys || !com.contains(prn)) {
+      continue;
+    }
+    const QMap<QString, double>& bc = com[prn];
+    for (auto itS = itP.value().constBegin(); itS != itP.value().constEnd(); ++itS) {
+      const QString& sig = itS.key();
+      if (!bc.contains(sig) || sig.isEmpty()) {
+        continue;
+      }
+      double diff = itS.value() - bc[sig];
+      sats.insert(prn);
+      numBias++;
+      sumSqr += diff * diff;
+      if (fabs(diff) > fabs(maxDiff)) {
+        maxDiff = diff;
+        maxStr  = QString("%1 C%2").arg(prn).arg(sig);
+      }
+      if (_antex) {
+        // satCorr() at nadir 0 (PCV pattern at zenith 0 of the satellite) gives -z(f)
+        bool foundF = false, foundR = false;
+        double corrF = _antex->satCorr(prn, t_frequency::toFreq(sys, sig[0].toLatin1()), M_PI / 2.0, 0.0, foundF, tt);
+        double corrR = _antex->satCorr(prn, refFrq, M_PI / 2.0, 0.0, foundR, tt);
+        if (foundF && foundR) {
+          double res = diff - (corrR - corrF);   // expected z(f) - z(ref)
+          sumSqrRes += res * res;
+          numPco++;
+        }
+      }
+    }
+  }
+  if (numBias == 0) {
+    return;
+  }
+  double rms = sqrt(sumSqr / numBias);
+  if (fabs(maxDiff) <= MAX_DIFF) {
+    lines << QString("code biases equal to those of the CoM stream %1 (%2 satellites, %3 biases)")
+             .arg(comID).arg(sats.size()).arg(numBias);
+    return;
+  }
+  lines << QString("code biases differ from those of the CoM stream %1: RMS %2 m, max %3 m (%4) "
+                   "(%5 satellites, %6 biases)")
+           .arg(comID).arg(rms, 0, 'f', 3).arg(maxDiff, 0, 'f', 3).arg(maxStr).arg(sats.size()).arg(numBias);
+  if (numPco > 0) {
+    double rmsRes = sqrt(sumSqrRes / numPco);
+    if (rmsRes < MAX_DIFF || rmsRes < 0.2 * rms) {
+      lines << QString("code bias differences APC - CoM equal the satellite PCO differences z(f) - z(ref) of the "
+                       "ANTEX file (RMS of the residuals %1 m, %2 biases): frequency-dependent PCOs in the biases "
+                       "of the APC stream, applied twice by users reducing the PCOs by the PCO of the reference "
+                       "frequency (IGS SSR convention)").arg(rmsRes, 0, 'f', 3).arg(numPco);
+    }
+    else {
+      lines << QString("code bias differences APC - CoM not explained by the satellite PCO differences of the "
+                       "ANTEX file (RMS of the residuals %1 m, %2 biases)").arg(rmsRes, 0, 'f', 3).arg(numPco);
     }
   }
@@ -1819,4 +1922,5 @@
       }
       compareCodeBiases(staID, sys, lines);
+      compareApcComBiases(staID, sys, endTime, lines);
       if (_phaseSignals.contains(staSys)) {
         QStringList sigs = _phaseSignals[staSys].values();
Index: /trunk/BNC/src/ssrQc.h
===================================================================
--- /trunk/BNC/src/ssrQc.h	(revision 11213)
+++ /trunk/BNC/src/ssrQc.h	(revision 11214)
@@ -200,4 +200,9 @@
                  QMap<QString, double>& dcbs, const QString& onlyAC = QString(),
                  QMap<QString, int>* numVotes = 0);
+  // Code biases of an APC stream (SSRA...) compared with the CoM stream of the
+  // same solution and format (SSRC...), and with the ANTEX PCO differences;
+  // IGS-SSR and old RTCM-SSR only
+  void   compareApcComBiases(const QString& staID, char sys, const bncTime& tt, QStringList& lines);
+  QMap<QString, e_ssrFormat> _orbFormat;   // stream: SSR format of the latest orbit corrections
   QMap<QString, QMap<QString, QMap<QString, double> > > _cbLast; // stream, PRN, signal: latest code bias [m]
   bncBiasSnx*               _bsxRef;    // reference code biases (option ssrQcBiasFile)
Index: /trunk/BNC/tests/README.md
===================================================================
--- /trunk/BNC/tests/README.md	(revision 11213)
+++ /trunk/BNC/tests/README.md	(revision 11214)
@@ -158,4 +158,9 @@
   (G01 G04 G11 G23 G28 0.2-0.3 cycles, verified by hand from the decoded .ssr files), all other
   pairs ~0.25 cycles; CNE1 BeiDou phase biases with integer indicator 0.
+* `ssr_qc_apc_com`: code biases of the APC stream SSRA00GMV0 vs. the CoM stream SSRC00GMV0 (old
+  RTCM-SSR) on `data/apc_com_gmv_261015_10min.raw` (with BCEP00BKG0, 15 Oct 2026 10:00-10:10,
+  `bncraw.py slice` of the QC capture), 'QC ANTEX File' igs20.atx: the GPS/Galileo/BDS biases of
+  the APC stream are shifted by the PCO differences z(f) - z(ref) (residuals 2/3/14 mm, verified
+  by hand from the decoded .ssr files: C06 C6I -0.42 m = z(B3I) - z(B1I)), GLONASS biases equal.
 
 * `decoder_limits`: crafted, CRC-valid frames from `tools/mkcrafted.py`
Index: /trunk/BNC/tests/cases/ssr_qc_apc_com/case.json
===================================================================
--- /trunk/BNC/tests/cases/ssr_qc_apc_com/case.json	(revision 11214)
+++ /trunk/BNC/tests/cases/ssr_qc_apc_com/case.json	(revision 11214)
@@ -0,0 +1,15 @@
+{
+  "description": "31_SsrQC replay with ssrQcAntexFile: code biases of the APC stream SSRA00GMV0 vs. the CoM stream SSRC00GMV0 (15 Oct 2026, 10 min); GPS/Galileo/BDS APC biases shifted by the ANTEX PCO differences z(f) - z(ref), GLONASS equal",
+  "config": "Example_Configs/31_SsrQC.bnc",
+  "raw": "data/apc_com_gmv_261015_10min.raw",
+  "exit_code": 5,
+  "timeout": 600,
+  "args": [
+    "-key",
+    "ssrQcAntexFile",
+    "Input/igs20.atx"
+  ],
+  "outputs": [
+    "Output/*_QC.txt"
+  ]
+}
