47 lines
1.8 KiB
C++
47 lines
1.8 KiB
C++
// Copyright (2019-2023) Paul Scherrer Institute
|
|
|
|
#ifndef JUNGFRAUJOCH_DETECTORSETUP_H
|
|
#define JUNGFRAUJOCH_DETECTORSETUP_H
|
|
|
|
#include "DetectorGeometry.h"
|
|
#include "../jungfrau/JFModuleGainCalibration.h"
|
|
|
|
class DetectorSetup {
|
|
std::string description;
|
|
DetectorGeometry geometry;
|
|
std::vector<std::string> det_modules_hostname;
|
|
std::vector<JFModuleGainCalibration> gain_calibration;
|
|
int64_t udp_interface_count = 2;
|
|
float pixel_size_um = 75.0f;
|
|
std::string sensor_material = "Si";
|
|
float sensor_thickness_um = 320.0f;
|
|
std::vector<int64_t> tx_delay;
|
|
public:
|
|
DetectorSetup(const DetectorGeometry& geom);
|
|
DetectorSetup(const DetectorGeometry& geom,
|
|
const std::string &description,
|
|
const std::vector<std::string> &det_modules_hostname);
|
|
|
|
void LoadGain(const std::vector<std::string> &filenames);
|
|
|
|
DetectorSetup& TxDelay(const std::vector<int64_t> &v);
|
|
DetectorSetup& UDPInterfaceCount(int64_t input);
|
|
DetectorSetup& SensorMaterial(const std::string &input);
|
|
DetectorSetup& SensorThickness_um(float input);
|
|
DetectorSetup& PixelSize_um(float input);
|
|
|
|
[[nodiscard]] const DetectorGeometry& GetGeometry() const;
|
|
[[nodiscard]] const std::vector<std::string>& GetDetectorModuleHostname() const;
|
|
[[nodiscard]] uint64_t GetModulesNum() const;
|
|
[[nodiscard]] std::string GetDescription() const;
|
|
[[nodiscard]] float GetPixelSize_mm() const;
|
|
[[nodiscard]] float GetSensorThickness_um() const;
|
|
[[nodiscard]] std::string GetSensorMaterial() const;
|
|
[[nodiscard]] const std::vector<JFModuleGainCalibration> &GetGainCalibration() const;
|
|
[[nodiscard]] int64_t GetUDPInterfaceCount() const;
|
|
[[nodiscard]] const std::vector<int64_t> &GetTxDelay() const; // can be empty for default
|
|
};
|
|
|
|
|
|
#endif //JUNGFRAUJOCH_DETECTORSETUP_H
|