diff --git a/slsDetectorSoftware/eigerDetectorServer/FebControl.c b/slsDetectorSoftware/eigerDetectorServer/FebControl.c index b8b6ff4bd..7f4795712 100644 --- a/slsDetectorSoftware/eigerDetectorServer/FebControl.c +++ b/slsDetectorSoftware/eigerDetectorServer/FebControl.c @@ -190,8 +190,8 @@ int Feb_Control_Init(int master, int top){ //get serial int serial=1; switch(Feb_Control_module_number){ - case 34: serial = 0; break; //martin - case 31: serial = 0; break; //dhanya + case 34: serial = 0; break; //martin half + case 31: serial = 0; break; //martin case 26: serial = 0; break; //leo case 32: serial = 1; break; case 24: serial = 2; break; diff --git a/slsDetectorSoftware/eigerDetectorServer/Makefile b/slsDetectorSoftware/eigerDetectorServer/Makefile index 26b190032..046fd22eb 100755 --- a/slsDetectorSoftware/eigerDetectorServer/Makefile +++ b/slsDetectorSoftware/eigerDetectorServer/Makefile @@ -1,6 +1,6 @@ CC = powerpc-4xx-softfloat-gcc CCX = powerpc-4xx-softfloat-g++ -CFLAGS += -Wall -DDACS_INT -DEIGERD -DSLS_DETECTOR_FUNCTION_LIST -DDACS_INT #-DSTOP_SERVER #-DVERBOSE #-DVIRTUAL -DPCCOMPILE +CFLAGS += -Wall -DDACS_INT -DEIGERD -DSLS_DETECTOR_FUNCTION_LIST -DDACS_INT -DSTOP_SERVER #-DVERBOSE #-DVIRTUAL -DPCCOMPILE LDLIBS += -lm -lstdc++ PROGS = eigerDetectorServer diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer index 5abcad5af..3736d5932 100755 Binary files a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer and b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer differ diff --git a/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c index 0648b116b..9fa1127ae 100644 --- a/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c @@ -149,6 +149,7 @@ int initDetector(){ int initDetectorStop(){ getModuleConfiguration(); Feb_Interface_FebInterface(); + Feb_Control_FebControl(); Feb_Control_Init(master,top); printf("FEB Initialization done\n"); /* Beb_Beb(-1); diff --git a/slsDetectorSoftware/slsDetectorAnalysis/postProcessing.cpp b/slsDetectorSoftware/slsDetectorAnalysis/postProcessing.cpp index c689d3f99..1ca44fb1e 100644 --- a/slsDetectorSoftware/slsDetectorAnalysis/postProcessing.cpp +++ b/slsDetectorSoftware/slsDetectorAnalysis/postProcessing.cpp @@ -532,26 +532,33 @@ void* postProcessing::processData(int delflag) { //updating progress if(currentfIndex != -1) setCurrentProgress(currentfIndex+1); - - /** IF detector acquisition is done, let the acquire() thread know to finish up and force join thread */ - if(acquiringDone == 1){ #ifdef VERY_VERY_DEBUG - cout << "acquiring seems to be done" << endl; + cout << "currentfIndex:" << currentfIndex << endl; #endif - //so that only once it checks for last frame and then next time, checks join thread + /** IF detector acquisition is done, let the acquire() thread know to finish up and force join thread */ + if(acquiringDone > 0){ +#ifdef VERY_VERY_DEBUG + if(acquiringDone == 1) + cout << "acquiring seems to be done" << endl; +#endif + //so that it checks for last frame for some number of checks, then checks join thread pthread_mutex_lock(&mg); - acquiringDone = 2; + acquiringDone++; +#ifdef VERY_VERY_DEBUG + cout << "acquiringDone :" << acquiringDone << endl; +#endif pthread_mutex_unlock(&mg); //newData = true; - }else if (acquiringDone == 2){ + if (acquiringDone == 10){//for eiger, it is very slow, have to wait long to get last frame #ifdef VERY_VERY_DEBUG - cout << "gonna post for it to end" << endl; + cout << "gonna post for it to end" << endl; #endif - sem_post(&sem_queue); + sem_post(&sem_queue); #ifdef VERY_VERY_DEBUG - cout << "Sem posted" << endl; + cout << "Sem posted" << endl; #endif - //newData = false; + //newData = false; + } }else if (checkJoinThread()) break;