diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index 5edf5df3..28b9824d 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt @@ -42,7 +42,9 @@ ADD_LIBRARY( CommonFunctions STATIC SpotToSave.h NetworkAddressConvert.h NetworkAddressConvert.cpp grpcToJson.h jsonToGrpc.h to_fixed.h - DetectorGeometry.cpp DetectorGeometry.h DetectorModuleGeometry.cpp DetectorModuleGeometry.h) + DetectorGeometry.cpp DetectorGeometry.h + DetectorModuleGeometry.cpp DetectorModuleGeometry.h + DetectorSetup.h DetectorSetup.cpp) TARGET_LINK_LIBRARIES(CommonFunctions Compression FrameSerialize libzmq JFCalibration JFJochProtoBuf -lrt) diff --git a/common/DetectorSetup.cpp b/common/DetectorSetup.cpp new file mode 100644 index 00000000..e03b4e48 --- /dev/null +++ b/common/DetectorSetup.cpp @@ -0,0 +1,67 @@ +// Copyright (2019-2023) Paul Scherrer Institute +// SPDX-License-Identifier: GPL-3.0-or-later + +#include "DetectorSetup.h" +#include "JFJochException.h" + +DetectorSetup::DetectorSetup(const DetectorGeometry &in_geometry) + : DetectorSetup(in_geometry, "Detector", std::vector()) {} + +DetectorSetup::DetectorSetup(const DetectorGeometry &in_geometry, + const std::string &in_description, + const std::vector &in_det_modules_hostname) : + geometry(in_geometry), description(in_description), det_modules_hostname(in_det_modules_hostname) { + if (!det_modules_hostname.empty() && (geometry.GetModulesNum() != det_modules_hostname.size())) + throw JFJochException(JFJochExceptionCategory::InputParameterInvalid, + "Mismatch between number of modules in detector geometry and hostname"); +} + +const DetectorGeometry &DetectorSetup::GetGeometry() const { + return geometry; +} + +const std::vector &DetectorSetup::GetDetectorModuleHostname() const { + return det_modules_hostname; +} + +uint64_t DetectorSetup::GetModulesNum() const { + return geometry.GetModulesNum(); +} + +std::string DetectorSetup::GetDescription() const { + return description; +} + +JFJochProtoBuf::DetectorType DetectorSetup::GetDetectorType() const { + return JFJochProtoBuf::DetectorType::JUNGFRAU; +} + +float DetectorSetup::GetPixelSize_mm() const { + return PIXEL_SIZE_IN_MM; +} + +void DetectorSetup::LoadGain(const std::vector &filenames) { + if (filenames.size() != GetModulesNum()) + throw JFJochException(JFJochExceptionCategory::InputParameterInvalid, + "Mismatch in number of gain calibration files"); + for (const auto& i: filenames) + gain_calibration.emplace_back(i); +} + +const std::vector &DetectorSetup::GetGainCalibration() const { + return gain_calibration; +} + +DetectorSetup::operator JFJochProtoBuf::Detector() const { + JFJochProtoBuf::Detector ret; + ret.set_nmodules(GetModulesNum()); + ret.set_description(GetDescription()); + ret.set_pixel_size_mm(GetPixelSize_mm()); + + for (const auto& iter: det_modules_hostname) + ret.add_module_hostname(iter); + + *ret.mutable_geometry() = geometry; + ret.set_type(JFJochProtoBuf::DetectorType::JUNGFRAU); + return ret; +} \ No newline at end of file diff --git a/common/DetectorSetup.h b/common/DetectorSetup.h new file mode 100644 index 00000000..47b6c8c6 --- /dev/null +++ b/common/DetectorSetup.h @@ -0,0 +1,35 @@ +// Copyright (2019-2023) Paul Scherrer Institute +// SPDX-License-Identifier: GPL-3.0-or-later + +#ifndef JUNGFRAUJOCH_DETECTORSETUP_H +#define JUNGFRAUJOCH_DETECTORSETUP_H + +#include "DetectorGeometry.h" +#include "../jungfrau/JFModuleGainCalibration.h" + +class DetectorSetup { + std::string description; + DetectorGeometry geometry; + std::vector det_modules_hostname; + std::vector gain_calibration; +public: + DetectorSetup(const DetectorGeometry& geom); + DetectorSetup(const DetectorGeometry& geom, + const std::string &description, + const std::vector &det_modules_hostname); + + void LoadGain(const std::vector &filenames); + + [[nodiscard]] const DetectorGeometry& GetGeometry() const; + [[nodiscard]] const std::vector& GetDetectorModuleHostname() const; + [[nodiscard]] uint64_t GetModulesNum() const; + [[nodiscard]] std::string GetDescription() const; + [[nodiscard]] JFJochProtoBuf::DetectorType GetDetectorType() const; + [[nodiscard]] float GetPixelSize_mm() const; + [[nodiscard]] const std::vector &GetGainCalibration() const; + + operator JFJochProtoBuf::Detector() const; +}; + + +#endif //JUNGFRAUJOCH_DETECTORSETUP_H diff --git a/common/DiffractionExperiment.cpp b/common/DiffractionExperiment.cpp index c31b9e0a..50b5fe3e 100644 --- a/common/DiffractionExperiment.cpp +++ b/common/DiffractionExperiment.cpp @@ -34,7 +34,7 @@ DiffractionExperiment::operator JFJochProtoBuf::JungfraujochSettings() const { DiffractionExperiment::DiffractionExperiment() : DiffractionExperiment(DetectorGeometry(8, 2)) {} -DiffractionExperiment::DiffractionExperiment(const DetectorGeometry& geom) { +DiffractionExperiment::DiffractionExperiment(const DetectorSetup& det_setup) { dataset.set_photon_energy_kev(WVL_1A_IN_KEV); dataset.set_detector_distance_mm(100); dataset.mutable_scattering_vector()->set_x(0); @@ -59,7 +59,6 @@ DiffractionExperiment::DiffractionExperiment(const DetectorGeometry& geom) { internal.set_mask_chip_edges(false); internal.set_mask_module_edges(false); - internal.set_type(JFJochProtoBuf::JUNGFRAU); internal.set_preview_period_us(1000*1000); // 1s / 1 Hz internal.set_spot_finding_period_us(5*1000); // 5 ms / 200 Hz @@ -77,16 +76,13 @@ DiffractionExperiment::DiffractionExperiment(const DetectorGeometry& geom) { internal.set_storage_cells(1); internal.set_storage_cell_start(15); - Geometry(geom); + Detector(det_setup); Mode(DetectorMode::Conversion); } // setter functions -DiffractionExperiment &DiffractionExperiment::Geometry(const DetectorGeometry &input) { - check_min("Number of modules", input.GetModulesNum(), 1); - check_max("Number of modules", input.GetModulesNum(), 64); // if operating > 32M, would need to check the code anyway - internal.set_nmodules(input.GetModulesNum()); - *internal.mutable_conv_geometry() = input; +DiffractionExperiment &DiffractionExperiment::Detector(const DetectorSetup &input) { + *internal.mutable_detector() = input; return *this; } @@ -331,11 +327,6 @@ DiffractionExperiment& DiffractionExperiment::QSpacingForRadialInt_recipA(float return *this; } -DiffractionExperiment &DiffractionExperiment::DetectorType(JFJochProtoBuf::DetectorType type) { - internal.set_type(type); - return *this; -} - DiffractionExperiment &DiffractionExperiment::SetUnitCell(const JFJochProtoBuf::UnitCell &cell) { *dataset.mutable_unit_cell() = cell; return *this; @@ -618,17 +609,17 @@ bool DiffractionExperiment::IsPixelSigned() const { } int64_t DiffractionExperiment::GetDataStreamsNum() const { - return std::min(internal.ndatastreams(), internal.nmodules()); + return std::min(internal.ndatastreams(), internal.detector().nmodules()); } int64_t DiffractionExperiment::GetModulesNum(uint16_t data_stream) const { if (data_stream == TASK_NO_DATA_STREAM) - return internal.nmodules(); + return internal.detector().nmodules(); if (data_stream >= GetDataStreamsNum()) throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Non existing data stream"); - return (internal.nmodules() + (GetDataStreamsNum() - 1) - data_stream) / GetDataStreamsNum(); + return (internal.detector().nmodules() + (GetDataStreamsNum() - 1) - data_stream) / GetDataStreamsNum(); } int64_t DiffractionExperiment::GetFirstModuleOfDataStream(uint16_t data_stream) const { @@ -656,7 +647,7 @@ int64_t DiffractionExperiment::GetXPixelsNumFullImage() const { if (GetDetectorMode() != DetectorMode::Conversion) return RAW_MODULE_COLS; else - return internal.conv_geometry().width_pxl(); + return internal.detector().geometry().width_pxl(); } int64_t DiffractionExperiment::GetXPixelsNum() const { @@ -677,7 +668,7 @@ int64_t DiffractionExperiment::GetYPixelsNumFullImage() const { if (GetDetectorMode() != DetectorMode::Conversion) return RAW_MODULE_LINES * GetModulesNum(); else - return internal.conv_geometry().height_pxl(); + return internal.detector().geometry().height_pxl(); } int64_t DiffractionExperiment::GetPixel0OfModule(uint16_t module_number) const { @@ -687,7 +678,7 @@ int64_t DiffractionExperiment::GetPixel0OfModule(uint16_t module_number) const { if (GetDetectorMode() != DetectorMode::Conversion) return RAW_MODULE_SIZE * module_number; else - return internal.conv_geometry().module_geometry(module_number).pixel0(); + return internal.detector().geometry().module_geometry(module_number).pixel0(); } int64_t DiffractionExperiment::GetOverflow() const { @@ -886,7 +877,7 @@ float DiffractionExperiment::GetQSpacingForRadialInt_recipA() const { } JFJochProtoBuf::DetectorType DiffractionExperiment::GetDetectorType() const { - return internal.type(); + return internal.detector().type(); } int64_t DiffractionExperiment::GetMaxSpotCount() const { @@ -940,12 +931,12 @@ JFJochProtoBuf::DetectorConfig DiffractionExperiment::DetectorConfig(const JFJoc throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Number of FPGA boards in the receiver is less then necessary"); - if (!internal.detector_module_hostname().empty() && (internal.detector_module_hostname_size() != GetModulesNum())) + if (!internal.detector().module_hostname().empty() && (internal.detector().module_hostname_size() != GetModulesNum())) throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Inconsistent number of modules and detector module host names"); - if (!internal.detector_module_hostname().empty()) - *ret.mutable_module_hostname() = internal.detector_module_hostname(); + if (!internal.detector().module_hostname().empty()) + *ret.mutable_module_hostname() = internal.detector().module_hostname(); for (int d = 0; d < GetDataStreamsNum(); d++) { for (int module = 0; module < GetModulesNum(d); module++) { @@ -1128,7 +1119,7 @@ void DiffractionExperiment::FillMessage(StartMessage &message) const { message.sample_name = GetSampleName(); message.max_spot_count = GetMaxSpotCount(); message.pixel_mask_enabled = GetApplyPixelMaskInFPGA(); - + message.detector_description = GetDetectorDescription(); message.space_group_number = GetSpaceGroupNumber(); if (HasUnitCell()) { auto uc = GetUnitCell(); @@ -1167,9 +1158,9 @@ bool DiffractionExperiment::GetApplyPixelMaskInFPGA() const { float DiffractionExperiment::GetPixelSize_mm() const { if (GetBinning2x2()) - return PIXEL_SIZE_IN_MM * 2; + return internal.detector().pixel_size_mm() * 2; else - return PIXEL_SIZE_IN_MM; + return internal.detector().pixel_size_mm(); } DiffractionExperiment &DiffractionExperiment::Binning2x2(bool input) { @@ -1224,25 +1215,21 @@ int64_t DiffractionExperiment::GetModuleFastDirectionStep(uint16_t module_number if (module_number >= GetModulesNum()) throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Module number out of bounds"); - return internal.conv_geometry().module_geometry(module_number).fast_direction_step(); + return internal.detector().geometry().module_geometry(module_number).fast_direction_step(); } int64_t DiffractionExperiment::GetModuleSlowDirectionStep(uint16_t module_number) const { if (module_number >= GetModulesNum()) throw JFJochException(JFJochExceptionCategory::ArrayOutOfBounds, "Module number out of bounds"); - return internal.conv_geometry().module_geometry(module_number).slow_direction_step(); -} - -DiffractionExperiment &DiffractionExperiment::DetectorModuleHostname(const std::vector &input) { - if (input.empty()) - internal.mutable_detector_module_hostname()->Clear(); - else - *internal.mutable_detector_module_hostname() = {input.begin(), input.end()}; - return *this; + return internal.detector().geometry().module_geometry(module_number).slow_direction_step(); } void DiffractionExperiment::GetDetectorModuleHostname(std::vector &output) const { - for (const auto &iter: internal.detector_module_hostname()) + for (const auto &iter: internal.detector().module_hostname()) output.push_back(iter); } + +std::string DiffractionExperiment::GetDetectorDescription() const { + return internal.detector().description(); +} \ No newline at end of file diff --git a/common/DiffractionExperiment.h b/common/DiffractionExperiment.h index d6599b8f..c2cc0d94 100644 --- a/common/DiffractionExperiment.h +++ b/common/DiffractionExperiment.h @@ -17,7 +17,7 @@ #include "Definitions.h" #include "../frame_serialize/StartMessage.h" #include "../frame_serialize/EndMessage.h" -#include "DetectorGeometry.h" +#include "DetectorSetup.h" enum class DetectorMode : int { Conversion, Raw, PedestalG0, PedestalG1, PedestalG2 @@ -32,11 +32,11 @@ class DiffractionExperiment { public: // Public methods are atomic DiffractionExperiment(); - DiffractionExperiment(const DetectorGeometry& geom); + DiffractionExperiment(const DetectorSetup& geom); explicit DiffractionExperiment(const JFJochProtoBuf::JungfraujochSettings &settings); // Methods below can be chained together - DiffractionExperiment& Geometry(const DetectorGeometry &input); + DiffractionExperiment& Detector(const DetectorSetup& input); DiffractionExperiment& Mode(DetectorMode input); DiffractionExperiment& DataStreams(int64_t input); @@ -87,7 +87,6 @@ public: DiffractionExperiment& SpaceGroupNumber(int64_t input); DiffractionExperiment& StorageCells(int64_t input); DiffractionExperiment& StorageCellStart(int64_t input = 15); - DiffractionExperiment& DetectorType(JFJochProtoBuf::DetectorType type); DiffractionExperiment& SampleName(std::string input); DiffractionExperiment& ConversionOnCPU(bool input); @@ -95,7 +94,6 @@ public: DiffractionExperiment& SourceNameShort(std::string input); DiffractionExperiment& InstrumentName(std::string input); DiffractionExperiment& InstrumentNameShort(std::string input); - DiffractionExperiment& DetectorModuleHostname(const std::vector& input); DiffractionExperiment& Binning2x2(bool input); DiffractionExperiment& ApplyPixelMaskInFPGA(bool input); @@ -221,7 +219,7 @@ public: std::string GetSourceNameShort() const; std::string GetInstrumentName() const; std::string GetInstrumentNameShort() const; - + std::string GetDetectorDescription() const; void GetDetectorModuleHostname(std::vector& output) const; }; diff --git a/grpc/jfjoch.proto b/grpc/jfjoch.proto index 02c10c88..869298b7 100644 --- a/grpc/jfjoch.proto +++ b/grpc/jfjoch.proto @@ -129,17 +129,24 @@ message DetectorGeometry { repeated DetectorModuleGeometry module_geometry = 3; } +message Detector { + int64 nmodules = 1; + string description = 2; + float pixel_size_mm = 3; + repeated string module_hostname = 4; + DetectorGeometry geometry = 5; + DetectorType type = 6; +} + message InternalSettings { int64 frame_time_pedestalG1G2_us = 1; // uint64 frame_time_pedestalG2_us = 2; reserved int64 frame_time_us = 3; int64 count_time_us = 4; - int64 nmodules = 5; - int64 ndatastreams = 6; + Detector detector = 5; - repeated string detector_module_hostname = 7; - DetectorGeometry conv_geometry = 8; + int64 ndatastreams = 6; bool internal_fpga_packet_generator = 9; int64 storage_cells = 10; @@ -153,7 +160,6 @@ message InternalSettings { int64 spot_finding_period_us = 16; int64 indexing_period_us = 17; - DetectorType type = 18; DetectorMode mode = 19; bool mask_module_edges = 20; bool mask_chip_edges = 21; @@ -174,6 +180,7 @@ message InternalSettings { string source_name_short = 33; string instrument_name = 34; string instrument_name_short = 35; + } diff --git a/python/jfjoch_pb2.py b/python/jfjoch_pb2.py index ef82c8e6..7d490506 100644 --- a/python/jfjoch_pb2.py +++ b/python/jfjoch_pb2.py @@ -13,7 +13,7 @@ _sym_db = _symbol_database.Default() -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0cjfjoch.proto\x12\x0eJFJochProtoBuf\"\x07\n\x05\x45mpty\"W\n\x08UnitCell\x12\t\n\x01\x61\x18\x01 \x01(\x02\x12\t\n\x01\x62\x18\x02 \x01(\x02\x12\t\n\x01\x63\x18\x03 \x01(\x02\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x0c\n\x04\x62\x65ta\x18\x05 \x01(\x02\x12\r\n\x05gamma\x18\x06 \x01(\x02\")\n\x06Vector\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\x12\t\n\x01z\x18\x03 \x01(\x02\"|\n\x10RotationSettings\x12\x17\n\x0fstart_angle_deg\x18\x01 \x01(\x02\x12 \n\x18\x61ngle_incr_per_image_deg\x18\x02 \x01(\x02\x12-\n\rrotation_axis\x18\x03 \x01(\x0b\x32\x16.JFJochProtoBuf.Vector\"\x1c\n\x04Plot\x12\t\n\x01x\x18\x01 \x03(\x02\x12\t\n\x01y\x18\x02 \x03(\x02\"\xa5\x04\n\x0f\x44\x61tasetSettings\x12\x1a\n\x12images_per_trigger\x18\x01 \x01(\x03\x12\x10\n\x08ntrigger\x18\x02 \x01(\x03\x12\x13\n\tsummation\x18\x03 \x01(\x03H\x00\x12\x17\n\rimage_time_us\x18\x04 \x01(\x03H\x00\x12\x12\n\nbeam_x_pxl\x18\x05 \x01(\x02\x12\x12\n\nbeam_y_pxl\x18\x06 \x01(\x02\x12\x1c\n\x14\x64\x65tector_distance_mm\x18\x07 \x01(\x02\x12\x19\n\x11photon_energy_keV\x18\x08 \x01(\x02\x12\x13\n\x0b\x66ile_prefix\x18\t \x01(\t\x12\x17\n\x0f\x64\x61ta_file_count\x18\n \x01(\x03\x12\x30\n\x0b\x63ompression\x18\x0b \x01(\x0e\x32\x1b.JFJochProtoBuf.Compression\x12\x13\n\x0bsample_name\x18\x0c \x01(\t\x12\x30\n\tunit_cell\x18\r \x01(\x0b\x32\x18.JFJochProtoBuf.UnitCellH\x01\x88\x01\x01\x12\x1a\n\x12space_group_number\x18\x0e \x01(\x03\x12\x36\n\x11scattering_vector\x18\x0f \x01(\x0b\x32\x16.JFJochProtoBuf.VectorH\x02\x88\x01\x01\x12\x18\n\x10\x61pply_pixel_mask\x18\x10 \x01(\x08\x12\x12\n\nbinning2x2\x18\x11 \x01(\x08\x42\x08\n\x06timingB\x0c\n\n_unit_cellB\x14\n\x12_scattering_vector\"\xf6\x02\n\x10\x44\x65tectorSettings\x12\x15\n\rframe_time_us\x18\x01 \x01(\x03\x12\x1a\n\rcount_time_us\x18\x02 \x01(\x03H\x00\x88\x01\x01\x12\x19\n\x11use_storage_cells\x18\x03 \x01(\x08\x12%\n\x1duse_internal_packet_generator\x18\x04 \x01(\x08\x12\x18\n\x10\x63ollect_raw_data\x18\x05 \x01(\x08\x12\x1f\n\x12pedestal_g0_frames\x18\x06 \x01(\x03H\x01\x88\x01\x01\x12\x1f\n\x12pedestal_g1_frames\x18\x07 \x01(\x03H\x02\x88\x01\x01\x12\x1f\n\x12pedestal_g2_frames\x18\x08 \x01(\x03H\x03\x88\x01\x01\x12\x19\n\x11\x63onversion_on_cpu\x18\t \x01(\x08\x42\x10\n\x0e_count_time_usB\x15\n\x13_pedestal_g0_framesB\x15\n\x13_pedestal_g1_framesB\x15\n\x13_pedestal_g2_frames\"b\n\x16\x44\x65tectorModuleGeometry\x12\x0e\n\x06pixel0\x18\x01 \x01(\x03\x12\x1b\n\x13\x66\x61st_direction_step\x18\x02 \x01(\x03\x12\x1b\n\x13slow_direction_step\x18\x03 \x01(\x03\"z\n\x10\x44\x65tectorGeometry\x12\x11\n\twidth_pxl\x18\x01 \x01(\x03\x12\x12\n\nheight_pxl\x18\x02 \x01(\x03\x12?\n\x0fmodule_geometry\x18\x03 \x03(\x0b\x32&.JFJochProtoBuf.DetectorModuleGeometry\"\xfe\x06\n\x10InternalSettings\x12\"\n\x1a\x66rame_time_pedestalG1G2_us\x18\x01 \x01(\x03\x12\x15\n\rframe_time_us\x18\x03 \x01(\x03\x12\x15\n\rcount_time_us\x18\x04 \x01(\x03\x12\x10\n\x08nmodules\x18\x05 \x01(\x03\x12\x14\n\x0cndatastreams\x18\x06 \x01(\x03\x12 \n\x18\x64\x65tector_module_hostname\x18\x07 \x03(\t\x12\x37\n\rconv_geometry\x18\x08 \x01(\x0b\x32 .JFJochProtoBuf.DetectorGeometry\x12&\n\x1einternal_fpga_packet_generator\x18\t \x01(\x08\x12\x15\n\rstorage_cells\x18\n \x01(\x03\x12\x1a\n\x12storage_cell_start\x18\x0b \x01(\x03\x12\x1a\n\x12pedestal_g0_frames\x18\x0c \x01(\x03\x12\x1a\n\x12pedestal_g1_frames\x18\r \x01(\x03\x12\x1a\n\x12pedestal_g2_frames\x18\x0e \x01(\x03\x12\x19\n\x11preview_period_us\x18\x0f \x01(\x03\x12\x1e\n\x16spot_finding_period_us\x18\x10 \x01(\x03\x12\x1a\n\x12indexing_period_us\x18\x11 \x01(\x03\x12*\n\x04type\x18\x12 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorType\x12*\n\x04mode\x18\x13 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorMode\x12\x19\n\x11mask_module_edges\x18\x14 \x01(\x08\x12\x17\n\x0fmask_chip_edges\x18\x15 \x01(\x08\x12\x13\n\x0bipv4_subnet\x18\x16 \x01(\x03\x12\x15\n\rbase_udp_port\x18\x17 \x01(\x03\x12\r\n\x05low_q\x18\x1a \x01(\x02\x12\x0e\n\x06high_q\x18\x1b \x01(\x02\x12\x11\n\tq_spacing\x18\x1c \x01(\x02\x12\x10\n\x08git_sha1\x18\x1d \x01(\t\x12\x10\n\x08git_date\x18\x1e \x01(\t\x12\x19\n\x11\x63onversion_on_cpu\x18\x1f \x01(\x08\x12\x13\n\x0bsource_name\x18 \x01(\t\x12\x19\n\x11source_name_short\x18! \x01(\t\x12\x17\n\x0finstrument_name\x18\" \x01(\t\x12\x1d\n\x15instrument_name_short\x18# \x01(\t\"|\n\x14JungfraujochSettings\x12\x30\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x1f.JFJochProtoBuf.DatasetSettings\x12\x32\n\x08internal\x18\x02 \x01(\x0b\x32 .JFJochProtoBuf.InternalSettings\"\x1e\n\nJFPedestal\x12\x10\n\x08pedestal\x18\x01 \x01(\x0c\"-\n\x11JFGainCalibration\x12\x18\n\x10gain_calibration\x18\x01 \x01(\x0c\"\xb2\x01\n\rJFCalibration\x12\x10\n\x08nmodules\x18\x01 \x01(\x04\x12\x16\n\x0enstorage_cells\x18\x02 \x01(\x04\x12,\n\x08pedestal\x18\x03 \x03(\x0b\x32\x1a.JFJochProtoBuf.JFPedestal\x12\x0c\n\x04mask\x18\x04 \x01(\x0c\x12;\n\x10gain_calibration\x18\x05 \x03(\x0b\x32!.JFJochProtoBuf.JFGainCalibration\"V\n\x17JFCalibrationStatistics\x12;\n\x11module_statistics\x18\x01 \x03(\x0b\x32 .JFJochProtoBuf.ModuleStatistics\"\xe1\x03\n\x1b\x41\x63quisitionDeviceStatistics\x12\x14\n\x0cgood_packets\x18\x01 \x01(\x04\x12-\n%packets_expected_per_module_and_frame\x18\x02 \x01(\x04\x12-\n%packets_received_per_module_and_frame\x18\x03 \x03(\x04\x12\x12\n\nefficiency\x18\x04 \x01(\x02\x12\x16\n\x0e\x62ytes_received\x18\x05 \x01(\x04\x12\x17\n\x0fstart_timestamp\x18\x06 \x01(\x04\x12\x15\n\rend_timestamp\x18\x07 \x01(\x04\x12/\n\x0b\x66pga_status\x18\x08 \x01(\x0b\x32\x1a.JFJochProtoBuf.FPGAStatus\x12\x10\n\x08nmodules\x18\t \x01(\x04\x12\x13\n\x0bpacket_mask\x18\n \x03(\x04\x12\x1f\n\x17mask_entries_per_module\x18\x0b \x01(\x04\x12\x18\n\x10packets_expected\x18\x0c \x01(\x04\x12\x11\n\ttimestamp\x18\r \x03(\r\x12\x16\n\x0e\x64\x65tector_debug\x18\x0e \x03(\r\x12\x0f\n\x07\x62unchid\x18\x0f \x03(\x04\x12#\n\x1bpackets_received_per_module\x18\x10 \x03(\x04\"\x88\x01\n\rReceiverInput\x12\x43\n\x15jungfraujoch_settings\x18\x01 \x01(\x0b\x32$.JFJochProtoBuf.JungfraujochSettings\x12\x32\n\x0b\x63\x61libration\x18\x02 \x01(\x0b\x32\x1d.JFJochProtoBuf.JFCalibration\"\xaa\x03\n\x0eReceiverOutput\x12\x46\n\x11\x64\x65vice_statistics\x18\x01 \x03(\x0b\x32+.JFJochProtoBuf.AcquisitionDeviceStatistics\x12\x19\n\x11max_receive_delay\x18\x02 \x01(\x04\x12\x17\n\x0f\x63ompressed_size\x18\x03 \x01(\x04\x12\x18\n\x10\x63ompressed_ratio\x18\x04 \x01(\x02\x12\x13\n\x0bimages_sent\x18\x05 \x01(\x04\x12\x15\n\rstart_time_ms\x18\x06 \x01(\x04\x12\x13\n\x0b\x65nd_time_ms\x18\x07 \x01(\x04\x12\x12\n\nefficiency\x18\x08 \x01(\x02\x12\x1d\n\x15max_image_number_sent\x18\t \x01(\x04\x12\x11\n\tcancelled\x18\n \x01(\x08\x12\x18\n\x10master_file_name\x18\x0b \x01(\t\x12\x33\n\x0fpedestal_result\x18\x0c \x03(\x0b\x32\x1a.JFJochProtoBuf.JFPedestal\x12\x1a\n\rindexing_rate\x18\r \x01(\x02H\x00\x88\x01\x01\x42\x10\n\x0e_indexing_rate\".\n\x15ReceiverNetworkConfig\x12\x15\n\rfpga_mac_addr\x18\x01 \x03(\t\"\x93\x01\n\x0eReceiverStatus\x12\x15\n\x08progress\x18\x01 \x01(\x02H\x00\x88\x01\x01\x12/\n\x0b\x66pga_status\x18\x02 \x03(\x0b\x32\x1a.JFJochProtoBuf.FPGAStatus\x12\x1a\n\rindexing_rate\x18\x03 \x01(\x02H\x01\x88\x01\x01\x42\x0b\n\t_progressB\x10\n\x0e_indexing_rate\"\xd2\x01\n\x1bReceiverDataProcessingPlots\x12*\n\x0c\x62kg_estimate\x18\x01 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12\x30\n\x12radial_int_profile\x18\x02 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12(\n\nspot_count\x18\x03 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12+\n\rindexing_rate\x18\x04 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\">\n\x0bWriterInput\x12\x1c\n\x14zmq_receiver_address\x18\x01 \x01(\t\x12\x11\n\tseries_id\x18\x02 \x01(\x03\"P\n\x0cWriterOutput\x12\x0f\n\x07nimages\x18\x01 \x01(\x03\x12\x17\n\x0fperformance_MBs\x18\x02 \x01(\x02\x12\x16\n\x0eperformance_Hz\x18\x03 \x01(\x02\"\xe0\x01\n\x14\x44\x65tectorModuleConfig\x12\x17\n\x0fudp_dest_port_1\x18\x01 \x01(\x04\x12\x17\n\x0fudp_dest_port_2\x18\x02 \x01(\x04\x12\x17\n\x0fipv4_src_addr_1\x18\x03 \x01(\t\x12\x17\n\x0fipv4_src_addr_2\x18\x04 \x01(\t\x12\x18\n\x10ipv4_dest_addr_1\x18\x05 \x01(\t\x12\x18\n\x10ipv4_dest_addr_2\x18\x06 \x01(\t\x12\x17\n\x0fmac_addr_dest_1\x18\x07 \x01(\t\x12\x17\n\x0fmac_addr_dest_2\x18\x08 \x01(\t\"`\n\x0e\x44\x65tectorConfig\x12\x35\n\x07modules\x18\x01 \x03(\x0b\x32$.JFJochProtoBuf.DetectorModuleConfig\x12\x17\n\x0fmodule_hostname\x18\x02 \x03(\t\"\xf9\x01\n\rDetectorInput\x12\x13\n\x0bmodules_num\x18\x01 \x01(\x03\x12*\n\x04mode\x18\x02 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorMode\x12\x12\n\nnum_frames\x18\x03 \x01(\x03\x12\x14\n\x0cnum_triggers\x18\x04 \x01(\x03\x12\x1b\n\x13storage_cell_number\x18\x05 \x01(\x03\x12\x1a\n\x12storage_cell_start\x18\x06 \x01(\x03\x12\x1a\n\x12storage_cell_delay\x18\x07 \x01(\x03\x12\x11\n\tperiod_us\x18\t \x01(\x03\x12\x15\n\rcount_time_us\x18\n \x01(\x03\"\x10\n\x0e\x44\x65tectorOutput\"b\n\x0e\x44\x65tectorStatus\x12$\n\x05state\x18\x01 \x01(\x0e\x32\x15.JFJochProtoBuf.State\x12\x12\n\nfw_version\x18\x02 \x01(\x03\x12\x16\n\x0eserver_version\x18\x03 \x01(\t\"\xae\x08\n\nFPGAStatus\x12\x15\n\rpackets_ether\x18\x02 \x01(\x04\x12\x13\n\x0bpackets_udp\x18\x03 \x01(\x04\x12\x16\n\x0epackets_jfjoch\x18\x04 \x01(\x04\x12\x14\n\x0cpackets_icmp\x18\x05 \x01(\x04\x12\x11\n\tfpga_idle\x18\x06 \x01(\x08\x12\x17\n\x0fhbm_temp_0_degC\x18\x07 \x01(\x04\x12\x17\n\x0fhbm_temp_1_degC\x18\x08 \x01(\x04\x12\x12\n\nstalls_hbm\x18\t \x01(\x04\x12\x13\n\x0bstalls_host\x18\n \x01(\x04\x12\x1b\n\x13\x65thernet_rx_aligned\x18\x0b \x01(\x08\x12\x1c\n\x14\x66ull_status_register\x18\r \x01(\r\x12?\n\x0b\x66ifo_status\x18\x0e \x03(\x0b\x32*.JFJochProtoBuf.FPGAStatus.FifoStatusEntry\x12\x13\n\x0bmax_modules\x18\x0f \x01(\x04\x12\x10\n\x08git_sha1\x18\x10 \x01(\r\x12\x17\n\x0fmailbox_err_reg\x18\x11 \x01(\r\x12\x1a\n\x12mailbox_status_reg\x18\x12 \x01(\r\x12\x1c\n\x14\x64\x61tamover_mm2s_error\x18\x13 \x01(\x08\x12\x1c\n\x14\x64\x61tamover_s2mm_error\x18\x14 \x01(\x08\x12&\n\x1e\x66rame_statistics_alignment_err\x18\x15 \x01(\x08\x12\"\n\x1a\x66rame_statistics_tlast_err\x18\x16 \x01(\x08\x12%\n\x1d\x66rame_statistics_work_req_err\x18\x17 \x01(\x08\x12\x14\n\x0cslowest_head\x18\x18 \x01(\x04\x12\x16\n\x0e\x66pga_temp_degC\x18\x1a \x01(\x02\x12\x1a\n\x12\x63urrent_edge_12V_A\x18\x1b \x01(\x02\x12\x1a\n\x12voltage_edge_12V_V\x18\x1c \x01(\x02\x12\x1b\n\x13\x63urrent_edge_3p3V_A\x18\x1d \x01(\x02\x12\x1b\n\x13voltage_edge_3p3V_V\x18\x1e \x01(\x02\x12\x1c\n\x14pcie_h2c_descriptors\x18\x1f \x01(\x04\x12\x1c\n\x14pcie_c2h_descriptors\x18 \x01(\x04\x12\x16\n\x0epcie_h2c_beats\x18! \x01(\x04\x12\x16\n\x0epcie_c2h_beats\x18\" \x01(\x04\x12\x17\n\x0fpcie_h2c_status\x18# \x01(\x04\x12\x17\n\x0fpcie_c2h_status\x18$ \x01(\x04\x12\x13\n\x0bpackets_sls\x18% \x01(\x04\x12\x11\n\terror_eth\x18& \x01(\r\x12\x18\n\x10\x65rror_packet_len\x18\' \x01(\r\x1aQ\n\x0f\x46ifoStatusEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12-\n\x05value\x18\x02 \x01(\x0e\x32\x1e.JFJochProtoBuf.FPGAFIFOStatus:\x02\x38\x01\"I\n\x1aIndexerDataProcessingPlots\x12+\n\rindexing_rate\x18\x01 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\"\x8a\x03\n\x16\x44\x61taProcessingSettings\x12!\n\x19signal_to_noise_threshold\x18\x01 \x01(\x02\x12\x1e\n\x16photon_count_threshold\x18\x02 \x01(\x03\x12\x18\n\x10min_pix_per_spot\x18\x03 \x01(\x03\x12\x18\n\x10max_pix_per_spot\x18\x04 \x01(\x03\x12\x16\n\x0elocal_bkg_size\x18\x05 \x01(\x03\x12\"\n\x15high_resolution_limit\x18\x06 \x01(\x02H\x00\x88\x01\x01\x12!\n\x14low_resolution_limit\x18\x07 \x01(\x02H\x01\x88\x01\x01\x12\x1a\n\x12\x62kg_estimate_low_q\x18\x08 \x01(\x02\x12\x1b\n\x13\x62kg_estimate_high_q\x18\t \x01(\x02\x12\x1b\n\x0eresult_binning\x18\n \x01(\x03H\x02\x88\x01\x01\x42\x18\n\x16_high_resolution_limitB\x17\n\x15_low_resolution_limitB\x11\n\x0f_result_binning\"\x8d\x02\n\x0cPreviewFrame\x12\x14\n\x0cimage_number\x18\x01 \x01(\x03\x12\x14\n\x0ctotal_images\x18\x02 \x01(\x03\x12\x14\n\x0cwavelength_A\x18\x03 \x01(\x02\x12\x12\n\nbeam_x_pxl\x18\x04 \x01(\x02\x12\x12\n\nbeam_y_pxl\x18\x05 \x01(\x02\x12\x1c\n\x14\x64\x65tector_distance_mm\x18\x06 \x01(\x02\x12\x18\n\x10saturation_value\x18\x07 \x01(\x03\x12\x13\n\x0b\x66ile_prefix\x18\x08 \x01(\t\x12\r\n\x05width\x18\t \x01(\x03\x12\x0e\n\x06height\x18\n \x01(\x03\x12\x13\n\x0bpixel_depth\x18\x0b \x01(\x03\x12\x0c\n\x04\x64\x61ta\x18\r \x01(\x0cJ\x04\x08\x0c\x10\r\"\xed\x01\n\x10ModuleStatistics\x12\x15\n\rmodule_number\x18\x01 \x01(\x03\x12\x1b\n\x13storage_cell_number\x18\x02 \x01(\x03\x12\x18\n\x10pedestal_g0_mean\x18\x03 \x01(\x02\x12\x18\n\x10pedestal_g1_mean\x18\x04 \x01(\x02\x12\x18\n\x10pedestal_g2_mean\x18\x05 \x01(\x02\x12\x14\n\x0cgain_g0_mean\x18\x06 \x01(\x02\x12\x14\n\x0cgain_g1_mean\x18\x07 \x01(\x02\x12\x14\n\x0cgain_g2_mean\x18\x08 \x01(\x02\x12\x15\n\rmasked_pixels\x18\t \x01(\x04\"I\n\x05Image\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c\x12\r\n\x05width\x18\x02 \x01(\x03\x12\x0e\n\x06height\x18\x03 \x01(\x03\x12\x13\n\x0bpixel_depth\x18\x04 \x01(\x03\".\n\nMaskToLoad\x12\x0c\n\x04mask\x18\x01 \x03(\r\x12\x12\n\nbit_to_set\x18\x02 \x01(\x05\"\xfc\x03\n\x15MeasurementStatistics\x12\x13\n\x0b\x66ile_prefix\x18\x01 \x01(\t\x12\x18\n\x10images_collected\x18\x02 \x01(\x03\x12\x1d\n\x15max_image_number_sent\x18\x03 \x01(\x03\x12\x1d\n\x15\x63ollection_efficiency\x18\x04 \x01(\x02\x12\x19\n\x11\x63ompression_ratio\x18\x05 \x01(\x02\x12\x11\n\tcancelled\x18\x06 \x01(\x08\x12\x19\n\x11max_receive_delay\x18\x07 \x01(\x03\x12#\n\x16writer_performance_MBs\x18\x08 \x01(\x02H\x00\x88\x01\x01\x12\x1b\n\x0eimages_written\x18\t \x01(\x03H\x01\x88\x01\x01\x12\x1a\n\rindexing_rate\x18\n \x01(\x02H\x02\x88\x01\x01\x12$\n\x17indexing_performance_ms\x18\x0b \x01(\x02H\x03\x88\x01\x01\x12\x16\n\x0e\x64\x65tector_width\x18\x0c \x01(\x03\x12\x17\n\x0f\x64\x65tector_height\x18\r \x01(\x03\x12\x1c\n\x14\x64\x65tector_pixel_depth\x18\x0e \x01(\x03\x42\x19\n\x17_writer_performance_MBsB\x11\n\x0f_images_writtenB\x10\n\x0e_indexing_rateB\x1a\n\x18_indexing_performance_ms\"\x8d\x01\n\x0c\x42rokerStatus\x12+\n\x0c\x62roker_state\x18\x01 \x01(\x0e\x32\x15.JFJochProtoBuf.State\x12\x15\n\x08progress\x18\x02 \x01(\x02H\x00\x88\x01\x01\x12\x1a\n\rindexing_rate\x18\x03 \x01(\x02H\x01\x88\x01\x01\x42\x0b\n\t_progressB\x10\n\x0e_indexing_rate\"\xa4\x01\n\x10\x42rokerFullStatus\x12\x30\n\x08receiver\x18\x01 \x01(\x0b\x32\x1e.JFJochProtoBuf.ReceiverOutput\x12\x30\n\x08\x64\x65tector\x18\x02 \x01(\x0b\x32\x1e.JFJochProtoBuf.DetectorOutput\x12,\n\x06writer\x18\x03 \x03(\x0b\x32\x1c.JFJochProtoBuf.WriterOutput*T\n\x0b\x43ompression\x12\r\n\tBSHUF_LZ4\x10\x00\x12\x0e\n\nBSHUF_ZSTD\x10\x01\x12\x12\n\x0e\x42SHUF_ZSTD_RLE\x10\x02\x12\x12\n\x0eNO_COMPRESSION\x10\x03*\'\n\x0c\x44\x65tectorType\x12\x0c\n\x08JUNGFRAU\x10\x00\x12\t\n\x05\x45IGER\x10\x01*Z\n\x0c\x44\x65tectorMode\x12\x0e\n\nCONVERSION\x10\x00\x12\x07\n\x03RAW\x10\x01\x12\x0f\n\x0bPEDESTAL_G0\x10\x02\x12\x0f\n\x0bPEDESTAL_G1\x10\x03\x12\x0f\n\x0bPEDESTAL_G2\x10\x04*2\n\x0e\x46PGAFIFOStatus\x12\t\n\x05\x45MPTY\x10\x00\x12\x08\n\x04\x46ULL\x10\x01\x12\x0b\n\x07PARTIAL\x10\x02*^\n\x05State\x12\x13\n\x0fNOT_INITIALIZED\x10\x00\x12\x08\n\x04IDLE\x10\x01\x12\x08\n\x04\x42USY\x10\x02\x12\x0c\n\x08PEDESTAL\x10\x03\x12\x13\n\x0f\x44\x41TA_COLLECTION\x10\x04\x12\t\n\x05\x45RROR\x10\x05\x32\xac\x05\n\x13gRPC_JFJochReceiver\x12?\n\x05Start\x12\x1d.JFJochProtoBuf.ReceiverInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x37\n\x05\x41\x62ort\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x38\n\x06\x43\x61ncel\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12?\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.ReceiverOutput\"\x00\x12\x44\n\tGetStatus\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.ReceiverStatus\"\x00\x12\\\n\x19SetDataProcessingSettings\x12&.JFJochProtoBuf.DataProcessingSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12^\n\x16GetDataProcessingPlots\x12\x15.JFJochProtoBuf.Empty\x1a+.JFJochProtoBuf.ReceiverDataProcessingPlots\"\x00\x12H\n\x0fGetPreviewFrame\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.PreviewFrame\"\x00\x12R\n\x10GetNetworkConfig\x12\x15.JFJochProtoBuf.Empty\x1a%.JFJochProtoBuf.ReceiverNetworkConfig\"\x00\x32\xca\x01\n\x11gRPC_JFJochWriter\x12=\n\x05Start\x12\x1b.JFJochProtoBuf.WriterInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x37\n\x05\x41\x62ort\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12=\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.WriterOutput\"\x00\x32\x82\x03\n\x13gRPC_JFJochDetector\x12?\n\x05Start\x12\x1d.JFJochProtoBuf.DetectorInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x36\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x41\n\x06Status\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.DetectorStatus\"\x00\x12=\n\x02On\x12\x1e.JFJochProtoBuf.DetectorConfig\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x35\n\x03Off\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x39\n\x07Trigger\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x32\xae\x0b\n\x11gRPC_JFJochBroker\x12\x41\n\x05Start\x12\x1f.JFJochProtoBuf.DatasetSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x36\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12:\n\x08Pedestal\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12<\n\nInitialize\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x38\n\x06\x43\x61ncel\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12<\n\nDeactivate\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x39\n\x07Trigger\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x42\n\tGetStatus\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.BrokerStatus\"\x00\x12\\\n\x18GetCalibrationStatistics\x12\x15.JFJochProtoBuf.Empty\x1a\'.JFJochProtoBuf.JFCalibrationStatistics\"\x00\x12P\n\x13GetDetectorSettings\x12\x15.JFJochProtoBuf.Empty\x1a .JFJochProtoBuf.DetectorSettings\"\x00\x12P\n\x13PutDetectorSettings\x12 .JFJochProtoBuf.DetectorSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12Z\n\x18GetMeasurementStatistics\x12\x15.JFJochProtoBuf.Empty\x1a%.JFJochProtoBuf.MeasurementStatistics\"\x00\x12\\\n\x19GetDataProcessingSettings\x12\x15.JFJochProtoBuf.Empty\x1a&.JFJochProtoBuf.DataProcessingSettings\"\x00\x12\\\n\x19PutDataProcessingSettings\x12&.JFJochProtoBuf.DataProcessingSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12P\n\x08GetPlots\x12\x15.JFJochProtoBuf.Empty\x1a+.JFJochProtoBuf.ReceiverDataProcessingPlots\"\x00\x12\x43\n\nGetPreview\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.PreviewFrame\"\x00\x12?\n\rGetPedestalG0\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12?\n\rGetPedestalG1\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12?\n\rGetPedestalG2\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12\x39\n\x07GetMask\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x62\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0cjfjoch.proto\x12\x0eJFJochProtoBuf\"\x07\n\x05\x45mpty\"W\n\x08UnitCell\x12\t\n\x01\x61\x18\x01 \x01(\x02\x12\t\n\x01\x62\x18\x02 \x01(\x02\x12\t\n\x01\x63\x18\x03 \x01(\x02\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x0c\n\x04\x62\x65ta\x18\x05 \x01(\x02\x12\r\n\x05gamma\x18\x06 \x01(\x02\")\n\x06Vector\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\x12\t\n\x01z\x18\x03 \x01(\x02\"|\n\x10RotationSettings\x12\x17\n\x0fstart_angle_deg\x18\x01 \x01(\x02\x12 \n\x18\x61ngle_incr_per_image_deg\x18\x02 \x01(\x02\x12-\n\rrotation_axis\x18\x03 \x01(\x0b\x32\x16.JFJochProtoBuf.Vector\"\x1c\n\x04Plot\x12\t\n\x01x\x18\x01 \x03(\x02\x12\t\n\x01y\x18\x02 \x03(\x02\"\xa5\x04\n\x0f\x44\x61tasetSettings\x12\x1a\n\x12images_per_trigger\x18\x01 \x01(\x03\x12\x10\n\x08ntrigger\x18\x02 \x01(\x03\x12\x13\n\tsummation\x18\x03 \x01(\x03H\x00\x12\x17\n\rimage_time_us\x18\x04 \x01(\x03H\x00\x12\x12\n\nbeam_x_pxl\x18\x05 \x01(\x02\x12\x12\n\nbeam_y_pxl\x18\x06 \x01(\x02\x12\x1c\n\x14\x64\x65tector_distance_mm\x18\x07 \x01(\x02\x12\x19\n\x11photon_energy_keV\x18\x08 \x01(\x02\x12\x13\n\x0b\x66ile_prefix\x18\t \x01(\t\x12\x17\n\x0f\x64\x61ta_file_count\x18\n \x01(\x03\x12\x30\n\x0b\x63ompression\x18\x0b \x01(\x0e\x32\x1b.JFJochProtoBuf.Compression\x12\x13\n\x0bsample_name\x18\x0c \x01(\t\x12\x30\n\tunit_cell\x18\r \x01(\x0b\x32\x18.JFJochProtoBuf.UnitCellH\x01\x88\x01\x01\x12\x1a\n\x12space_group_number\x18\x0e \x01(\x03\x12\x36\n\x11scattering_vector\x18\x0f \x01(\x0b\x32\x16.JFJochProtoBuf.VectorH\x02\x88\x01\x01\x12\x18\n\x10\x61pply_pixel_mask\x18\x10 \x01(\x08\x12\x12\n\nbinning2x2\x18\x11 \x01(\x08\x42\x08\n\x06timingB\x0c\n\n_unit_cellB\x14\n\x12_scattering_vector\"\xf6\x02\n\x10\x44\x65tectorSettings\x12\x15\n\rframe_time_us\x18\x01 \x01(\x03\x12\x1a\n\rcount_time_us\x18\x02 \x01(\x03H\x00\x88\x01\x01\x12\x19\n\x11use_storage_cells\x18\x03 \x01(\x08\x12%\n\x1duse_internal_packet_generator\x18\x04 \x01(\x08\x12\x18\n\x10\x63ollect_raw_data\x18\x05 \x01(\x08\x12\x1f\n\x12pedestal_g0_frames\x18\x06 \x01(\x03H\x01\x88\x01\x01\x12\x1f\n\x12pedestal_g1_frames\x18\x07 \x01(\x03H\x02\x88\x01\x01\x12\x1f\n\x12pedestal_g2_frames\x18\x08 \x01(\x03H\x03\x88\x01\x01\x12\x19\n\x11\x63onversion_on_cpu\x18\t \x01(\x08\x42\x10\n\x0e_count_time_usB\x15\n\x13_pedestal_g0_framesB\x15\n\x13_pedestal_g1_framesB\x15\n\x13_pedestal_g2_frames\"b\n\x16\x44\x65tectorModuleGeometry\x12\x0e\n\x06pixel0\x18\x01 \x01(\x03\x12\x1b\n\x13\x66\x61st_direction_step\x18\x02 \x01(\x03\x12\x1b\n\x13slow_direction_step\x18\x03 \x01(\x03\"z\n\x10\x44\x65tectorGeometry\x12\x11\n\twidth_pxl\x18\x01 \x01(\x03\x12\x12\n\nheight_pxl\x18\x02 \x01(\x03\x12?\n\x0fmodule_geometry\x18\x03 \x03(\x0b\x32&.JFJochProtoBuf.DetectorModuleGeometry\"\xc1\x01\n\x08\x44\x65tector\x12\x10\n\x08nmodules\x18\x01 \x01(\x03\x12\x13\n\x0b\x64\x65scription\x18\x02 \x01(\t\x12\x15\n\rpixel_size_mm\x18\x03 \x01(\x02\x12\x17\n\x0fmodule_hostname\x18\x04 \x03(\t\x12\x32\n\x08geometry\x18\x05 \x01(\x0b\x32 .JFJochProtoBuf.DetectorGeometry\x12*\n\x04type\x18\x06 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorType\"\x91\x06\n\x10InternalSettings\x12\"\n\x1a\x66rame_time_pedestalG1G2_us\x18\x01 \x01(\x03\x12\x15\n\rframe_time_us\x18\x03 \x01(\x03\x12\x15\n\rcount_time_us\x18\x04 \x01(\x03\x12*\n\x08\x64\x65tector\x18\x05 \x01(\x0b\x32\x18.JFJochProtoBuf.Detector\x12\x14\n\x0cndatastreams\x18\x06 \x01(\x03\x12&\n\x1einternal_fpga_packet_generator\x18\t \x01(\x08\x12\x15\n\rstorage_cells\x18\n \x01(\x03\x12\x1a\n\x12storage_cell_start\x18\x0b \x01(\x03\x12\x1a\n\x12pedestal_g0_frames\x18\x0c \x01(\x03\x12\x1a\n\x12pedestal_g1_frames\x18\r \x01(\x03\x12\x1a\n\x12pedestal_g2_frames\x18\x0e \x01(\x03\x12\x19\n\x11preview_period_us\x18\x0f \x01(\x03\x12\x1e\n\x16spot_finding_period_us\x18\x10 \x01(\x03\x12\x1a\n\x12indexing_period_us\x18\x11 \x01(\x03\x12*\n\x04mode\x18\x13 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorMode\x12\x19\n\x11mask_module_edges\x18\x14 \x01(\x08\x12\x17\n\x0fmask_chip_edges\x18\x15 \x01(\x08\x12\x13\n\x0bipv4_subnet\x18\x16 \x01(\x03\x12\x15\n\rbase_udp_port\x18\x17 \x01(\x03\x12\r\n\x05low_q\x18\x1a \x01(\x02\x12\x0e\n\x06high_q\x18\x1b \x01(\x02\x12\x11\n\tq_spacing\x18\x1c \x01(\x02\x12\x10\n\x08git_sha1\x18\x1d \x01(\t\x12\x10\n\x08git_date\x18\x1e \x01(\t\x12\x19\n\x11\x63onversion_on_cpu\x18\x1f \x01(\x08\x12\x13\n\x0bsource_name\x18 \x01(\t\x12\x19\n\x11source_name_short\x18! \x01(\t\x12\x17\n\x0finstrument_name\x18\" \x01(\t\x12\x1d\n\x15instrument_name_short\x18# \x01(\t\"|\n\x14JungfraujochSettings\x12\x30\n\x07\x64\x61taset\x18\x01 \x01(\x0b\x32\x1f.JFJochProtoBuf.DatasetSettings\x12\x32\n\x08internal\x18\x02 \x01(\x0b\x32 .JFJochProtoBuf.InternalSettings\"\x1e\n\nJFPedestal\x12\x10\n\x08pedestal\x18\x01 \x01(\x0c\"-\n\x11JFGainCalibration\x12\x18\n\x10gain_calibration\x18\x01 \x01(\x0c\"\xb2\x01\n\rJFCalibration\x12\x10\n\x08nmodules\x18\x01 \x01(\x04\x12\x16\n\x0enstorage_cells\x18\x02 \x01(\x04\x12,\n\x08pedestal\x18\x03 \x03(\x0b\x32\x1a.JFJochProtoBuf.JFPedestal\x12\x0c\n\x04mask\x18\x04 \x01(\x0c\x12;\n\x10gain_calibration\x18\x05 \x03(\x0b\x32!.JFJochProtoBuf.JFGainCalibration\"V\n\x17JFCalibrationStatistics\x12;\n\x11module_statistics\x18\x01 \x03(\x0b\x32 .JFJochProtoBuf.ModuleStatistics\"\xe1\x03\n\x1b\x41\x63quisitionDeviceStatistics\x12\x14\n\x0cgood_packets\x18\x01 \x01(\x04\x12-\n%packets_expected_per_module_and_frame\x18\x02 \x01(\x04\x12-\n%packets_received_per_module_and_frame\x18\x03 \x03(\x04\x12\x12\n\nefficiency\x18\x04 \x01(\x02\x12\x16\n\x0e\x62ytes_received\x18\x05 \x01(\x04\x12\x17\n\x0fstart_timestamp\x18\x06 \x01(\x04\x12\x15\n\rend_timestamp\x18\x07 \x01(\x04\x12/\n\x0b\x66pga_status\x18\x08 \x01(\x0b\x32\x1a.JFJochProtoBuf.FPGAStatus\x12\x10\n\x08nmodules\x18\t \x01(\x04\x12\x13\n\x0bpacket_mask\x18\n \x03(\x04\x12\x1f\n\x17mask_entries_per_module\x18\x0b \x01(\x04\x12\x18\n\x10packets_expected\x18\x0c \x01(\x04\x12\x11\n\ttimestamp\x18\r \x03(\r\x12\x16\n\x0e\x64\x65tector_debug\x18\x0e \x03(\r\x12\x0f\n\x07\x62unchid\x18\x0f \x03(\x04\x12#\n\x1bpackets_received_per_module\x18\x10 \x03(\x04\"\x88\x01\n\rReceiverInput\x12\x43\n\x15jungfraujoch_settings\x18\x01 \x01(\x0b\x32$.JFJochProtoBuf.JungfraujochSettings\x12\x32\n\x0b\x63\x61libration\x18\x02 \x01(\x0b\x32\x1d.JFJochProtoBuf.JFCalibration\"\xaa\x03\n\x0eReceiverOutput\x12\x46\n\x11\x64\x65vice_statistics\x18\x01 \x03(\x0b\x32+.JFJochProtoBuf.AcquisitionDeviceStatistics\x12\x19\n\x11max_receive_delay\x18\x02 \x01(\x04\x12\x17\n\x0f\x63ompressed_size\x18\x03 \x01(\x04\x12\x18\n\x10\x63ompressed_ratio\x18\x04 \x01(\x02\x12\x13\n\x0bimages_sent\x18\x05 \x01(\x04\x12\x15\n\rstart_time_ms\x18\x06 \x01(\x04\x12\x13\n\x0b\x65nd_time_ms\x18\x07 \x01(\x04\x12\x12\n\nefficiency\x18\x08 \x01(\x02\x12\x1d\n\x15max_image_number_sent\x18\t \x01(\x04\x12\x11\n\tcancelled\x18\n \x01(\x08\x12\x18\n\x10master_file_name\x18\x0b \x01(\t\x12\x33\n\x0fpedestal_result\x18\x0c \x03(\x0b\x32\x1a.JFJochProtoBuf.JFPedestal\x12\x1a\n\rindexing_rate\x18\r \x01(\x02H\x00\x88\x01\x01\x42\x10\n\x0e_indexing_rate\".\n\x15ReceiverNetworkConfig\x12\x15\n\rfpga_mac_addr\x18\x01 \x03(\t\"\x93\x01\n\x0eReceiverStatus\x12\x15\n\x08progress\x18\x01 \x01(\x02H\x00\x88\x01\x01\x12/\n\x0b\x66pga_status\x18\x02 \x03(\x0b\x32\x1a.JFJochProtoBuf.FPGAStatus\x12\x1a\n\rindexing_rate\x18\x03 \x01(\x02H\x01\x88\x01\x01\x42\x0b\n\t_progressB\x10\n\x0e_indexing_rate\"\xd2\x01\n\x1bReceiverDataProcessingPlots\x12*\n\x0c\x62kg_estimate\x18\x01 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12\x30\n\x12radial_int_profile\x18\x02 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12(\n\nspot_count\x18\x03 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\x12+\n\rindexing_rate\x18\x04 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\">\n\x0bWriterInput\x12\x1c\n\x14zmq_receiver_address\x18\x01 \x01(\t\x12\x11\n\tseries_id\x18\x02 \x01(\x03\"P\n\x0cWriterOutput\x12\x0f\n\x07nimages\x18\x01 \x01(\x03\x12\x17\n\x0fperformance_MBs\x18\x02 \x01(\x02\x12\x16\n\x0eperformance_Hz\x18\x03 \x01(\x02\"\xe0\x01\n\x14\x44\x65tectorModuleConfig\x12\x17\n\x0fudp_dest_port_1\x18\x01 \x01(\x04\x12\x17\n\x0fudp_dest_port_2\x18\x02 \x01(\x04\x12\x17\n\x0fipv4_src_addr_1\x18\x03 \x01(\t\x12\x17\n\x0fipv4_src_addr_2\x18\x04 \x01(\t\x12\x18\n\x10ipv4_dest_addr_1\x18\x05 \x01(\t\x12\x18\n\x10ipv4_dest_addr_2\x18\x06 \x01(\t\x12\x17\n\x0fmac_addr_dest_1\x18\x07 \x01(\t\x12\x17\n\x0fmac_addr_dest_2\x18\x08 \x01(\t\"`\n\x0e\x44\x65tectorConfig\x12\x35\n\x07modules\x18\x01 \x03(\x0b\x32$.JFJochProtoBuf.DetectorModuleConfig\x12\x17\n\x0fmodule_hostname\x18\x02 \x03(\t\"\xf9\x01\n\rDetectorInput\x12\x13\n\x0bmodules_num\x18\x01 \x01(\x03\x12*\n\x04mode\x18\x02 \x01(\x0e\x32\x1c.JFJochProtoBuf.DetectorMode\x12\x12\n\nnum_frames\x18\x03 \x01(\x03\x12\x14\n\x0cnum_triggers\x18\x04 \x01(\x03\x12\x1b\n\x13storage_cell_number\x18\x05 \x01(\x03\x12\x1a\n\x12storage_cell_start\x18\x06 \x01(\x03\x12\x1a\n\x12storage_cell_delay\x18\x07 \x01(\x03\x12\x11\n\tperiod_us\x18\t \x01(\x03\x12\x15\n\rcount_time_us\x18\n \x01(\x03\"\x10\n\x0e\x44\x65tectorOutput\"b\n\x0e\x44\x65tectorStatus\x12$\n\x05state\x18\x01 \x01(\x0e\x32\x15.JFJochProtoBuf.State\x12\x12\n\nfw_version\x18\x02 \x01(\x03\x12\x16\n\x0eserver_version\x18\x03 \x01(\t\"\xae\x08\n\nFPGAStatus\x12\x15\n\rpackets_ether\x18\x02 \x01(\x04\x12\x13\n\x0bpackets_udp\x18\x03 \x01(\x04\x12\x16\n\x0epackets_jfjoch\x18\x04 \x01(\x04\x12\x14\n\x0cpackets_icmp\x18\x05 \x01(\x04\x12\x11\n\tfpga_idle\x18\x06 \x01(\x08\x12\x17\n\x0fhbm_temp_0_degC\x18\x07 \x01(\x04\x12\x17\n\x0fhbm_temp_1_degC\x18\x08 \x01(\x04\x12\x12\n\nstalls_hbm\x18\t \x01(\x04\x12\x13\n\x0bstalls_host\x18\n \x01(\x04\x12\x1b\n\x13\x65thernet_rx_aligned\x18\x0b \x01(\x08\x12\x1c\n\x14\x66ull_status_register\x18\r \x01(\r\x12?\n\x0b\x66ifo_status\x18\x0e \x03(\x0b\x32*.JFJochProtoBuf.FPGAStatus.FifoStatusEntry\x12\x13\n\x0bmax_modules\x18\x0f \x01(\x04\x12\x10\n\x08git_sha1\x18\x10 \x01(\r\x12\x17\n\x0fmailbox_err_reg\x18\x11 \x01(\r\x12\x1a\n\x12mailbox_status_reg\x18\x12 \x01(\r\x12\x1c\n\x14\x64\x61tamover_mm2s_error\x18\x13 \x01(\x08\x12\x1c\n\x14\x64\x61tamover_s2mm_error\x18\x14 \x01(\x08\x12&\n\x1e\x66rame_statistics_alignment_err\x18\x15 \x01(\x08\x12\"\n\x1a\x66rame_statistics_tlast_err\x18\x16 \x01(\x08\x12%\n\x1d\x66rame_statistics_work_req_err\x18\x17 \x01(\x08\x12\x14\n\x0cslowest_head\x18\x18 \x01(\x04\x12\x16\n\x0e\x66pga_temp_degC\x18\x1a \x01(\x02\x12\x1a\n\x12\x63urrent_edge_12V_A\x18\x1b \x01(\x02\x12\x1a\n\x12voltage_edge_12V_V\x18\x1c \x01(\x02\x12\x1b\n\x13\x63urrent_edge_3p3V_A\x18\x1d \x01(\x02\x12\x1b\n\x13voltage_edge_3p3V_V\x18\x1e \x01(\x02\x12\x1c\n\x14pcie_h2c_descriptors\x18\x1f \x01(\x04\x12\x1c\n\x14pcie_c2h_descriptors\x18 \x01(\x04\x12\x16\n\x0epcie_h2c_beats\x18! \x01(\x04\x12\x16\n\x0epcie_c2h_beats\x18\" \x01(\x04\x12\x17\n\x0fpcie_h2c_status\x18# \x01(\x04\x12\x17\n\x0fpcie_c2h_status\x18$ \x01(\x04\x12\x13\n\x0bpackets_sls\x18% \x01(\x04\x12\x11\n\terror_eth\x18& \x01(\r\x12\x18\n\x10\x65rror_packet_len\x18\' \x01(\r\x1aQ\n\x0f\x46ifoStatusEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12-\n\x05value\x18\x02 \x01(\x0e\x32\x1e.JFJochProtoBuf.FPGAFIFOStatus:\x02\x38\x01\"I\n\x1aIndexerDataProcessingPlots\x12+\n\rindexing_rate\x18\x01 \x01(\x0b\x32\x14.JFJochProtoBuf.Plot\"\x8a\x03\n\x16\x44\x61taProcessingSettings\x12!\n\x19signal_to_noise_threshold\x18\x01 \x01(\x02\x12\x1e\n\x16photon_count_threshold\x18\x02 \x01(\x03\x12\x18\n\x10min_pix_per_spot\x18\x03 \x01(\x03\x12\x18\n\x10max_pix_per_spot\x18\x04 \x01(\x03\x12\x16\n\x0elocal_bkg_size\x18\x05 \x01(\x03\x12\"\n\x15high_resolution_limit\x18\x06 \x01(\x02H\x00\x88\x01\x01\x12!\n\x14low_resolution_limit\x18\x07 \x01(\x02H\x01\x88\x01\x01\x12\x1a\n\x12\x62kg_estimate_low_q\x18\x08 \x01(\x02\x12\x1b\n\x13\x62kg_estimate_high_q\x18\t \x01(\x02\x12\x1b\n\x0eresult_binning\x18\n \x01(\x03H\x02\x88\x01\x01\x42\x18\n\x16_high_resolution_limitB\x17\n\x15_low_resolution_limitB\x11\n\x0f_result_binning\"\x8d\x02\n\x0cPreviewFrame\x12\x14\n\x0cimage_number\x18\x01 \x01(\x03\x12\x14\n\x0ctotal_images\x18\x02 \x01(\x03\x12\x14\n\x0cwavelength_A\x18\x03 \x01(\x02\x12\x12\n\nbeam_x_pxl\x18\x04 \x01(\x02\x12\x12\n\nbeam_y_pxl\x18\x05 \x01(\x02\x12\x1c\n\x14\x64\x65tector_distance_mm\x18\x06 \x01(\x02\x12\x18\n\x10saturation_value\x18\x07 \x01(\x03\x12\x13\n\x0b\x66ile_prefix\x18\x08 \x01(\t\x12\r\n\x05width\x18\t \x01(\x03\x12\x0e\n\x06height\x18\n \x01(\x03\x12\x13\n\x0bpixel_depth\x18\x0b \x01(\x03\x12\x0c\n\x04\x64\x61ta\x18\r \x01(\x0cJ\x04\x08\x0c\x10\r\"\xed\x01\n\x10ModuleStatistics\x12\x15\n\rmodule_number\x18\x01 \x01(\x03\x12\x1b\n\x13storage_cell_number\x18\x02 \x01(\x03\x12\x18\n\x10pedestal_g0_mean\x18\x03 \x01(\x02\x12\x18\n\x10pedestal_g1_mean\x18\x04 \x01(\x02\x12\x18\n\x10pedestal_g2_mean\x18\x05 \x01(\x02\x12\x14\n\x0cgain_g0_mean\x18\x06 \x01(\x02\x12\x14\n\x0cgain_g1_mean\x18\x07 \x01(\x02\x12\x14\n\x0cgain_g2_mean\x18\x08 \x01(\x02\x12\x15\n\rmasked_pixels\x18\t \x01(\x04\"I\n\x05Image\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c\x12\r\n\x05width\x18\x02 \x01(\x03\x12\x0e\n\x06height\x18\x03 \x01(\x03\x12\x13\n\x0bpixel_depth\x18\x04 \x01(\x03\".\n\nMaskToLoad\x12\x0c\n\x04mask\x18\x01 \x03(\r\x12\x12\n\nbit_to_set\x18\x02 \x01(\x05\"\xfc\x03\n\x15MeasurementStatistics\x12\x13\n\x0b\x66ile_prefix\x18\x01 \x01(\t\x12\x18\n\x10images_collected\x18\x02 \x01(\x03\x12\x1d\n\x15max_image_number_sent\x18\x03 \x01(\x03\x12\x1d\n\x15\x63ollection_efficiency\x18\x04 \x01(\x02\x12\x19\n\x11\x63ompression_ratio\x18\x05 \x01(\x02\x12\x11\n\tcancelled\x18\x06 \x01(\x08\x12\x19\n\x11max_receive_delay\x18\x07 \x01(\x03\x12#\n\x16writer_performance_MBs\x18\x08 \x01(\x02H\x00\x88\x01\x01\x12\x1b\n\x0eimages_written\x18\t \x01(\x03H\x01\x88\x01\x01\x12\x1a\n\rindexing_rate\x18\n \x01(\x02H\x02\x88\x01\x01\x12$\n\x17indexing_performance_ms\x18\x0b \x01(\x02H\x03\x88\x01\x01\x12\x16\n\x0e\x64\x65tector_width\x18\x0c \x01(\x03\x12\x17\n\x0f\x64\x65tector_height\x18\r \x01(\x03\x12\x1c\n\x14\x64\x65tector_pixel_depth\x18\x0e \x01(\x03\x42\x19\n\x17_writer_performance_MBsB\x11\n\x0f_images_writtenB\x10\n\x0e_indexing_rateB\x1a\n\x18_indexing_performance_ms\"\x8d\x01\n\x0c\x42rokerStatus\x12+\n\x0c\x62roker_state\x18\x01 \x01(\x0e\x32\x15.JFJochProtoBuf.State\x12\x15\n\x08progress\x18\x02 \x01(\x02H\x00\x88\x01\x01\x12\x1a\n\rindexing_rate\x18\x03 \x01(\x02H\x01\x88\x01\x01\x42\x0b\n\t_progressB\x10\n\x0e_indexing_rate\"\xa4\x01\n\x10\x42rokerFullStatus\x12\x30\n\x08receiver\x18\x01 \x01(\x0b\x32\x1e.JFJochProtoBuf.ReceiverOutput\x12\x30\n\x08\x64\x65tector\x18\x02 \x01(\x0b\x32\x1e.JFJochProtoBuf.DetectorOutput\x12,\n\x06writer\x18\x03 \x03(\x0b\x32\x1c.JFJochProtoBuf.WriterOutput*T\n\x0b\x43ompression\x12\r\n\tBSHUF_LZ4\x10\x00\x12\x0e\n\nBSHUF_ZSTD\x10\x01\x12\x12\n\x0e\x42SHUF_ZSTD_RLE\x10\x02\x12\x12\n\x0eNO_COMPRESSION\x10\x03*\'\n\x0c\x44\x65tectorType\x12\x0c\n\x08JUNGFRAU\x10\x00\x12\t\n\x05\x45IGER\x10\x01*Z\n\x0c\x44\x65tectorMode\x12\x0e\n\nCONVERSION\x10\x00\x12\x07\n\x03RAW\x10\x01\x12\x0f\n\x0bPEDESTAL_G0\x10\x02\x12\x0f\n\x0bPEDESTAL_G1\x10\x03\x12\x0f\n\x0bPEDESTAL_G2\x10\x04*2\n\x0e\x46PGAFIFOStatus\x12\t\n\x05\x45MPTY\x10\x00\x12\x08\n\x04\x46ULL\x10\x01\x12\x0b\n\x07PARTIAL\x10\x02*^\n\x05State\x12\x13\n\x0fNOT_INITIALIZED\x10\x00\x12\x08\n\x04IDLE\x10\x01\x12\x08\n\x04\x42USY\x10\x02\x12\x0c\n\x08PEDESTAL\x10\x03\x12\x13\n\x0f\x44\x41TA_COLLECTION\x10\x04\x12\t\n\x05\x45RROR\x10\x05\x32\xac\x05\n\x13gRPC_JFJochReceiver\x12?\n\x05Start\x12\x1d.JFJochProtoBuf.ReceiverInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x37\n\x05\x41\x62ort\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x38\n\x06\x43\x61ncel\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12?\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.ReceiverOutput\"\x00\x12\x44\n\tGetStatus\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.ReceiverStatus\"\x00\x12\\\n\x19SetDataProcessingSettings\x12&.JFJochProtoBuf.DataProcessingSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12^\n\x16GetDataProcessingPlots\x12\x15.JFJochProtoBuf.Empty\x1a+.JFJochProtoBuf.ReceiverDataProcessingPlots\"\x00\x12H\n\x0fGetPreviewFrame\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.PreviewFrame\"\x00\x12R\n\x10GetNetworkConfig\x12\x15.JFJochProtoBuf.Empty\x1a%.JFJochProtoBuf.ReceiverNetworkConfig\"\x00\x32\xca\x01\n\x11gRPC_JFJochWriter\x12=\n\x05Start\x12\x1b.JFJochProtoBuf.WriterInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x37\n\x05\x41\x62ort\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12=\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.WriterOutput\"\x00\x32\x82\x03\n\x13gRPC_JFJochDetector\x12?\n\x05Start\x12\x1d.JFJochProtoBuf.DetectorInput\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x36\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x41\n\x06Status\x12\x15.JFJochProtoBuf.Empty\x1a\x1e.JFJochProtoBuf.DetectorStatus\"\x00\x12=\n\x02On\x12\x1e.JFJochProtoBuf.DetectorConfig\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x35\n\x03Off\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x39\n\x07Trigger\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x32\xae\x0b\n\x11gRPC_JFJochBroker\x12\x41\n\x05Start\x12\x1f.JFJochProtoBuf.DatasetSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x36\n\x04Stop\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12:\n\x08Pedestal\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12<\n\nInitialize\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x38\n\x06\x43\x61ncel\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12<\n\nDeactivate\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x39\n\x07Trigger\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12\x42\n\tGetStatus\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.BrokerStatus\"\x00\x12\\\n\x18GetCalibrationStatistics\x12\x15.JFJochProtoBuf.Empty\x1a\'.JFJochProtoBuf.JFCalibrationStatistics\"\x00\x12P\n\x13GetDetectorSettings\x12\x15.JFJochProtoBuf.Empty\x1a .JFJochProtoBuf.DetectorSettings\"\x00\x12P\n\x13PutDetectorSettings\x12 .JFJochProtoBuf.DetectorSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12Z\n\x18GetMeasurementStatistics\x12\x15.JFJochProtoBuf.Empty\x1a%.JFJochProtoBuf.MeasurementStatistics\"\x00\x12\\\n\x19GetDataProcessingSettings\x12\x15.JFJochProtoBuf.Empty\x1a&.JFJochProtoBuf.DataProcessingSettings\"\x00\x12\\\n\x19PutDataProcessingSettings\x12&.JFJochProtoBuf.DataProcessingSettings\x1a\x15.JFJochProtoBuf.Empty\"\x00\x12P\n\x08GetPlots\x12\x15.JFJochProtoBuf.Empty\x1a+.JFJochProtoBuf.ReceiverDataProcessingPlots\"\x00\x12\x43\n\nGetPreview\x12\x15.JFJochProtoBuf.Empty\x1a\x1c.JFJochProtoBuf.PreviewFrame\"\x00\x12?\n\rGetPedestalG0\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12?\n\rGetPedestalG1\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12?\n\rGetPedestalG2\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x12\x39\n\x07GetMask\x12\x15.JFJochProtoBuf.Empty\x1a\x15.JFJochProtoBuf.Image\"\x00\x62\x06proto3') _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, globals()) _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'jfjoch_pb2', globals()) @@ -22,16 +22,16 @@ if _descriptor._USE_C_DESCRIPTORS == False: DESCRIPTOR._options = None _FPGASTATUS_FIFOSTATUSENTRY._options = None _FPGASTATUS_FIFOSTATUSENTRY._serialized_options = b'8\001' - _COMPRESSION._serialized_start=8159 - _COMPRESSION._serialized_end=8243 - _DETECTORTYPE._serialized_start=8245 - _DETECTORTYPE._serialized_end=8284 - _DETECTORMODE._serialized_start=8286 - _DETECTORMODE._serialized_end=8376 - _FPGAFIFOSTATUS._serialized_start=8378 - _FPGAFIFOSTATUS._serialized_end=8428 - _STATE._serialized_start=8430 - _STATE._serialized_end=8524 + _COMPRESSION._serialized_start=8246 + _COMPRESSION._serialized_end=8330 + _DETECTORTYPE._serialized_start=8332 + _DETECTORTYPE._serialized_end=8371 + _DETECTORMODE._serialized_start=8373 + _DETECTORMODE._serialized_end=8463 + _FPGAFIFOSTATUS._serialized_start=8465 + _FPGAFIFOSTATUS._serialized_end=8515 + _STATE._serialized_start=8517 + _STATE._serialized_end=8611 _EMPTY._serialized_start=32 _EMPTY._serialized_end=39 _UNITCELL._serialized_start=41 @@ -50,72 +50,74 @@ if _descriptor._USE_C_DESCRIPTORS == False: _DETECTORMODULEGEOMETRY._serialized_end=1356 _DETECTORGEOMETRY._serialized_start=1358 _DETECTORGEOMETRY._serialized_end=1480 - _INTERNALSETTINGS._serialized_start=1483 - _INTERNALSETTINGS._serialized_end=2377 - _JUNGFRAUJOCHSETTINGS._serialized_start=2379 - _JUNGFRAUJOCHSETTINGS._serialized_end=2503 - _JFPEDESTAL._serialized_start=2505 - _JFPEDESTAL._serialized_end=2535 - _JFGAINCALIBRATION._serialized_start=2537 - _JFGAINCALIBRATION._serialized_end=2582 - _JFCALIBRATION._serialized_start=2585 - _JFCALIBRATION._serialized_end=2763 - _JFCALIBRATIONSTATISTICS._serialized_start=2765 - _JFCALIBRATIONSTATISTICS._serialized_end=2851 - _ACQUISITIONDEVICESTATISTICS._serialized_start=2854 - _ACQUISITIONDEVICESTATISTICS._serialized_end=3335 - _RECEIVERINPUT._serialized_start=3338 - _RECEIVERINPUT._serialized_end=3474 - _RECEIVEROUTPUT._serialized_start=3477 - _RECEIVEROUTPUT._serialized_end=3903 - _RECEIVERNETWORKCONFIG._serialized_start=3905 - _RECEIVERNETWORKCONFIG._serialized_end=3951 - _RECEIVERSTATUS._serialized_start=3954 - _RECEIVERSTATUS._serialized_end=4101 - _RECEIVERDATAPROCESSINGPLOTS._serialized_start=4104 - _RECEIVERDATAPROCESSINGPLOTS._serialized_end=4314 - _WRITERINPUT._serialized_start=4316 - _WRITERINPUT._serialized_end=4378 - _WRITEROUTPUT._serialized_start=4380 - _WRITEROUTPUT._serialized_end=4460 - _DETECTORMODULECONFIG._serialized_start=4463 - _DETECTORMODULECONFIG._serialized_end=4687 - _DETECTORCONFIG._serialized_start=4689 - _DETECTORCONFIG._serialized_end=4785 - _DETECTORINPUT._serialized_start=4788 - _DETECTORINPUT._serialized_end=5037 - _DETECTOROUTPUT._serialized_start=5039 - _DETECTOROUTPUT._serialized_end=5055 - _DETECTORSTATUS._serialized_start=5057 - _DETECTORSTATUS._serialized_end=5155 - _FPGASTATUS._serialized_start=5158 - _FPGASTATUS._serialized_end=6228 - _FPGASTATUS_FIFOSTATUSENTRY._serialized_start=6147 - _FPGASTATUS_FIFOSTATUSENTRY._serialized_end=6228 - _INDEXERDATAPROCESSINGPLOTS._serialized_start=6230 - _INDEXERDATAPROCESSINGPLOTS._serialized_end=6303 - _DATAPROCESSINGSETTINGS._serialized_start=6306 - _DATAPROCESSINGSETTINGS._serialized_end=6700 - _PREVIEWFRAME._serialized_start=6703 - _PREVIEWFRAME._serialized_end=6972 - _MODULESTATISTICS._serialized_start=6975 - _MODULESTATISTICS._serialized_end=7212 - _IMAGE._serialized_start=7214 - _IMAGE._serialized_end=7287 - _MASKTOLOAD._serialized_start=7289 - _MASKTOLOAD._serialized_end=7335 - _MEASUREMENTSTATISTICS._serialized_start=7338 - _MEASUREMENTSTATISTICS._serialized_end=7846 - _BROKERSTATUS._serialized_start=7849 - _BROKERSTATUS._serialized_end=7990 - _BROKERFULLSTATUS._serialized_start=7993 - _BROKERFULLSTATUS._serialized_end=8157 - _GRPC_JFJOCHRECEIVER._serialized_start=8527 - _GRPC_JFJOCHRECEIVER._serialized_end=9211 - _GRPC_JFJOCHWRITER._serialized_start=9214 - _GRPC_JFJOCHWRITER._serialized_end=9416 - _GRPC_JFJOCHDETECTOR._serialized_start=9419 - _GRPC_JFJOCHDETECTOR._serialized_end=9805 - _GRPC_JFJOCHBROKER._serialized_start=9808 - _GRPC_JFJOCHBROKER._serialized_end=11262 + _DETECTOR._serialized_start=1483 + _DETECTOR._serialized_end=1676 + _INTERNALSETTINGS._serialized_start=1679 + _INTERNALSETTINGS._serialized_end=2464 + _JUNGFRAUJOCHSETTINGS._serialized_start=2466 + _JUNGFRAUJOCHSETTINGS._serialized_end=2590 + _JFPEDESTAL._serialized_start=2592 + _JFPEDESTAL._serialized_end=2622 + _JFGAINCALIBRATION._serialized_start=2624 + _JFGAINCALIBRATION._serialized_end=2669 + _JFCALIBRATION._serialized_start=2672 + _JFCALIBRATION._serialized_end=2850 + _JFCALIBRATIONSTATISTICS._serialized_start=2852 + _JFCALIBRATIONSTATISTICS._serialized_end=2938 + _ACQUISITIONDEVICESTATISTICS._serialized_start=2941 + _ACQUISITIONDEVICESTATISTICS._serialized_end=3422 + _RECEIVERINPUT._serialized_start=3425 + _RECEIVERINPUT._serialized_end=3561 + _RECEIVEROUTPUT._serialized_start=3564 + _RECEIVEROUTPUT._serialized_end=3990 + _RECEIVERNETWORKCONFIG._serialized_start=3992 + _RECEIVERNETWORKCONFIG._serialized_end=4038 + _RECEIVERSTATUS._serialized_start=4041 + _RECEIVERSTATUS._serialized_end=4188 + _RECEIVERDATAPROCESSINGPLOTS._serialized_start=4191 + _RECEIVERDATAPROCESSINGPLOTS._serialized_end=4401 + _WRITERINPUT._serialized_start=4403 + _WRITERINPUT._serialized_end=4465 + _WRITEROUTPUT._serialized_start=4467 + _WRITEROUTPUT._serialized_end=4547 + _DETECTORMODULECONFIG._serialized_start=4550 + _DETECTORMODULECONFIG._serialized_end=4774 + _DETECTORCONFIG._serialized_start=4776 + _DETECTORCONFIG._serialized_end=4872 + _DETECTORINPUT._serialized_start=4875 + _DETECTORINPUT._serialized_end=5124 + _DETECTOROUTPUT._serialized_start=5126 + _DETECTOROUTPUT._serialized_end=5142 + _DETECTORSTATUS._serialized_start=5144 + _DETECTORSTATUS._serialized_end=5242 + _FPGASTATUS._serialized_start=5245 + _FPGASTATUS._serialized_end=6315 + _FPGASTATUS_FIFOSTATUSENTRY._serialized_start=6234 + _FPGASTATUS_FIFOSTATUSENTRY._serialized_end=6315 + _INDEXERDATAPROCESSINGPLOTS._serialized_start=6317 + _INDEXERDATAPROCESSINGPLOTS._serialized_end=6390 + _DATAPROCESSINGSETTINGS._serialized_start=6393 + _DATAPROCESSINGSETTINGS._serialized_end=6787 + _PREVIEWFRAME._serialized_start=6790 + _PREVIEWFRAME._serialized_end=7059 + _MODULESTATISTICS._serialized_start=7062 + _MODULESTATISTICS._serialized_end=7299 + _IMAGE._serialized_start=7301 + _IMAGE._serialized_end=7374 + _MASKTOLOAD._serialized_start=7376 + _MASKTOLOAD._serialized_end=7422 + _MEASUREMENTSTATISTICS._serialized_start=7425 + _MEASUREMENTSTATISTICS._serialized_end=7933 + _BROKERSTATUS._serialized_start=7936 + _BROKERSTATUS._serialized_end=8077 + _BROKERFULLSTATUS._serialized_start=8080 + _BROKERFULLSTATUS._serialized_end=8244 + _GRPC_JFJOCHRECEIVER._serialized_start=8614 + _GRPC_JFJOCHRECEIVER._serialized_end=9298 + _GRPC_JFJOCHWRITER._serialized_start=9301 + _GRPC_JFJOCHWRITER._serialized_end=9503 + _GRPC_JFJOCHDETECTOR._serialized_start=9506 + _GRPC_JFJOCHDETECTOR._serialized_end=9892 + _GRPC_JFJOCHBROKER._serialized_start=9895 + _GRPC_JFJOCHBROKER._serialized_end=11349 # @@protoc_insertion_point(module_scope) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 60981b8d..b1efdd72 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -24,7 +24,7 @@ ADD_EXECUTABLE(CatchTest JFCalibrationTest.cpp RadialIntegrationTest.cpp StatusVectorTest.cpp ProcessRawPacketTest.cpp - CBORTest.cpp JFConversionTest.cpp DetectorGeometryTest.cpp JFJochBrokerParserTest.cpp) + CBORTest.cpp JFConversionTest.cpp DetectorGeometryTest.cpp JFJochBrokerParserTest.cpp DetectorSetupTest.cpp) target_link_libraries(CatchTest JFJochBroker JFJochReceiver JFJochWriter ImageAnalysis CommonFunctions HLSSimulation) target_include_directories(CatchTest PRIVATE .) diff --git a/tests/DetectorSetupTest.cpp b/tests/DetectorSetupTest.cpp new file mode 100644 index 00000000..50cd3fff --- /dev/null +++ b/tests/DetectorSetupTest.cpp @@ -0,0 +1,52 @@ +// Copyright (2019-2022) Paul Scherrer Institute +// SPDX-License-Identifier: GPL-3.0-or-later + +#include +#include "../common/DetectorSetup.h" + +TEST_CASE("DetectorSetup_MismatchInSize") { + REQUIRE_THROWS(DetectorSetup(DetectorGeometry(8), "JF", {"mx1","mx2","mx3","mx4"})); + REQUIRE_THROWS(DetectorSetup(DetectorGeometry(2), "JF", {"mx1","mx2","mx3","mx4"})); + REQUIRE_NOTHROW(DetectorSetup(DetectorGeometry(4), "JF", {"mx1","mx2","mx3","mx4"})); +} + +TEST_CASE("DetectorSetup_ProtoBuf") { + DetectorSetup setup(DetectorGeometry(4), "JF", {"mx1","mx2","mx3","mx4"}); + JFJochProtoBuf::Detector detector = setup; + REQUIRE(detector.type() == JFJochProtoBuf::JUNGFRAU); + REQUIRE(detector.description() == "JF"); + REQUIRE(detector.module_hostname_size() == 4); + REQUIRE(detector.module_hostname(3) == "mx4"); + REQUIRE(detector.pixel_size_mm() == Approx(0.075)); + REQUIRE(detector.nmodules() == 4); + REQUIRE(detector.geometry().module_geometry_size() == 4); +} + +TEST_CASE("DetectorSetup_LoadGainFile") { + DetectorSetup setup(DetectorGeometry(4), "JF", {"mx1","mx2","mx3","mx4"}); + REQUIRE_THROWS(setup.LoadGain({})); + + REQUIRE(setup.GetGainCalibration().empty()); + + REQUIRE_THROWS(setup.LoadGain({ + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin" + })); + + REQUIRE_THROWS(setup.LoadGain({ + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin" + })); + + REQUIRE_NOTHROW(setup.LoadGain({ + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin", + "../../tests/test_data/gainMaps_M049.bin" + })); + REQUIRE(setup.GetGainCalibration().size() == 4); +} \ No newline at end of file diff --git a/tests/DiffractionExperimentTest.cpp b/tests/DiffractionExperimentTest.cpp index 086a8a1d..fbfd21c8 100644 --- a/tests/DiffractionExperimentTest.cpp +++ b/tests/DiffractionExperimentTest.cpp @@ -744,29 +744,6 @@ TEST_CASE("DiffractionExperiment_StorageCells_Pedestal","[DiffractionExperiment] REQUIRE(x.GetFrameNum() == 456 * 2); } - -TEST_CASE("DiffractionExperiment_IsPixelSigned","[DiffractionExperiment]") { - DiffractionExperiment x; - x.DetectorType(JFJochProtoBuf::JUNGFRAU).Mode(DetectorMode::Conversion); - REQUIRE(x.IsPixelSigned()); - x.DetectorType(JFJochProtoBuf::EIGER); - REQUIRE(!x.IsPixelSigned()); - x.DetectorType(JFJochProtoBuf::JUNGFRAU).Mode(DetectorMode::Raw); - REQUIRE(!x.IsPixelSigned()); -} - -TEST_CASE("DiffractionExperiment_DetectorType","[DiffractionExperiment]") { - DiffractionExperiment x,y; - REQUIRE(x.GetDetectorType() == JFJochProtoBuf::JUNGFRAU); // JF is default - x.DetectorType(JFJochProtoBuf::EIGER); - REQUIRE(x.GetDetectorType() == JFJochProtoBuf::EIGER); - - JFJochProtoBuf::JungfraujochSettings settings_in_protobuf = x; - REQUIRE_NOTHROW(y.Import(settings_in_protobuf)); - - REQUIRE(y.GetDetectorType() == JFJochProtoBuf::EIGER); -} - TEST_CASE("DiffractionExperiment_DetectorInput_MultiTriggger","[DiffractionExperiment]") { DiffractionExperiment x(DetectorGeometry(8, 2, 8, 36)); x.FrameTime(700us).Summation(1).ImagesPerTrigger(350).NumTriggers(7); @@ -974,7 +951,6 @@ TEST_CASE("DiffractionExperiment_DefaultDataProcessingSettings","[DiffractionExp TEST_CASE("DiffractionExperiment_ConversionOnCPU","[DiffractionExperiment]") { DiffractionExperiment x; - x.DetectorType(JFJochProtoBuf::JUNGFRAU); REQUIRE(x.GetConversionOnFPGA()); REQUIRE(!x.GetConversionOnCPU()); @@ -990,10 +966,6 @@ TEST_CASE("DiffractionExperiment_ConversionOnCPU","[DiffractionExperiment]") { x.LoadDetectorSettings(settings); REQUIRE(x.GetConversionOnFPGA()); REQUIRE(!x.GetConversionOnCPU()); - - x.DetectorType(JFJochProtoBuf::EIGER); - REQUIRE(!x.GetConversionOnFPGA()); - REQUIRE(!x.GetConversionOnCPU()); } TEST_CASE("DiffractionExperiment_Binning","[DiffractionExperiment]") { @@ -1039,22 +1011,16 @@ TEST_CASE("DiffractionExperiment_Binning","[DiffractionExperiment]") { TEST_CASE("DiffractionExperiment_DetectorModuleHostname","[DiffractionExperiment]") { std::vector h = {"mx1", "mx2", "mx3"}; - DiffractionExperiment x(DetectorGeometry(8)); + DiffractionExperiment x(DetectorSetup(3, "X", h)); JFJochProtoBuf::DetectorConfig det_cfg; JFJochProtoBuf::ReceiverNetworkConfig net_cfg; net_cfg.add_fpga_mac_addr("AA:BB:CC:DD:EE:FF"); net_cfg.add_fpga_mac_addr("AA:BB:CC:DD:EE:FE"); - // Before setting module hostname - REQUIRE_NOTHROW(det_cfg = x.DetectorConfig(net_cfg)); - - REQUIRE_NOTHROW(x.DetectorModuleHostname(h)); std::vector h_out; REQUIRE_NOTHROW(x.GetDetectorModuleHostname(h_out)); REQUIRE(h == h_out); - REQUIRE_THROWS(det_cfg = x.DetectorConfig(net_cfg)); - x.Geometry(DetectorGeometry(3)); REQUIRE_NOTHROW(det_cfg = x.DetectorConfig(net_cfg)); } \ No newline at end of file