diff --git a/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer b/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer index b77199c10..7fed40ec4 100755 Binary files a/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer and b/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServer_developer differ diff --git a/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c b/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c index 26e951a46..b8d0f2f07 100644 --- a/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c @@ -487,9 +487,11 @@ int adcPhase(int st){ /**carlos needed clkphase 1 and 2? cehck with Aldo */ printf("Setting ADC Phase to %d\n",st); if (st > 65535 || st < -65535) return clkPhase[0]; - clkPhase[1] = st - clkPhase[0]; - printf(" phase %d\n", clkPhase[1] ); + clkPhase[1] = st - clkPhase[0]; + if (clkPhase[1] == 0) + return clkPhase[0]; + configurePll(); clkPhase[0] = st; return clkPhase[0]; @@ -1249,7 +1251,7 @@ void configurePll() { u_int32_t val; int32_t phase=0, inv=0; - printf(" phase in %d\n", clkPhase[1]); + printf("Configuring PLL with phase in %d\n", clkPhase[1]); if (clkPhase[1]>0) { inv=0; phase=clkPhase[1]; diff --git a/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp b/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp index e5fe9c137..f99f69747 100644 --- a/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp +++ b/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp @@ -5829,9 +5829,7 @@ string slsDetectorCommand::cmdSpeed(int narg, char *args[], int action) { return string("cannot scan speed value ")+string(args[1]); } - // -1 could work - else if (cmd=="adcphase") - t = 65536; + myDet->setOnline(ONLINE_FLAG); diff --git a/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c b/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c index 4da1ae734..5dca4b587 100755 --- a/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c +++ b/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c @@ -3167,7 +3167,7 @@ int set_speed(int file_des) { #ifdef JUNGFRAUD case ADC_PHASE: retval = adcPhase(val); - if ((val != 65536) && (retval!=val) && (val>=0)) { + if ((val != 100000) && (retval!=val) && (val>=0)) { ret=FAIL; sprintf(mess,"could not change set adc phase: should be %d but is %d \n", val, retval); cprintf(RED, "Warning: %s", mess);