mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-25 07:40:03 +02:00
somewhere
This commit is contained in:
parent
6da59ca382
commit
de2de6315c
@ -4974,11 +4974,15 @@ int multiSlsDetector::resetFramesCaught() {
|
|||||||
|
|
||||||
|
|
||||||
int multiSlsDetector::createReceivingDataThreads(bool destroy){
|
int multiSlsDetector::createReceivingDataThreads(bool destroy){
|
||||||
|
if(!destroy) cprintf(MAGENTA,"Going to create data threads\n");
|
||||||
|
else cprintf(MAGENTA,"Going to destroy data threads\n");
|
||||||
|
|
||||||
|
|
||||||
int numReadouts = thisMultiDetector->numberOfDetectors;
|
int numReadouts = thisMultiDetector->numberOfDetectors;
|
||||||
if(getDetectorsType() == EIGER)
|
if(getDetectorsType() == EIGER)
|
||||||
numReadouts *= 2;
|
numReadouts *= 2;
|
||||||
|
|
||||||
|
|
||||||
//reset masks
|
//reset masks
|
||||||
killAllReceivingDataThreads = false;
|
killAllReceivingDataThreads = false;
|
||||||
|
|
||||||
@ -5010,8 +5014,8 @@ int multiSlsDetector::createReceivingDataThreads(bool destroy){
|
|||||||
#endif
|
#endif
|
||||||
//reset current index
|
//reset current index
|
||||||
currentThreadIndex = -1;
|
currentThreadIndex = -1;
|
||||||
|
cout<<"numreadouts:"<<numReadouts<<endl;
|
||||||
for(int i = 0; i < numReadouts; ++i){
|
for(int i = 0; i < 1;++i){//numReadouts; ++i){
|
||||||
sem_init(&sem_singlewait[i],1,0);
|
sem_init(&sem_singlewait[i],1,0);
|
||||||
sem_init(&sem_singledone[i],1,0);
|
sem_init(&sem_singledone[i],1,0);
|
||||||
threadStarted = false;
|
threadStarted = false;
|
||||||
@ -5034,7 +5038,9 @@ int multiSlsDetector::createReceivingDataThreads(bool destroy){
|
|||||||
|
|
||||||
|
|
||||||
void* multiSlsDetector::startReceivingDataThread(void* this_pointer){
|
void* multiSlsDetector::startReceivingDataThread(void* this_pointer){
|
||||||
((multiSlsDetector*)this_pointer)->startReceivingDataThread();
|
//((multiSlsDetector*)this_pointer)->startReceivingDataThread();
|
||||||
|
while(true);
|
||||||
|
|
||||||
return this_pointer;
|
return this_pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5042,7 +5048,7 @@ void* multiSlsDetector::startReceivingDataThread(void* this_pointer){
|
|||||||
void multiSlsDetector::startReceivingDataThread(){
|
void multiSlsDetector::startReceivingDataThread(){
|
||||||
|
|
||||||
int ithread = currentThreadIndex; //set current thread value index
|
int ithread = currentThreadIndex; //set current thread value index
|
||||||
//cout << ithread << " thread created" << endl;
|
cprintf(BLUE,"thread created %d\n",ithread);
|
||||||
|
|
||||||
//number of readouts
|
//number of readouts
|
||||||
int numReadoutPerDetector = 1;
|
int numReadoutPerDetector = 1;
|
||||||
|
@ -481,7 +481,7 @@ void* postProcessing::processData(int delflag) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//receiver
|
//receiver
|
||||||
else{
|
else{cprintf(RED,"In post processing threads\n");
|
||||||
|
|
||||||
|
|
||||||
if(dataReady){
|
if(dataReady){
|
||||||
@ -517,7 +517,7 @@ void* postProcessing::processData(int delflag) {
|
|||||||
|
|
||||||
//cout<<"exiting from proccessing thread"<<endl;
|
//cout<<"exiting from proccessing thread"<<endl;
|
||||||
|
|
||||||
|
cprintf(RED,"Exiting post processing thread\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user