Merge branch 'developer' into localhost

This commit is contained in:
2022-02-11 16:24:11 +01:00
11 changed files with 56 additions and 20 deletions

View File

@ -1466,6 +1466,21 @@ void Implementation::setTenGigaEnable(const bool b) {
generalData->SetTenGigaEnable(b);
SetupFifoStructure();
// datastream can be disabled/enabled only for Eiger 10GbE
if (detType == EIGER) {
if (!b) {
detectorDataStream[LEFT] = 1;
detectorDataStream[RIGHT] = 1;
} else {
detectorDataStream[LEFT] = detectorDataStream10GbE[LEFT];
detectorDataStream[RIGHT] = detectorDataStream10GbE[RIGHT];
}
LOG(logINFO) << "Detector datastream updated [Left: "
<< sls::ToString(detectorDataStream[LEFT])
<< ", Right: "
<< sls::ToString(detectorDataStream[RIGHT]) << "]";
}
}
LOG(logINFO) << "Ten Giga: " << (tengigaEnable ? "enabled" : "disabled");
LOG(logINFO) << "Packets per Frame: " << (generalData->packetsPerFrame);
@ -1532,9 +1547,9 @@ bool Implementation::getDetectorDataStream(const portPosition port) const {
void Implementation::setDetectorDataStream(const portPosition port,
const bool enable) {
int index = (port == LEFT ? 0 : 1);
detectorDataStream[index] = enable;
LOG(logINFO) << "Detector datastream (" << sls::ToString(port)
<< " Port): " << sls::ToString(detectorDataStream[index]);
detectorDataStream10GbE[index] = enable;
LOG(logINFO) << "Detector 10GbE datastream (" << sls::ToString(port)
<< " Port): " << sls::ToString(detectorDataStream10GbE[index]);
}
int Implementation::getReadNRows() const { return readNRows; }

View File

@ -356,6 +356,7 @@ class Implementation : private virtual slsDetectorDefs {
bool quadEnable{false};
bool activated{true};
std::array<bool, 2> detectorDataStream = {{true, true}};
std::array<bool, 2> detectorDataStream10GbE = {{true, true}};
int readNRows{0};
int thresholdEnergyeV{-1};
std::array<int, 3> thresholdAllEnergyeV = {{-1, -1, -1}};