diff --git a/algo/ca/TrackingChain.cxx b/algo/ca/TrackingChain.cxx index 39f3b7a7af2a235970eb3307d08e7eeac7488d80..b288a10e30f04da4295d87756ddef1aa25ee16c3 100644 --- a/algo/ca/TrackingChain.cxx +++ b/algo/ca/TrackingChain.cxx @@ -9,6 +9,8 @@ #include "TrackingChain.h" +#include "tof/Config.h" + #include <boost/filesystem.hpp> #include "CaConstants.h" @@ -74,6 +76,7 @@ void TrackingChain::Finalize() {} // void TrackingChain::PrepareInput(Input_t recoResults) { + //L_(info) << "TOF TEST: " << tof::Config::GetTofTrackingStation(0x00008036); <- access to the TOF tracking station fNofHitKeys = 0; int nHitsTot = recoResults.stsHits.NElements() + recoResults.tofHits.NElements(); L_(info) << "Tracking chain: input has " << nHitsTot << " hits"; diff --git a/algo/ca/TrackingChain.h b/algo/ca/TrackingChain.h index e5dcaccec3154cbba13c89b2a8c760e5bb41e340..3b8452a536b64a7cc875cfe82a7fd69db4e02e1c 100644 --- a/algo/ca/TrackingChain.h +++ b/algo/ca/TrackingChain.h @@ -61,6 +61,8 @@ namespace cbm::algo template<ca::EDetectorID DetID> void ReadHits(PartitionedSpan<const ca::HitTypes_t::at<DetID>> hits); + /// \brief + ca::Framework fCaFramework {}; ///< CA framework instance ca::DataManager fCaDataManager {}; ///< CA data manager diff --git a/algo/detectors/tof/Config.h b/algo/detectors/tof/Config.h index 34e69400ab5c758f66fd1b752ef7d9281c8b7a4c..4d7a4213514175cfe26d6853ce47666da2542cb7 100644 --- a/algo/detectors/tof/Config.h +++ b/algo/detectors/tof/Config.h @@ -5,6 +5,8 @@ #ifndef CBM_ALGO_TOF_CONFIG #define CBM_ALGO_TOF_CONFIG 1 +#include "CbmTofAddress.h" + #include <cstdint> namespace cbm::algo::tof @@ -18,7 +20,14 @@ namespace cbm::algo::tof class Config { public: - static uint32_t GetTofTrackingStation(const uint32_t smType, const uint32_t sm, const uint32_t rpc) + /// @brief Function to get tracking station index by the TOF address + static int32_t GetTofTrackingStation(uint32_t address) + { + return GetTofTrackingStation(CbmTofAddress::GetSmType(address), CbmTofAddress::GetSmId(address), + CbmTofAddress::GetRpcId(address)); + } + + static int32_t GetTofTrackingStation(const uint32_t smType, const uint32_t sm, const uint32_t rpc) { const uint8_t numSmTypes = 10; const uint8_t numRpc[numSmTypes] = {5, 3, 5, 1, 1, 1, 2, 2, 1, 2}; @@ -31,9 +40,9 @@ namespace cbm::algo::tof {0, 0, 0, 0, 0}, {0, 0, 0, 0, 0}, {1, 1, 0, 0, 0}, + {1, 1, 0, 0, 0}, {0, 0, 0, 0, 0}, - {0, 0, 0, 0, 0}, - {1, 1, 2, 2, 0}}; + {2, 2, 2, 2, 0}}; if (smType < numSmTypes) { if (sm < numSm[smType] && rpc < numRpc[smType]) return trkStation[smType][sm * numRpc[smType] + rpc]; diff --git a/algo/params/mcbm_beam_2022_05_23_nickel.ca.par b/algo/params/mcbm_beam_2022_05_23_nickel.ca.par index 065f8ac194d81e9b788d0db69665471b8b00a6df..ebe88b3ac6cb93f536e92fd3206dc9ec9e8da18f 100644 Binary files a/algo/params/mcbm_beam_2022_05_23_nickel.ca.par and b/algo/params/mcbm_beam_2022_05_23_nickel.ca.par differ