slsDetectorSoftware & eiger server: fixed coordinates in 2 d, but switch to row (x), col(y); numdetx and numdety sent to all receivers now, likely bug fix virtual file linked in master for 1 mod jungfrau; xccoord and y coord calculated at setdetector pos and given to listener

This commit is contained in:
2018-08-15 19:02:16 +02:00
parent b3ccd5e1a1
commit 87e8333dfd
13 changed files with 156 additions and 98 deletions

View File

@ -424,6 +424,18 @@ void UDPStandardImplementation::setDetectorPositionId(const int i){
&detID, &numThreads, &numberOfFrames, &dynamicRange, &udpPortNum[i],
generalData);
}
for (unsigned int i = 0; i < listener.size(); ++i) {
uint16_t x = 0, y = 0;
if (myDetectorType == EIGER || myDetectorType == JUNGFRAU) {
x = detID % numDet[1]; // row
y = (detID / numDet[1]) * ((myDetectorType == EIGER) ? 2 : 1) + i; // col for horiz. udp ports
}
// calculate x in 1d
else
x = detID * numThreads + i;
listener[i]->SetHardCodedCoords(x,y);
}
}