Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions DataFormats/Detectors/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,6 @@ add_subdirectory(CPV)

if(ENABLE_UPGRADES)
add_subdirectory(Upgrades)
else()
message(STATUS "Not building dataformats for upgrades")
endif()
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,13 @@ class DetID
static constexpr ID FV0 = 13;
static constexpr ID FDD = 14;
static constexpr ID ACO = 15;
static constexpr ID First = ITS;
#ifdef ENABLE_UPGRADES
static constexpr ID IT3 = 16;
static constexpr ID Last = IT3;
#else
static constexpr ID Last = ACO; ///< if extra detectors added, update this !!!
#endif
static constexpr ID First = ITS;

static constexpr int nDetectors = Last + 1; ///< number of defined detectors

Expand Down Expand Up @@ -126,19 +131,33 @@ class DetID
ID mID = First; ///< detector ID

static constexpr const char* sDetNames[nDetectors + 1] = ///< defined detector names

#ifdef ENABLE_UPGRADES
{"ITS", "TPC", "TRD", "TOF", "PHS", "CPV", "EMC", "HMP", "MFT", "MCH", "MID", "ZDC", "FT0", "FV0", "FDD", "ACO", "IT3", nullptr};
#else
{"ITS", "TPC", "TRD", "TOF", "PHS", "CPV", "EMC", "HMP", "MFT", "MCH", "MID", "ZDC", "FT0", "FV0", "FDD", "ACO", nullptr};

#endif
// detector names, will be defined in DataSources
static constexpr std::array<mask_t, nDetectors> sMasks = ///< detectot masks
{utils::bit2Mask(ITS), utils::bit2Mask(TPC), utils::bit2Mask(TRD), utils::bit2Mask(TOF), utils::bit2Mask(PHS),
utils::bit2Mask(CPV), utils::bit2Mask(EMC), utils::bit2Mask(HMP), utils::bit2Mask(MFT), utils::bit2Mask(MCH),
utils::bit2Mask(MID), utils::bit2Mask(ZDC), utils::bit2Mask(FT0), utils::bit2Mask(FV0), utils::bit2Mask(FDD), utils::bit2Mask(ACO)};
utils::bit2Mask(MID), utils::bit2Mask(ZDC), utils::bit2Mask(FT0), utils::bit2Mask(FV0), utils::bit2Mask(FDD),
utils::bit2Mask(ACO)
#ifdef ENABLE_UPGRADES
,
utils::bit2Mask(IT3)
#endif
};

static constexpr std::array<o2h::DataOrigin, nDetectors> sOrigins = ///< detector data origins
static constexpr std::array<o2h::DataOrigin, nDetectors>
sOrigins = ///< detector data origins
{o2h::gDataOriginITS, o2h::gDataOriginTPC, o2h::gDataOriginTRD, o2h::gDataOriginTOF, o2h::gDataOriginPHS,
o2h::gDataOriginCPV, o2h::gDataOriginEMC, o2h::gDataOriginHMP, o2h::gDataOriginMFT, o2h::gDataOriginMCH,
o2h::gDataOriginMID, o2h::gDataOriginZDC, o2h::gDataOriginFT0, o2h::gDataOriginFV0, o2h::gDataOriginFDD, o2h::gDataOriginACO};
o2h::gDataOriginMID, o2h::gDataOriginZDC, o2h::gDataOriginFT0, o2h::gDataOriginFV0, o2h::gDataOriginFDD, o2h::gDataOriginACO
#ifdef ENABLE_UPGRADES
,
o2h::gDataOriginIT3
#endif
};

ClassDefNV(DetID, 1);
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,11 @@ class SimTraits
/*FT0*/ VS{ "FT0Hit" },
/*FV0*/ VS{ "FV0Hit" },
/*FDD*/ VS{ "FDDHit" },
/*ACO*/ VS{ "ACOHit" },
/*ACO*/ VS{ "ACOHit" }
#ifdef ENABLE_UPGRADES
,
/*IT3*/ VS{ "ITS3Hit" }
#endif
};
// clang-format on

Expand Down Expand Up @@ -217,6 +221,12 @@ template <>
struct DetIDToHitTypes<o2::detectors::DetID::TPC> {
using HitType = o2::tpc::HitGroup;
};
#ifdef ENABLE_UPGRADES
template <>
struct DetIDToHitTypes<o2::detectors::DetID::IT3> {
using HitType = o2::itsmft::Hit;
};
#endif

} // namespace detectors

