diff --git a/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c b/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c index ee2771699..c6ed49d63 100755 --- a/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c +++ b/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c @@ -1623,7 +1623,7 @@ int getAdcConfigured(){ } u_int32_t runBusy(void) { - u_int32_t s = bus_r(STATUS_REG); + u_int32_t s = bus_r(STATUS_REG) & RUN_BUSY_BIT; return s; } diff --git a/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt b/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt index 331da9c31..859caa9c9 100644 --- a/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt +++ b/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt @@ -1,9 +1,9 @@ Path: slsDetectorsPackage/slsDetectorSoftware/gotthardDetectorServer URL: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git Repository Root: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git -Repsitory UUID: e4fa807b5d987714a047b9d2cac271c89f6c2fef -Revision: 208 -Branch: developer +Repsitory UUID: c5777e517c451226e3275e6948895baee21a1f94 +Revision: 210 +Branch: gotthardfix Last Changed Author: Dhanya_Maliakal -Last Changed Rev: 1487 -Last Changed Date: 2017-08-16 16:01:46.000000002 +0200 ./firmware_funcs.c +Last Changed Rev: 1585 +Last Changed Date: 2017-11-09 13:57:04.000000002 +0100 ./server_funcs.c diff --git a/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h b/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h index f5a2ab5e4..93af5c534 100644 --- a/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h +++ b/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h @@ -1,11 +1,11 @@ //#define SVNPATH "" #define SVNURL "git@git.psi.ch:sls_detectors_software/sls_detector_software.git" //#define SVNREPPATH "" -#define SVNREPUUID "e4fa807b5d987714a047b9d2cac271c89f6c2fef" -//#define SVNREV 0x1487 +#define SVNREPUUID "c5777e517c451226e3275e6948895baee21a1f94" +//#define SVNREV 0x1585 //#define SVNKIND "" //#define SVNSCHED "" #define SVNAUTH "Dhanya_Maliakal" -#define SVNREV 0x1487 -#define SVNDATE 0x20170816 +#define SVNREV 0x1585 +#define SVNDATE 0x20171109 // diff --git a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 deleted file mode 100755 index e802907cb..000000000 Binary files a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 and /dev/null differ diff --git a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.6 b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.6 new file mode 100755 index 000000000..f14fa775b Binary files /dev/null and b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.6 differ diff --git a/slsDetectorSoftware/gotthardDetectorServer/registers_g.h b/slsDetectorSoftware/gotthardDetectorServer/registers_g.h index f22222dbe..ddb29bedf 100755 --- a/slsDetectorSoftware/gotthardDetectorServer/registers_g.h +++ b/slsDetectorSoftware/gotthardDetectorServer/registers_g.h @@ -185,6 +185,7 @@ #define ALL_FIFO_EMPTY_BIT 0x00010000 // data ready #define RUNMACHINE_BUSY_BIT 0x00020000 #define READMACHINE_BUSY_BIT 0x00040000 +#define STOPPED_BIT 0x00100000 diff --git a/slsDetectorSoftware/gotthardDetectorServer/server_funcs.c b/slsDetectorSoftware/gotthardDetectorServer/server_funcs.c index 844b2d86f..309b3ebda 100755 --- a/slsDetectorSoftware/gotthardDetectorServer/server_funcs.c +++ b/slsDetectorSoftware/gotthardDetectorServer/server_funcs.c @@ -1812,11 +1812,29 @@ int get_run_status(int file_des) { retval= runState(); printf("\n\nSTATUS=%08x\n",retval); + + //stopped (external stop, also maybe fifo full) + if (runState() & STOPPED_BIT){ + printf("-----------------------------------STOPPED--------------------------------------x%0x\n",retval); + s=STOPPED; + + retval= runState(); + printf("reading again STATUS=%08x\n",retval); + if (runState() & STOPPED_BIT){ + printf("-----------------------------------ERROR--------------------------------------x%0x\n",retval); + s=ERROR; + } + } + + + //error - if(retval&SOME_FIFO_FULL_BIT){ + else if(retval&SOME_FIFO_FULL_BIT){ printf("-----------------------------------ERROR--------------------------------------x%0x\n",retval); s=ERROR; } + + //runbusy=0 // else if(!(retval&RUNMACHINE_BUSY_BIT)){ //commented by Anna 24.10.2012 else if(!(retval&RUN_BUSY_BIT)){ // by Anna 24.10.2012