This commit is contained in:
2025-02-11 11:53:07 +01:00
parent 76ab0228ac
commit 505bf9642f
3 changed files with 14 additions and 6 deletions

View File

@ -2551,8 +2551,7 @@ int readSample(int ns) {
// read digital output
if (digitalEnable && ns < ndSamples) {
if (!(ns % 1000)) {
/*if (!(ns % 1000)) {
LOG(logDEBUG1,
("Reading sample ns:%d of %d DEmtpy:%d DFull:%d Status:0x%x\n",
ns, ndSamples,
@ -2563,6 +2562,15 @@ int readSample(int ns) {
FIFO_DIN_STATUS_FIFO_FULL_MSK) >>
FIFO_DIN_STATUS_FIFO_FULL_OFST),
bus_r(STATUS_REG)));
}*/
// wait for data
int fifoEmtpy = 1;
while (fifoEmtpy) {
fifoEmtpy = ((bus_r(FIFO_DIN_STATUS_REG) &
FIFO_DIN_STATUS_FIFO_EMPTY_MSK) >>
FIFO_DIN_STATUS_FIFO_EMPTY_OFST);
usleep(20);
}
// read fifo and write it to current position of data pointer

View File

@ -622,8 +622,8 @@ class ChipTestBoardData : public GeneralData {
readoutType == slsDetectorDefs::DIGITAL_AND_TRANSCEIVER) {
nDigitalChans = NCHAN_DIGITAL;
nDigitalBytes = (sizeof(uint64_t) * nDigitalSamples);
LOG(logDEBUG1) << "Number of Digital Channels:" << nDigitalChans
<< " Databytes: " << nDigitalBytes;
LOG(logINFORED) << "Number of Digital Channels:" << nDigitalChans
<< " Databytes: " << nDigitalBytes;
}
// transceiver channels
if (readoutType == slsDetectorDefs::TRANSCEIVER_ONLY ||
@ -643,8 +643,8 @@ class ChipTestBoardData : public GeneralData {
imageSize = nAnalogBytes + nDigitalBytes + nTransceiverBytes;
packetsPerFrame = ceil((double)imageSize / (double)dataSize);
LOG(logDEBUG1) << "Total Number of Channels:" << nPixelsX
<< " Databytes: " << imageSize;
LOG(logINFORED) << "Total Number of Channels:" << nPixelsX
<< " Databytes: " << imageSize;
};
};