Expand Down
4 changes: 4 additions & 0 deletions DataFormats/Detectors/Common/src/DetID.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ constexpr std::array<DetID::mask_t, DetID::nDetectors> DetID::sMasks;
constexpr DetID::ID DetID::ITS, DetID::TPC, DetID::TRD, DetID::TOF, DetID::PHS, DetID::CPV, DetID::EMC,
DetID::HMP, DetID::MFT, DetID::MCH, DetID::MID, DetID::ZDC, DetID::FT0, DetID::FV0, DetID::FDD, DetID::ACO, DetID::First, DetID::Last;

#ifdef ENABLE_UPGRADES
constexpr DetID::ID DetID::IT3;
#endif

constexpr int DetID::nDetectors;

/// detector masks from any non-alpha-num delimiter-separated list (empty if NONE is supplied)
Expand Down
3 changes: 3 additions & 0 deletions DataFormats/Headers/include/Headers/DataHeader.h
Original file line number Diff line number Diff line change
Expand Up @@ -632,6 +632,9 @@ constexpr o2::header::DataOrigin gDataOriginTOF{"TOF"};
constexpr o2::header::DataOrigin gDataOriginTPC{"TPC"};
constexpr o2::header::DataOrigin gDataOriginTRD{"TRD"};
constexpr o2::header::DataOrigin gDataOriginZDC{"ZDC"};
#ifdef ENABLE_UPGRADES
constexpr o2::header::DataOrigin gDataOriginIT3{"IT3"};
#endif

//possible data types
constexpr o2::header::DataDescription gDataDescriptionAny{"***************"};
Expand Down
6 changes: 5 additions & 1 deletion Detectors/Base/include/DetectorsBase/GeometryManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,12 @@ class GeometryManager : public TObject
static Bool_t getOriginalMatrixFromPath(const char* path, TGeoHMatrix& m);

private:
/// sensitive volume identifier composed from (det_mask<<sDetOffset)|(sensid&sSensorMask)
/// sensitive volume identifier composed from (det_mask<<sDetOffset)|(sensid&sSensorMask)
#ifdef ENABLE_UPGRADES
static constexpr UInt_t sDetOffset = 14; /// detector identifier will start from this bit
#else
static constexpr UInt_t sDetOffset = 15; /// detector identifier will start from this bit
#endif
static constexpr UInt_t sSensorMask =
(0x1 << sDetOffset) - 1; /// mask=max sensitive volumes allowed per detector (0xffff)

Expand Down
2 changes: 2 additions & 0 deletions Detectors/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,6 @@ o2_data_file(COPY Geometry DESTINATION Detectors)

if(ENABLE_UPGRADES)
add_subdirectory(Upgrades)
else()
message(STATUS "Not building detectors for upgrades")
endif()
2 changes: 2 additions & 0 deletions Detectors/Upgrades/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@
# submit itself to any jurisdiction.

message(STATUS "Building detectors for upgrades")
add_subdirectory(IT3)
add_subdirectory(PostLS4)
13 changes: 13 additions & 0 deletions Detectors/Upgrades/IT3/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Copyright CERN and copyright holders of ALICE O2. This software is distributed
# under the terms of the GNU General Public License v3 (GPL Version 3), copied
# verbatim in the file "COPYING".
#
# See http://alice-o2.web.cern.ch/license for full licensing information.
#
# In applying this license CERN does not waive the privileges and immunities
# granted to it by virtue of its status as an Intergovernmental Organization or
# submit itself to any jurisdiction.

add_subdirectory(simulation)
add_subdirectory(base)
add_subdirectory(macros)
18 changes: 18 additions & 0 deletions Detectors/Upgrades/IT3/base/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright CERN and copyright holders of ALICE O2. This software is distributed
# under the terms of the GNU General Public License v3 (GPL Version 3), copied
# verbatim in the file "COPYING".
#
# See http://alice-o2.web.cern.ch/license for full licensing information.
#
# In applying this license CERN does not waive the privileges and immunities
# granted to it by virtue of its status as an Intergovernmental Organization or
# submit itself to any jurisdiction.

o2_add_library(ITS3Base
SOURCES src/MisalignmentParameter.cxx
src/GeometryTGeo.cxx
PUBLIC_LINK_LIBRARIES O2::DetectorsBase O2::ITSMFTBase)

o2_target_root_dictionary(ITS3Base
HEADERS include/ITS3Base/GeometryTGeo.h
include/ITS3Base/MisalignmentParameter.h)
Loading