diff --git a/reco/L1/L1Algo/L1Algo.cxx b/reco/L1/L1Algo/L1Algo.cxx
index e1e7ed0e8b1f6834b94849fb8ef11fe52e97bfb2..765a31945a016fce18c21baf969acc1e8d647a4d 100644
--- a/reco/L1/L1Algo/L1Algo.cxx
+++ b/reco/L1/L1Algo/L1Algo.cxx
@@ -136,21 +136,22 @@ void L1Algo::ReceiveParameters(L1Parameters&& parameters)
 {
   fParameters = std::move(parameters);
 
-  //int NMvdStations = static_cast<int>(geo[ind++]);  // TODO: get rid of NMbdStations (S. Zh.)
-  int nStationsSts     = fParameters.GetNstationsActive(static_cast<L1DetectorID>(1));
   fNstationsBeforePipe = fParameters.GetNstationsActive(static_cast<L1DetectorID>(0));
-  //int NStsStations = static_cast<int>(geo[ind++]);  // TODO: get rid of NStsStations (S. Zh.)
 
-  fNfieldStations = nStationsSts + fNstationsBeforePipe;  // TODO: Provide special getter for it (S.Zharko, 12.05.2022)
-
-  if (fTrackingMode == kMcbm) { fNfieldStations = -1; }
-
-
-  LOG(info) << fParameters.ToString(3);
+  // FIXME: SZh 24.08.2022
+  //        This approach is suitable only for a case, when all the stations inside a magnetic field come right before
+  //        all the stations outside of the field!
+  fNfieldStations = std::lower_bound(fParameters.GetStations().cbegin(),
+                                     fParameters.GetStations().cbegin() + fParameters.GetNstationsActive(),
+                                     0,  // we are looking for the first zero element
+                                     [](const L1Station& s, int edge) { return bool(s.fieldStatus) > edge; })
+                    - fParameters.GetStations().cbegin();
 
   fTrackingLevel    = fParameters.GetTrackingLevel();
   fGhostSuppression = fParameters.GetGhostSuppression();
   fMomentumCutOff   = fParameters.GetMomentumCutOff();
+
+  LOG(info) << fParameters.ToString(3);
 }
 
 /// TODO: Move to L1Hit
diff --git a/reco/L1/L1Algo/L1Parameters.cxx b/reco/L1/L1Algo/L1Parameters.cxx
index ca1b313ab95edc3ccb0f7609d439b3d870ea3413..8422a5cb4693d41a65fbf4c47c73574997fe3b9d 100644
--- a/reco/L1/L1Algo/L1Parameters.cxx
+++ b/reco/L1/L1Algo/L1Parameters.cxx
@@ -161,6 +161,29 @@ void L1Parameters::CheckConsistency() const
     throw std::logic_error(msg.str());
   }
 
+  /*
+   * Check magnetic field flags of the stations
+   *
+   * In a current version of tracking there are three configurations possible to be proceeded:
+   *  A. All the stations are inside magnetic field
+   *  B. There is no magnetic field in a setup
+   *  C. All the first stations are inside magnetic field, all the last stations are outside the field
+   * In all the cases the fieldStatus flags should be sorted containing all non-zero elements in the beginning
+   * (representing stations placed into magnetic field) and all zero elements in the end of z-axis.
+   */
+  bool ifFieldStatusFlagsOk = std::is_sorted(
+    fStations.cbegin(), fStations.cbegin() + fNstationsActiveTotal,
+    [&](const L1Station& lhs, const L1Station& rhs) { return bool(lhs.fieldStatus) > bool(rhs.fieldStatus); });
+
+  if (!ifFieldStatusFlagsOk) {
+    std::stringstream msg;
+    msg << "L1Parameters: invalid object condition: L1 tracking is impossible for a given field configuration:\n";
+    for (int iSt = 0; iSt < fNstationsActiveTotal; ++iSt) {
+      msg << "- station ID:  " << iSt << ",  field status: " << fStations[iSt].fieldStatus << '\n';
+    }
+    throw std::logic_error(msg.str());
+  }
+
   /*
    * Check target position SIMD vector
    */