diff --git a/slsDetectorSoftware/.gitignore b/slsDetectorSoftware/.gitignore index 752a00776..fc05915b5 100644 --- a/slsDetectorSoftware/.gitignore +++ b/slsDetectorSoftware/.gitignore @@ -1,3 +1,3 @@ *.o *~ -#*# \ No newline at end of file +#*# diff --git a/slsDetectorSoftware/Makefile b/slsDetectorSoftware/Makefile index 7c8f501ad..850edef3f 100644 --- a/slsDetectorSoftware/Makefile +++ b/slsDetectorSoftware/Makefile @@ -2,7 +2,6 @@ include ../Makefile.include DESTDIR ?= ../bin LIBDIR ?= $(DESTDIR) -DOCDIR ?= docs CFLAGS= -g -DC_ONLY -fPIC @@ -33,34 +32,10 @@ $(info ) OBJS = $(SRC_CLNT:%.cpp=%.o) -.PHONY: all intdoc doc htmldoc package clean +.PHONY: all package clean all: package $(SRC_CLNT) -intdoc: $(SRC_H) $(SRC_CLNT) - doxygen doxy.config - -doc: $(DOCDIR)/pdf/slsDetectorUsersDocs.pdf - -$(DOCDIR)/pdf/slsDetectorUsersDocs.pdf: slsDetectorUsersDocs - cd slsDetectorUsersDocs/latex && make - $(shell test -d $(DOCDIR) || mkdir -p $(DOCDIR)) - $(shell test -d $(DOCDIR)/pdf || mkdir -p $(DOCDIR)/pdf) - cp slsDetectorUsersDocs/latex/refman.pdf $(DOCDIR)/pdf/slsDetectorUsersDocs.pdf - - -htmldoc: $(DOCDIR)/html/slsDetectorUsersDocs - -$(DOCDIR)/html/slsDetectorUsersDocs: slsDetectorUsersDocs - $(shell test -d $(DOCDIR) || mkdir -p $(DOCDIR)) - $(shell test -d $(DOCDIR)/html || mkdir -p $(DOCDIR)/html) - $(shell test -d $(DOCDIR)/html/slsDetectorUsersDocs && rm -r $(DOCDIR)/html/slsDetectorUsersDocs) - cp -r slsDetectorUsersDocs/html $(DOCDIR)/html/slsDetectorUsersDocs - -slsDetectorUsersDocs: slsDetectorUsers.doxy slsDetector/slsDetectorUsers.h slsDetector/slsDetectorUsers.cpp slsDetectorAnalysis/detectorData.h - doxygen slsDetectorUsers.doxy - - mythenVirtualServer: $(SRC_MYTHEN_SVC) cd mythenDetectorServer && make -f Makefile.virtual DESTDIR=$(DESTDIR) @@ -90,7 +65,7 @@ $(DESTDIR)/libSlsDetector.a: $(OBJS) mv libSlsDetector.a $(DESTDIR) clean: - rm -rf $(DESTDIR)/libSlsDetector.a $(DESTDIR)/libSlsDetector.so core docs/* slsDetectorUsersDocs $(OBJS) + rm -rf $(DESTDIR)/libSlsDetector.a $(DESTDIR)/libSlsDetector.so core $(OBJS) cd diff --git a/slsDetectorSoftware/doxy.config b/slsDetectorSoftware/doxy.config new file mode 100644 index 000000000..9dec99861 --- /dev/null +++ b/slsDetectorSoftware/doxy.config @@ -0,0 +1,164 @@ +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. +# Private class members and static file members will be hidden unless +# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES + +EXTRACT_ALL = YES + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class +# will be included in the documentation. + +EXTRACT_PRIVATE = NO + + + +# If the EXTRACT_STATIC tag is set to YES all static members of a file +# will be included in the documentation. + +EXTRACT_STATIC = YES + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) +# defined locally in source files will be included in the documentation. +# If set to NO only classes defined in header files are included. + +EXTRACT_LOCAL_CLASSES = YES + +# This flag is only useful for Objective-C code. When set to YES local +# methods, which are defined in the implementation section but not in +# the interface are included in the documentation. +# If set to NO (the default) only methods in the interface are included. + +EXTRACT_LOCAL_METHODS = YES + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base +# name of the file that contains the anonymous namespace. By default +# anonymous namespace are hidden. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all +# undocumented members of documented classes, files or namespaces. +# If set to NO (the default) these members will be included in the +# various overviews, but no documentation section is generated. +# This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. +# If set to NO (the default) these classes will be included in the various +# overviews. This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all +# friend (class|struct|union) declarations. +# If set to NO (the default) these declarations will be included in the +# documentation. + +HIDE_FRIEND_COMPOUNDS = NO + +INTERNAL_DOCS = NO + +SHOW_INCLUDE_FILES = NO + +SHOW_FILES = NO + +SHOW_NAMESPACES = NO + +COMPACT_LATEX = YES + +PAPER_TYPE = a4 + +PDF_HYPERLINKS = YES + +USE_PDFLATEX = YES + +LATEX_HIDE_INDICES = YES + +PREDEFINED = __cplusplus + +INPUT = commonFiles/communication_funcs.h \ + commonFiles/error_defs.h \ + commonFiles/sls_detector_defs.h \ + commonFiles/sls_detector_funcs.h \ + f90Interface/externPostProcessing.h \ + multiSlsDetector/multiSlsDetectorClient.h \ + multiSlsDetector/multiSlsDetectorCommand.h \ + multiSlsDetector/multiSlsDetector.h \ + slsDetector/slsDetectorActions.h \ + slsDetector/slsDetectorBase.h \ + slsDetector/slsDetectorCommand.h \ + slsDetector/slsDetector.h \ + slsDetector/slsDetectorUsers.h \ + slsDetector/slsDetectorUtils.h \ + slsDetectorAnalysis/angCalLogClass.h \ + slsDetectorAnalysis/angleConversionConstant.h \ + slsDetectorAnalysis/angularCalibration.h \ + slsDetectorAnalysis/angularConversion.h \ + slsDetectorAnalysis/AngularConversion_Standalone.h \ + slsDetectorAnalysis/angularConversionStatic.h \ + slsDetectorAnalysis/badChannelCorrections.h \ + slsDetectorAnalysis/detectorData.h \ + slsDetectorAnalysis/enCalLogClass.h \ + slsDetectorAnalysis/energyCalibration.h \ + slsDetectorAnalysis/energyConversion.h \ + slsDetectorAnalysis/fileIO.h \ + slsDetectorAnalysis/FileIO_Standalone.h \ + slsDetectorAnalysis/fileIOStatic.h \ + slsDetectorAnalysis/movingStat.h \ + slsDetectorAnalysis/postProcessingFileIO_Standalone.h \ + slsDetectorAnalysis/postProcessingFuncs.h \ + slsDetectorAnalysis/postProcessing.h \ + slsDetectorAnalysis/postProcessing_Standalone.h \ + slsDetectorAnalysis/runningStat.h \ + slsDetectorAnalysis/singlePhotonFilter.h \ + slsDetectorAnalysis/single_photon_hit.h \ + slsDetectorAnalysis/TSlsDetectorDict.h \ + slsReceiverInterface/receiverInterface.h \ + threadFiles/CondVar.h \ + threadFiles/Global.h \ + threadFiles/Multi.h \ + threadFiles/Mutex.h \ + threadFiles/Single.h \ + threadFiles/Task.h \ + threadFiles/ThreadPool.h \ + usersFunctions/angleFunction.h \ + usersFunctions/usersFunctions.h \ + ../slsReceiverSoftware/include/ansi.h \ + ../slsReceiverSoftware/include/BinaryFile.h \ + ../slsReceiverSoftware/include/BinaryFileStatic.h \ + ../slsReceiverSoftware/include/circularFifo.h \ + ../slsReceiverSoftware/include/DataProcessor.h \ + ../slsReceiverSoftware/include/DataStreamer.h \ + ../slsReceiverSoftware/include/Fifo.h \ + ../slsReceiverSoftware/include/File.h \ + ../slsReceiverSoftware/include/GeneralData.h \ + ../slsReceiverSoftware/include/genericSocket.h \ + ../slsReceiverSoftware/include/HDF5File.h \ + ../slsReceiverSoftware/include/HDF5FileStatic.h \ + ../slsReceiverSoftware/include/Listener.h \ + ../slsReceiverSoftware/include/logger.h \ + ../slsReceiverSoftware/include/MySocketTCP.h \ + ../slsReceiverSoftware/include/receiver_defs.h \ + ../slsReceiverSoftware/include/RestHelper.h \ + ../slsReceiverSoftware/include/sls_receiver_defs.h \ + ../slsReceiverSoftware/include/sls_receiver_funcs.h \ + ../slsReceiverSoftware/include/slsReceiver.h \ + ../slsReceiverSoftware/include/slsReceiverTCPIPInterface.h \ + ../slsReceiverSoftware/include/slsReceiverUsers.h \ + ../slsReceiverSoftware/include/ThreadObject.h \ + ../slsReceiverSoftware/include/UDPBaseImplementation.h \ + ../slsReceiverSoftware/include/UDPInterface.h \ + ../slsReceiverSoftware/include/UDPRESTImplementation.h \ + ../slsReceiverSoftware/include/UDPStandardImplementation.h \ + ../slsReceiverSoftware/include/utilities.h \ + ../slsReceiverSoftware/include/ZmqSocket.h + + + + +OUTPUT_DIRECTORY = slsDetectorPackageDocs + diff --git a/slsDetectorSoftware/eigerDetectorServer/9mhvserial_bf.c b/slsDetectorSoftware/eigerDetectorServer/9mhvserial_bf.c index 9cf2290ba..0746c4ac1 100644 --- a/slsDetectorSoftware/eigerDetectorServer/9mhvserial_bf.c +++ b/slsDetectorSoftware/eigerDetectorServer/9mhvserial_bf.c @@ -95,6 +95,7 @@ int main(int argc, char* argv[]) { cprintf(RED,"Warning: Unable to open port %s\n", PORTNAME); return -1; } + cprintf(GREEN,"opened port at %s\n",PORTNAME); struct termios serial_conf; // reset structure @@ -131,23 +132,6 @@ int main(int argc, char* argv[]) { buffer[BUFFERSIZE-1] = '\n'; cprintf(GREEN,"Ready...\n"); - /* - int once = 1; - while(strcmp(buffer,"start")){ - if(once){ - once=0; - cprintf(MAGENTA,"in the loop, checking\n"); - } - memset(buffer,0,BUFFERSIZE); - n = read(fd,buffer,BUFFERSIZE); - //#ifdef VERBOSE - cprintf(BLUE,"Received %d Bytes\n", n); - //#endif - cprintf(BLUE,"Got message: %s\n",buffer); - } - cprintf(GREEN,"started\n"); - */ - while(ret != GOODBYE){ memset(buffer,0,BUFFERSIZE); @@ -155,9 +139,15 @@ int main(int argc, char* argv[]) { #ifdef VERBOSE cprintf(BLUE,"Received %d Bytes\n", n); #endif - cprintf(BLUE,"Got message: %s\n",buffer); + cprintf(BLUE,"Got message: '%s'\n",buffer); switch(buffer[0]){ + case '\0': + cprintf(GREEN,"Got Start (Detector restart)\n"); + break; + case 's': + cprintf(GREEN,"Got Start \n"); + break; case 'p': if (!sscanf(&buffer[1],"%d",&ival)){ cprintf(RED,"Warning: cannot scan voltage value\n"); @@ -170,10 +160,10 @@ int main(int argc, char* argv[]) { strcpy(buffer,"fail "); else strcpy(buffer,"success "); - cprintf(GREEN,"%s\n",buffer); + cprintf(GREEN,"Sending: '%s'\n",buffer); n = write(fd, buffer, BUFFERSIZE); #ifdef VERBOSE - cprintf(BLUE,"Sent %d Bytes\n", n); + cprintf(GREEN,"Sent %d Bytes\n", n); #endif break; @@ -187,20 +177,21 @@ int main(int argc, char* argv[]) { else strcpy(buffer,"success "); n = write(fd, buffer, BUFFERSIZE); + cprintf(GREEN,"Sending: '%s'\n",buffer); #ifdef VERBOSE - cprintf(BLUE,"Sent %d Bytes\n", n); + cprintf(GREEN,"Sent %d Bytes\n", n); #endif //value memset(buffer,0,BUFFERSIZE); buffer[BUFFERSIZE-1] = '\n'; if(ival >= 0){ - cprintf(GREEN,"%d\n",ival); + cprintf(GREEN,"Sending: '%d'\n",ival); sprintf(buffer,"%d ",ival); n = write(fd, buffer, BUFFERSIZE); #ifdef VERBOSE - cprintf(BLUE,"Sent %d Bytes\n", n); + cprintf(GREEN,"Sent %d Bytes\n", n); #endif - }else cprintf(GREEN,"%s\n",buffer); + }else cprintf(RED,"%s\n",buffer); break; case 'e': @@ -208,7 +199,7 @@ int main(int argc, char* argv[]) { ret = GOODBYE; break; default: - printf("Unknown Command. buffer:[%s]\n",buffer); + cprintf(RED,"Unknown Command. buffer:'%s'\n",buffer); break; } } diff --git a/slsDetectorSoftware/eigerDetectorServer/FebControl.c b/slsDetectorSoftware/eigerDetectorServer/FebControl.c index 76028a105..300a92bc9 100644 --- a/slsDetectorSoftware/eigerDetectorServer/FebControl.c +++ b/slsDetectorSoftware/eigerDetectorServer/FebControl.c @@ -224,7 +224,7 @@ int Feb_Control_Init(int master, int top, int normal, int module_num){ int Feb_Control_OpenSerialCommunication(){ - cprintf(BG_BLUE,"opening serial communication of hv\n"); + cprintf(GREEN,"opening serial communication of hv\n"); //if(Feb_Control_hv_fd != -1) close(Feb_Control_hv_fd); Feb_Control_hv_fd = open(SPECIAL9M_HIGHVOLTAGE_PORT, O_RDWR | O_NOCTTY | O_SYNC); @@ -232,7 +232,7 @@ int Feb_Control_OpenSerialCommunication(){ cprintf(RED,"Warning: Unable to open port %s to set up high voltage serial communciation to the blackfin\n", SPECIAL9M_HIGHVOLTAGE_PORT); return 0; } - + cprintf(GREEN,"Serial Port opened at %s\n",SPECIAL9M_HIGHVOLTAGE_PORT); struct termios serial_conf; // reset structure memset (&serial_conf, 0, sizeof(serial_conf)); @@ -259,18 +259,21 @@ int Feb_Control_OpenSerialCommunication(){ return 0; } - /* - //send start + + //send the first message (which will be garbled up) char buffer[SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE]; memset(buffer,0,SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE); buffer[SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE-1] = '\n'; strcpy(buffer,"start"); + cprintf(GREEN,"sending start: '%s'\n",buffer); int n = write(Feb_Control_hv_fd, buffer, SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE); if (n < 0) { cprintf(RED,"\nWarning: Error writing to i2c bus\n"); return 0; } -*/ +#ifdef VERBOSE + cprintf(GREEN,"Sent: %d bytes\n",n); +#endif return 1; } @@ -629,13 +632,14 @@ int Feb_Control_SendHighVoltage(int dacvalue){ buffer[SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE-1]='\n'; int n; sprintf(buffer,"p%d",dacvalue); + cprintf(GREEN,"Sending HV: '%s'\n",buffer); n = write(Feb_Control_hv_fd, buffer, SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE); if (n < 0) { cprintf(RED,"\nWarning: Error writing to i2c bus\n"); return 0; } #ifdef VERBOSEI - cprintf(BLUE,"Sent %d Bytes\n", n); + cprintf(GREEN,"Sent %d Bytes\n", n); #endif //ok/fail memset(buffer,0,SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE); @@ -646,8 +650,9 @@ int Feb_Control_SendHighVoltage(int dacvalue){ return 0; } #ifdef VERBOSEI - cprintf(BLUE,"Received %d Bytes\n", n); + cprintf(GREEN,"Received %d Bytes\n", n); #endif + cprintf(GREEN,"Received HV: '%s'\n",buffer); fflush(stdout); /*Feb_Control_CloseSerialCommunication();*/ if(buffer[0] != 's'){ @@ -715,13 +720,14 @@ int Feb_Control_ReceiveHighVoltage(unsigned int* value){ //request strcpy(buffer,"g "); + cprintf(GREEN,"\nSending HV: '%s'\n",buffer); n = write(Feb_Control_hv_fd, buffer, SPECIAL9M_HIGHVOLTAGE_BUFFERSIZE); if (n < 0) { cprintf(RED,"\nWarning: Error writing to i2c bus\n"); return 0; } #ifdef VERBOSEI - cprintf(BLUE,"Sent %d Bytes\n", n); + cprintf(GREEN,"Sent %d Bytes\n", n); #endif //ok/fail @@ -733,8 +739,9 @@ int Feb_Control_ReceiveHighVoltage(unsigned int* value){ return 0; } #ifdef VERBOSEI - cprintf(BLUE,"Received %d Bytes\n", n); + cprintf(GREEN,"Received %d Bytes\n", n); #endif + cprintf(GREEN,"Received HV: '%s'\n",buffer); if(buffer[0] != 's'){ cprintf(RED,"\nWarning: failed to read high voltage\n"); return 0; @@ -748,8 +755,9 @@ int Feb_Control_ReceiveHighVoltage(unsigned int* value){ return 0; } #ifdef VERBOSEI - cprintf(BLUE,"Received %d Bytes\n", n); + cprintf(GREEN,"Received %d Bytes\n", n); #endif + cprintf(GREEN,"Received HV: '%s'\n",buffer); /*Feb_Control_OpenSerialCommunication();*/ if (!sscanf(buffer,"%d",value)){ cprintf(RED,"\nWarning: failed to scan high voltage read\n"); @@ -1805,7 +1813,7 @@ int Feb_Control_SetRateCorrectionTau(int64_t tau_in_Nsec){ if(Feb_Control_SetRateCorrectionTable(Feb_Control_rate_correction_table)){ Feb_Control_RateTable_Tau_in_nsec = tau_in_Nsec; - Feb_Control_RateTable_Period_in_nsec = period_in_sec; + Feb_Control_RateTable_Period_in_nsec = period_in_sec*1e9; return 1; }else{ Feb_Control_RateTable_Tau_in_nsec = -1; diff --git a/slsDetectorSoftware/eigerDetectorServer/Makefile.virtual b/slsDetectorSoftware/eigerDetectorServer/Makefile.virtual index 9d3bc6223..ceff1fc75 100644 --- a/slsDetectorSoftware/eigerDetectorServer/Makefile.virtual +++ b/slsDetectorSoftware/eigerDetectorServer/Makefile.virtual @@ -1,28 +1,28 @@ -CC = gcc -CFLAGS += -Wall -DDACS_INT -DEIGERD -DDACS_INT -DPCCOMPILE -DSLS_DETECTOR_FUNCTION_LIST #-DSTOP_SERVER #-DVERBOSE #-DVIRTUAL -DPCCOMPILE -LDLIBS += -lm -lstdc++ +CC = gcc +CFLAGS += -Wall -DDACS_INT -DEIGERD -DSLS_DETECTOR_FUNCTION_LIST -DDACS_INT -DPCCOMPILE -DSTOP_SERVER #-DVERBOSE +CFLAGS += -DVIRTUAL -DVIRTUAL_9M +MASTERFLAG += -DVIRTUAL_MASTER +LDLIBS += -lm -lstdc++ -pthread -PROGS = eigerDetectorServerVirtual -DESTDIR ?= bin -INSTMODE = 0777 +DESTDIR ?= bin -SRC_CLNT = communication_funcs.c slsDetectorServer.c slsDetectorServer_funcs.c slsDetectorFunctionList.c -#SRC_CLNT2 = Eiger.cxx HardwareIO.cxx LocalLinkInterface.cxx Feb.cxx -OBJS = $(SRC_CLNT:.c=.o) -OBJS2 = $(SRC_CLNT2:.cpp=.o) +SRC_CLNT = communication_funcs.c slsDetectorServer.c slsDetectorServer_funcs.c slsDetectorFunctionList_virtual.c -all: clean $(PROGS) + +all: clean master slave -boot: $(OBJS) $(OBJS2) - -$(PROGS): - echo $(OBJS) $(OBJS2) +master: $(SRC_CLNT) mkdir -p $(DESTDIR) - $(CC) -o $@ $(SRC_CLNT) $(CFLAGS) $(LDLIBS) - mv $(PROGS) $(DESTDIR) + $(CC) -o eigerDetectorServer_virtualMaster $(SRC_CLNT) $(CFLAGS) $(MASTERFLAG) $(LDLIBS) + mv eigerDetectorServer_virtualMaster $(DESTDIR) + +slave: $(SRC_CLNT) + mkdir -p $(DESTDIR) + $(CC) -o eigerDetectorServer_virtualSlave $(SRC_CLNT) $(CFLAGS) $(LDLIBS) + mv eigerDetectorServer_virtualSlave $(DESTDIR) clean: - rm -rf $(DESTDIR)/$(PROGS) *.o + rm -rf $(DESTDIR)/eigerDetectorServer_virtualMaster $(DESTDIR)/eigerDetectorServer_virtualSlave *.o \ No newline at end of file diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerVirtual b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerVirtual deleted file mode 100755 index 7a8d32b62..000000000 Binary files a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerVirtual and /dev/null differ diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualMaster b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualMaster new file mode 100755 index 000000000..934f86b70 Binary files /dev/null and b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualMaster differ diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualSlave b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualSlave new file mode 100755 index 000000000..b92f53b65 Binary files /dev/null and b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServer_virtualSlave differ diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.6 b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.9 similarity index 67% rename from slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.6 rename to slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.9 index 1d201568e..6cbc0d41a 100755 Binary files a/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.6 and b/slsDetectorSoftware/eigerDetectorServer/bin/eigerDetectorServerv3.0.0.16.9 differ diff --git a/slsDetectorSoftware/eigerDetectorServer/bin/hv9m_blackfin_serverv3.0.0.1 b/slsDetectorSoftware/eigerDetectorServer/bin/hv9m_blackfin_serverv3.0.0.1 new file mode 100755 index 000000000..4ab730239 Binary files /dev/null and b/slsDetectorSoftware/eigerDetectorServer/bin/hv9m_blackfin_serverv3.0.0.1 differ diff --git a/slsDetectorSoftware/eigerDetectorServer/gitInfo.txt b/slsDetectorSoftware/eigerDetectorServer/gitInfo.txt index 5314965df..f66bf01f0 100644 --- a/slsDetectorSoftware/eigerDetectorServer/gitInfo.txt +++ b/slsDetectorSoftware/eigerDetectorServer/gitInfo.txt @@ -1,9 +1,9 @@ Path: slsDetectorsPackage/slsDetectorSoftware/eigerDetectorServer 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: 2dfbd9016b501eca6ee2c00a08e49a3f7e7990d8 -Revision: 296 -Branch: 3.0-rc +Repsitory UUID: 3c1eb747d1930d6d38030a5a607f72d3b58a7a21 +Revision: 301 +Branch: virtualclass Last Changed Author: Dhanya_Maliakal -Last Changed Rev: 1457 -Last Changed Date: 2017-08-08 15:23:10.000000002 +0200 ./Makefile +Last Changed Rev: 1549 +Last Changed Date: 2017-08-30 15:06:49.000000002 +0200 ./Makefile.virtual diff --git a/slsDetectorSoftware/eigerDetectorServer/gitInfoEiger.h b/slsDetectorSoftware/eigerDetectorServer/gitInfoEiger.h index c01ec39e8..9f01077eb 100644 --- a/slsDetectorSoftware/eigerDetectorServer/gitInfoEiger.h +++ b/slsDetectorSoftware/eigerDetectorServer/gitInfoEiger.h @@ -1,11 +1,11 @@ //#define SVNPATH "" #define SVNURL "git@git.psi.ch:sls_detectors_software/sls_detector_software.git" //#define SVNREPPATH "" -#define SVNREPUUID "2dfbd9016b501eca6ee2c00a08e49a3f7e7990d8" -//#define SVNREV 0x1457 +#define SVNREPUUID "3c1eb747d1930d6d38030a5a607f72d3b58a7a21" +//#define SVNREV 0x1549 //#define SVNKIND "" //#define SVNSCHED "" #define SVNAUTH "Dhanya_Maliakal" -#define SVNREV 0x1457 -#define SVNDATE 0x20170808 +#define SVNREV 0x1549 +#define SVNDATE 0x20170830 // diff --git a/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c index 9ab1467ab..44e15b469 100644 --- a/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList.c @@ -299,6 +299,12 @@ void allocateDetectorStructureMemory(){ (detectorModules)->offset=0; (detectorModules)->reg=0; thisSettings = UNINITIALIZED; + + // if trimval requested, should return -1 to acknowledge unknown + int ichan=0; + for (ichan=0; ichan<(detectorModules->nchan); ichan++) { + *((detectorModules->chanregs)+ichan) = -1; + } } @@ -554,7 +560,7 @@ int setModule(sls_detector_module myMod, int delay){ if(myMod.nchan==0 && myMod.nchip == 0) cprintf(BLUE,"Setting module without trimbits\n"); else{ - cprintf(GREEN,"Setting module with trimbits\n"); + printf("Setting module with trimbits\n"); //includ gap pixels unsigned int tt[263680]; int iy,ichip,ix,ip=0,ich=0; @@ -609,7 +615,7 @@ int getModule(sls_detector_module *myMod){ //copy to local copy as well if (detectorModules) - copyModule(myMod,detectorModules); + copyModule(detectorModules,myMod); else return FAIL; return OK; @@ -1063,11 +1069,24 @@ int setAllTrimbits(int val){ } } } + cprintf(GREEN, "All trimbits have been set to %d\n", val); return OK; } int getAllTrimbits(){ - return *((detectorModules->chanregs)); + int ichan=0; + int value = *((detectorModules->chanregs)); + if (detectorModules){ + for (ichan=0; ichan<(detectorModules->nchan); ichan++) { + if(*((detectorModules->chanregs)+ichan) != value) { + value= -1; + break; + } + + } + } + printf("Value of all Trimbits: %d\n", value); + return value; } int getBebFPGATemp(){ diff --git a/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList_virtual.c b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList_virtual.c new file mode 100644 index 000000000..4646182e7 --- /dev/null +++ b/slsDetectorSoftware/eigerDetectorServer/slsDetectorFunctionList_virtual.c @@ -0,0 +1,999 @@ +#ifdef SLS_DETECTOR_FUNCTION_LIST + + +#include +#include +#include //usleep +#include +#include + +#include "slsDetectorFunctionList.h" + + +int default_tau_from_file= -1; + +#define BEB_NUM 34 + +enum detectorSettings thisSettings; +const char* dac_names[16] = {"SvP","Vtr","Vrf","Vrs","SvN","Vtgstv","Vcmp_ll","Vcmp_lr","cal","Vcmp_rl","rxb_rb","rxb_lb","Vcmp_rr","Vcp","Vcn","Vis"}; + +enum{E_PARALLEL, E_NON_PARALLEL, E_SAFE}; + +sls_detector_module *detectorModules=NULL; +int *detectorChips=NULL; +int *detectorChans=NULL; +dacs_t *detectorDacs=NULL; +dacs_t *detectorAdcs=NULL; + +int eiger_highvoltage = 0; +int eiger_theo_highvoltage = 0; +int eiger_iodelay = 0; +int eiger_photonenergy = 0; +int eiger_dynamicrange = 0; +int eiger_readoutmode = 0; +int eiger_storeinmem = 0; +int eiger_readoutspeed = 0; +int eiger_triggermode = 0; +int eiger_extgating = 0; +int eiger_extgatingpolarity = 0; + + +int eiger_nexposures = 1; +int eiger_ncycles = 1; + +//values for virtual server +double eiger_virtual_exptime = 0; +int64_t eiger_virtual_subexptime = 0; +double eiger_virtual_period = 0; +int eiger_virtual_counter_bit=1; +int eiger_virtual_ratecorrection_variable=0; +int64_t eiger_virtual_ratetable_tau_in_ns=-1; +int64_t eiger_virtual_ratetable_period_in_ns=-1; +int eiger_virtual_transmission_delay_left=0; +int eiger_virtual_transmission_delay_right=0; +int eiger_virtual_transmission_delay_frame=0; +int eiger_virtual_transmission_flowcontrol_10g=0; +int eiger_virtual_status=0; +pthread_t eiger_virtual_tid; + +int send_to_ten_gig = 0; +int ndsts_in_use=32; +unsigned int nimages_per_request=1; +int on_dst=0; +int dst_requested[32] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}; + + +int default_gain_values[3] = {517000,517000,517000}; +int default_offset_values[3] = {3851000,3851000,3851000}; + + +enum masterFlags masterMode=IS_SLAVE; +int top = 0; +int master = 0; +int normal = 0; + + + + + +/* basic tests */ + +void checkFirmwareCompatibility(){ + cprintf(BLUE,"\n\n" + "********************************************************\n" + "***************** EIGER Virtual Server *****************\n" + "********************************************************\n"); +} + + + + + +/* Ids */ + +int64_t getDetectorId(enum idMode arg){ + return 0; +} + +u_int64_t getFirmwareVersion() { + return 0; +} + + + +u_int32_t getDetectorNumber(){ + return 0; +} + + +u_int64_t getDetectorMAC() { + return 0; +} + + +u_int32_t getDetectorIP(){ + return 0; +} + + + + + +/* initialization */ + +void initControlServer(){ + getModuleConfiguration(); + setupDetector(); + printf("\n"); +} + +void initStopServer(){ + getModuleConfiguration(); + printf("\n"); +} + + +void getModuleConfiguration(){ +#ifdef VIRTUAL_MASTER + master = 1; + top = 1; +#else + master = 0; + top = 1; +#endif +#ifdef VIRTUAL_9M + normal = 0; +#else + normal = 1; +#endif + if(top) printf("*************** TOP ***************\n"); + else printf("*************** BOTTOM ***************\n"); + if(master) printf("*************** MASTER ***************\n"); + else printf("*************** SLAVE ***************\n"); + if(normal) printf("*************** NORMAL ***************\n"); + else printf("*************** SPECIAL ***************\n"); +} + + + +/* set up detector */ + +void allocateDetectorStructureMemory(){ + printf("This Server is for 1 Eiger half module (250k)\n"); + + //Allocation of memory + detectorModules=malloc(sizeof(sls_detector_module)); + detectorChips=malloc(NCHIP*sizeof(int)); + detectorChans=malloc(NCHIP*NCHAN*sizeof(int)); + detectorDacs=malloc(NDAC*sizeof(dacs_t)); + detectorAdcs=malloc(NADC*sizeof(dacs_t)); +#ifdef VERBOSE + printf("modules from 0x%x to 0x%x\n",detectorModules, detectorModules+n); + printf("chips from 0x%x to 0x%x\n",detectorChips, detectorChips+n*NCHIP); + printf("chans from 0x%x to 0x%x\n",detectorChans, detectorChans+n*NCHIP*NCHAN); + printf("dacs from 0x%x to 0x%x\n",detectorDacs, detectorDacs+n*NDAC); + printf("adcs from 0x%x to 0x%x\n",detectorAdcs, detectorAdcs+n*NADC); +#endif + (detectorModules)->dacs=detectorDacs; + (detectorModules)->adcs=detectorAdcs; + (detectorModules)->chipregs=detectorChips; + (detectorModules)->chanregs=detectorChans; + (detectorModules)->ndac=NDAC; + (detectorModules)->nadc=NADC; + (detectorModules)->nchip=NCHIP; + (detectorModules)->nchan=NCHIP*NCHAN; + (detectorModules)->module=0; + (detectorModules)->gain=0; + (detectorModules)->offset=0; + (detectorModules)->reg=0; + thisSettings = UNINITIALIZED; + + // if trimval requested, should return -1 to acknowledge unknown + int ichan=0; + for (ichan=0; ichan<(detectorModules->nchan); ichan++) { + *((detectorModules->chanregs)+ichan) = -1; + } +} + + + +void setupDetector() { + + allocateDetectorStructureMemory(); + //set dacs + printf("Setting Default Dac values\n"); + { + int i = 0; + int retval[2]={-1,-1}; + const int defaultvals[NDAC] = DEFAULT_DAC_VALS; + for(i = 0; i < NDAC; ++i) { + setDAC((enum DACINDEX)i,defaultvals[i],0,0,retval); + if (retval[0] != defaultvals[i]) + cprintf(RED, "Warning: Setting dac %d failed, wrote %d, read %d\n",i ,defaultvals[i], retval[0]); + } + } + + //setting default measurement parameters + setTimer(FRAME_NUMBER, DEFAULT_NUM_FRAMES); + setTimer(ACQUISITION_TIME, DEFAULT_EXPTIME); + setTimer(SUBFRAME_ACQUISITION_TIME, DEFAULT_SUBFRAME_EXPOSURE_VAL); + setTimer(FRAME_PERIOD, DEFAULT_PERIOD); + setDynamicRange(DEFAULT_DYNAMIC_RANGE); + eiger_photonenergy = DEFAULT_PHOTON_ENERGY; + setReadOutFlags(DEFAULT_READOUT_FLAG); + setSpeed(CLOCK_DIVIDER, DEFAULT_CLK_SPEED);//clk_devider,half speed + setIODelay(DEFAULT_IO_DELAY, DEFAULT_MOD_INDEX); + setTiming(DEFAULT_TIMING_MODE); + //SetPhotonEnergyCalibrationParameters(-5.8381e-5,1.838515,5.09948e-7,-4.32390e-11,1.32527e-15); + setRateCorrection(DEFAULT_RATE_CORRECTION); + int enable[2] = {DEFAULT_EXT_GATING_ENABLE, DEFAULT_EXT_GATING_POLARITY}; + setExternalGating(enable);//disable external gating + setHighVoltage(DEFAULT_HIGH_VOLTAGE); +} + + + + +/* advanced read/write reg */ +uint32_t writeRegister(uint32_t offset, uint32_t data) { + return 0; +} + +uint32_t readRegister(uint32_t offset) { + return 0; +} + + +/* set parameters - nmod, dr, roi */ + +int setNMod(int nm, enum dimension dim){ + return NMOD; +} + + +int getNModBoard(enum dimension arg){ + return NMAXMOD; +} + +int setDynamicRange(int dr){ + if(dr > 0){ + printf(" Setting dynamic range: %d\n",dr); + eiger_dynamicrange = dr; + } + return eiger_dynamicrange; +} + + + + +/* parameters - readout */ + +int setSpeed(enum speedVariable arg, int val){ + + if (arg != CLOCK_DIVIDER) + return -1; + + if(val != -1){ + printf(" Setting Read out Speed: %d\n",val); + eiger_readoutspeed = val; + } + return eiger_readoutspeed; +} + + +enum readOutFlags setReadOutFlags(enum readOutFlags val){ + + enum readOutFlags retval = GET_READOUT_FLAGS; + if(val!=GET_READOUT_FLAGS){ + + + if(val&0xF0000){ + switch(val){ + case PARALLEL: val=E_PARALLEL; printf(" Setting Read out Flag: Parallel\n"); break; + case NONPARALLEL: val=E_NON_PARALLEL; printf(" Setting Read out Flag: Non Parallel\n"); break; + case SAFE: val=E_SAFE; printf(" Setting Read out Flag: Safe\n"); break; + + default: + cprintf(RED,"Cannot set unknown readout flag. 0x%x\n", val); + return -1; + } + printf(" Setting Read out Flag: %d\n",val); + eiger_readoutmode = val; + }else{ + switch(val){ + case STORE_IN_RAM: val=1; printf(" Setting Read out Flag: Store in Ram\n"); break; + case CONTINOUS_RO: val=0; printf(" Setting Read out Flag: Continuous Readout\n"); break; + + default: + cprintf(RED,"Cannot set unknown readout flag. 0x%x\n", val); + return -1; + } + printf(" Setting store in ram variable: %d\n",val); + eiger_storeinmem = val; + + } + } + + switch(eiger_readoutmode){ + case E_PARALLEL: retval=PARALLEL; break; + case E_NON_PARALLEL: retval=NONPARALLEL; break; + case E_SAFE: retval=SAFE; break; + } + + switch(eiger_storeinmem){ + case 0: retval|=CONTINOUS_RO; break; + case 1: retval|=STORE_IN_RAM; break; + } + printf("Read out Flag: 0x%x\n",retval); + return retval; +} + + + + + + + + +/* parameters - timer */ + +int64_t setTimer(enum timerIndex ind, int64_t val){ + + switch(ind){ + case FRAME_NUMBER: + if(val >= 0){ + printf(" Setting number of frames: %d * %d\n",(unsigned int)val,eiger_ncycles); + eiger_nexposures = val; + nimages_per_request = eiger_nexposures * eiger_ncycles; + }return eiger_nexposures; + + case ACQUISITION_TIME: + if(val >= 0){ + printf(" Setting exp time: %fs\n",val/(1E9)); + eiger_virtual_exptime = (val/(1E9)); + } + return eiger_virtual_exptime*1e9; + + case SUBFRAME_ACQUISITION_TIME: + if(val >= 0){ + printf(" Setting sub exp time: %lldns\n",(long long int)val/10); + eiger_virtual_subexptime = (val/(10)); + } + return eiger_virtual_subexptime*10; + + case FRAME_PERIOD: + if(val >= 0){ + printf(" Setting acq period: %fs\n",val/(1E9)); + eiger_virtual_period = (val/(1E9)); + } + return eiger_virtual_period*1e9; + + case CYCLES_NUMBER: + if(val >= 0){ + printf(" Setting number of triggers: %d * %d\n",(unsigned int)val,eiger_nexposures); + eiger_ncycles = (val/(1E9)); + nimages_per_request = eiger_nexposures * eiger_ncycles; + } + return eiger_ncycles; + default: + cprintf(RED,"Warning: Timer Index not implemented for this detector: %d\n", ind); + break; + } + + return -1; +} + + + + + +/* parameters - channel, chip, module, settings */ + + +int setModule(sls_detector_module myMod, int delay){ + int retval[2]; + int i; + + //#ifdef VERBOSE + printf("Setting module with settings %d\n",myMod.reg); + //#endif + + setSettings( (enum detectorSettings)myMod.reg,-1); + + if(setIODelay(delay, -1)!= delay){ + cprintf(RED,"could not set iodelay %d\n",delay); + return FAIL; + } + + //copy module locally + if (detectorModules) + copyModule(detectorModules,&myMod); + + //set dac values + for(i=0;i= 0) + eiger_photonenergy = ev; + return getThresholdEnergy(imod); +} + + + + + +/* parameters - dac, adc, hv */ + +void setDAC(enum DACINDEX ind, int val, int imod, int mV, int retval[]){ + + if(ind == VTHRESHOLD){ + int ret[5]; + setDAC(VCMP_LL,val,imod,mV,retval); + ret[0] = retval[mV]; + setDAC(VCMP_LR,val,imod,mV,retval); + ret[1] = retval[mV]; + setDAC(VCMP_RL,val,imod,mV,retval); + ret[2] = retval[mV]; + setDAC(VCMP_RR,val,imod,mV,retval); + ret[3] = retval[mV]; + setDAC(VCP,val,imod,mV,retval); + ret[4] = retval[mV]; + + + if((ret[0]== ret[1])&& + (ret[1]==ret[2])&& + (ret[2]==ret[3]) && + (ret[3]==ret[4])) + cprintf(GREEN,"vthreshold match\n"); + else{ + retval[0] = -1;retval[1] = -1; + cprintf(RED,"vthreshold mismatch 0:%d 1:%d 2:%d 3:%d\n", + ret[0],ret[1],ret[2],ret[3]); + } + return; + } + char iname[10]; + + if(((int)ind>=0)&&((int)ind= 0) + printf("Setting dac %d: %s to %d ",ind, iname,val); + else + printf("Getting dac %d: %s ",ind, iname); + if(mV) + printf("in mV\n"); + else + printf("in dac units\n"); +#endif + + if (mV){ + retval[0] = (int)(((val-0)/(2048-0))*(4096-1) + 0.5); + retval[1] = val; + }else + retval[0] = val; + + (detectorModules)->dacs[ind] = retval[0]; +} + + + +int getADC(enum ADCINDEX ind, int imod){ + return 0; +} + + +int setHighVoltage(int val){ + if (master) { + // set + if(val!=-1){ + eiger_theo_highvoltage = val; + } + return eiger_theo_highvoltage; + } + + return SLAVE_HIGH_VOLTAGE_READ_VAL; +} + + + + + + + +/* parameters - timing, extsig */ + +enum externalCommunicationMode setTiming( enum externalCommunicationMode arg){ + enum externalCommunicationMode ret=GET_EXTERNAL_COMMUNICATION_MODE; + if(arg != GET_EXTERNAL_COMMUNICATION_MODE){ + switch((int)arg){ + case AUTO_TIMING: ret = 0; break; + case TRIGGER_EXPOSURE: ret = 2; break; + case BURST_TRIGGER: ret = 1; break; + case GATE_FIX_NUMBER: ret = 3; break; + } + printf(" Setting Triggering Mode: %d\n",(int)ret); + eiger_triggermode = ret; + } + + ret = eiger_triggermode; + switch((int)ret){ + case 0: ret = AUTO_TIMING; break; + case 2: ret = TRIGGER_EXPOSURE; break; + case 1: ret = BURST_TRIGGER; break; + case 3: ret = GATE_FIX_NUMBER; break; + default: + printf("Unknown trigger mode found %d\n",ret); + ret = 0; + } + return ret; +} + + + + + + +/* configure mac */ + +int configureMAC(uint32_t destip, uint64_t destmac, uint64_t sourcemac, uint32_t sourceip, uint32_t udpport, uint32_t udpport2, int ival) { + return 0; +} + + + + + + + +/* eiger specific - iodelay, 10g, pulse, rate, temp, activate, delay nw parameter */ + +int setIODelay(int val, int imod){ + if(val!=-1){ + printf(" Setting IO Delay: %d\n",val); + eiger_iodelay = val; + } + return eiger_iodelay; +} + + +int enableTenGigabitEthernet(int val){ + if(val!=-1){ + if(val>0) + send_to_ten_gig = 1; + else + send_to_ten_gig = 0; + //configuremac called from client + } +#ifdef VERBOSE + printf("10Gbe:%d\n",send_to_ten_gig); +#endif + return send_to_ten_gig; +} + + +int setCounterBit(int val){ + if(val!=-1){ + eiger_virtual_counter_bit = val; +#ifdef VERBOSE + printf("Counter Bit:%d\n",val); +#endif + } + return eiger_virtual_counter_bit; +} + + +int pulsePixel(int n, int x, int y){ + return OK; +} + +int pulsePixelNMove(int n, int x, int y){ + return OK; +} + +int pulseChip(int n){ + return OK; +} + +int64_t setRateCorrection(int64_t custom_tau_in_nsec){//in nanosec (will never be -1) + //deactivating rate correction + if(custom_tau_in_nsec==0){ + eiger_virtual_ratecorrection_variable = 0; + return 0; + } + + //when dynamic range changes, use old tau + else if(custom_tau_in_nsec == -1) + custom_tau_in_nsec = eiger_virtual_ratetable_tau_in_ns; + + //get period = subexptime if 32bit , else period = exptime if 16 bit + int64_t actual_period = eiger_virtual_subexptime*10; //already in nsec + if(eiger_dynamicrange == 16) + actual_period = eiger_virtual_exptime; + + int64_t ratetable_period_in_nsec = eiger_virtual_ratetable_period_in_ns; + int64_t tau_in_nsec = eiger_virtual_ratetable_tau_in_ns; + + + + //same setting + if((tau_in_nsec == custom_tau_in_nsec) && (ratetable_period_in_nsec == actual_period)){ + if(eiger_dynamicrange == 32) + printf("Rate Table already created before: Same Tau %lldns, Same subexptime %lldns\n", + (long long int)tau_in_nsec,(long long int)ratetable_period_in_nsec); + else + printf("Rate Table already created before: Same Tau %lldns, Same exptime %lldns\n", + (long long int)tau_in_nsec,(long long int)ratetable_period_in_nsec); + } + //different setting, calculate table + else{ + eiger_virtual_ratetable_tau_in_ns = custom_tau_in_nsec; + double period_in_sec = (double)(eiger_virtual_subexptime*10)/(double)1e9; + if(eiger_dynamicrange == 16) + period_in_sec = eiger_virtual_exptime; + eiger_virtual_ratetable_period_in_ns = period_in_sec*1e9; + } + //activating rate correction + eiger_virtual_ratecorrection_variable = 1; + printf("Rate Correction Value set to %lld ns\n",(long long int)eiger_virtual_ratetable_tau_in_ns); + + return eiger_virtual_ratetable_tau_in_ns; +} + +int getRateCorrectionEnable(){ + return eiger_virtual_ratecorrection_variable; +} + +int getDefaultSettingsTau_in_nsec(){ + return default_tau_from_file; +} + +void setDefaultSettingsTau_in_nsec(int t){ + default_tau_from_file = t; + printf("Default tau set to %d\n",default_tau_from_file); +} + +int64_t getCurrentTau(){ + if(!getRateCorrectionEnable()) + return 0; + else + return eiger_virtual_ratetable_tau_in_ns; +} + +void setExternalGating(int enable[]){ + if(enable>=0){ + eiger_extgating = enable[0]; + eiger_extgatingpolarity = enable[1]; + } + enable[0] = eiger_extgating; + enable[1] = eiger_extgatingpolarity; +} + +int setAllTrimbits(int val){ + int ichan; +#ifdef VERBOSE + printf("Copying register %x value %d\n",destMod->reg,val); +#endif + if (detectorModules){ + for (ichan=0; ichan<(detectorModules->nchan); ichan++) { + *((detectorModules->chanregs)+ichan)=val; + } + } + + cprintf(GREEN, "All trimbits have been set to %d\n", val); + return OK; +} + +int getAllTrimbits(){ + int ichan=0; + int value = *((detectorModules->chanregs)); + if (detectorModules){ + for (ichan=0; ichan<(detectorModules->nchan); ichan++) { + if(*((detectorModules->chanregs)+ichan) != value) { + value= -1; + break; + } + + } + } + printf("Value of all Trimbits: %d\n", value); + return value; +} + +int getBebFPGATemp(){ + return 0; +} + +int activate(int enable){ + return enable; +} + +int setNetworkParameter(enum NETWORKINDEX mode, int value){ + if (value>-1) { + switch(mode){ + case TXN_LEFT: + eiger_virtual_transmission_delay_left = value; + break; + case TXN_RIGHT: + eiger_virtual_transmission_delay_right = value; + break; + case TXN_FRAME: + eiger_virtual_transmission_delay_frame = value; + break; + case FLOWCTRL_10G: + eiger_virtual_transmission_flowcontrol_10g = value; + if(value>0) value = 1; + break; + default: cprintf(BG_RED,"Unrecognized mode in network parameter: %d\n",mode); + return -1; + } + } + switch(mode){ + case TXN_LEFT: + return eiger_virtual_transmission_delay_left; + case TXN_RIGHT: + return eiger_virtual_transmission_delay_right; + case TXN_FRAME: + return eiger_virtual_transmission_delay_frame; + case FLOWCTRL_10G: + return eiger_virtual_transmission_flowcontrol_10g; + default: cprintf(BG_RED,"Unrecognized mode in network parameter: %d\n",mode); + return -1; + } +} + + + + + + + +/* aquisition */ + + +int prepareAcquisition(){ + return OK; +} + + +int startStateMachine(){ + + if(pthread_create(&eiger_virtual_tid, NULL, &start_timer, NULL)) { + cprintf(RED,"Could not start Virtual acquisition thread\n"); + return FAIL; + } + eiger_virtual_status = 1; + cprintf(GREEN,"***Virtual Acquisition started\n"); + return OK; +} + +void* start_timer(void* arg) { + double wait_in_s = nimages_per_request * eiger_virtual_period; + cprintf(GREEN,"going to wait for %f s\n", wait_in_s); + usleep(wait_in_s * 1000 * 1000); + cprintf(GREEN,"Virtual Timer Done***\n"); + + eiger_virtual_status = 0; + return NULL; +} + +int stopStateMachine(){ + cprintf(BG_RED,"Going to stop acquisition\n"); + return OK; +} + + +int startReadOut(){ + printf("Requesting images...\n"); + return OK; +} + + +enum runStatus getRunStatus(){ + if(eiger_virtual_status== 0){ + printf("Status: IDLE\n"); + return IDLE; + }else{ + printf("Status: RUNNING...\n"); + return RUNNING; + } + //}else printf("***** not master*** \n"); + + return IDLE; +} + + + +void readFrame(int *ret, char *mess){ + while(eiger_virtual_status) { + //cprintf(RED,"Waiting for finished flag\n"); + usleep(5000); + } + *ret = (int)FINISHED; + strcpy(mess,"acquisition successfully finished\n"); +} + + + + + + + + +/* common */ + + +int copyModule(sls_detector_module *destMod, sls_detector_module *srcMod){ + + int ichip, idac, ichan, iadc; + int ret=OK; + +#ifdef VERBOSE + printf("Copying module %x to module %x\n",srcMod,destMod); +#endif + + if (srcMod->module>=0) { +#ifdef VERBOSE + printf("Copying module number %d to module number %d\n",srcMod->module,destMod->module); +#endif + destMod->module=srcMod->module; + } + if (srcMod->serialnumber>=0){ + + destMod->serialnumber=srcMod->serialnumber; + } + //no trimbit feature + if (destMod->nchip && ((srcMod->nchip)>(destMod->nchip))) { + printf("Number of chip of source is larger than number of chips of destination\n"); + return FAIL; + } + //no trimbit feature + if (destMod->nchan && ((srcMod->nchan)>(destMod->nchan))) { + printf("Number of channels of source is larger than number of channels of destination\n"); + return FAIL; + } + if ((srcMod->ndac)>(destMod->ndac)) { + printf("Number of dacs of source is larger than number of dacs of destination\n"); + return FAIL; + } + if ((srcMod->nadc)>(destMod->nadc)) { + printf("Number of dacs of source is larger than number of dacs of destination\n"); + return FAIL; + } + +#ifdef VERBOSE + printf("DACs: src %d, dest %d\n",srcMod->ndac,destMod->ndac); + printf("ADCs: src %d, dest %d\n",srcMod->nadc,destMod->nadc); + printf("Chips: src %d, dest %d\n",srcMod->nchip,destMod->nchip); + printf("Chans: src %d, dest %d\n",srcMod->nchan,destMod->nchan); + +#endif + destMod->ndac=srcMod->ndac; + destMod->nadc=srcMod->nadc; + destMod->nchip=srcMod->nchip; + destMod->nchan=srcMod->nchan; + if (srcMod->reg>=0) + destMod->reg=srcMod->reg; +#ifdef VERBOSE + printf("Copying register %x (%x)\n",destMod->reg,srcMod->reg ); +#endif + if (srcMod->gain>=0) + destMod->gain=srcMod->gain; + if (srcMod->offset>=0) + destMod->offset=srcMod->offset; + + if((destMod->nchip!=0) || (destMod->nchan!=0)) { + for (ichip=0; ichip<(srcMod->nchip); ichip++) { + if (*((srcMod->chipregs)+ichip)>=0) + *((destMod->chipregs)+ichip)=*((srcMod->chipregs)+ichip); + } + for (ichan=0; ichan<(srcMod->nchan); ichan++) { + if (*((srcMod->chanregs)+ichan)>=0) + *((destMod->chanregs)+ichan)=*((srcMod->chanregs)+ichan); + } + } +#ifdef VERBOSE + else printf("Not Copying trimbits\n"); +#endif + for (idac=0; idac<(srcMod->ndac); idac++) { + if (*((srcMod->dacs)+idac)>=0) + *((destMod->dacs)+idac)=*((srcMod->dacs)+idac); + } + for (iadc=0; iadc<(srcMod->nadc); iadc++) { + if (*((srcMod->adcs)+iadc)>=0) + *((destMod->adcs)+iadc)=*((srcMod->adcs)+iadc); + } + return ret; +} + + +int calculateDataBytes(){ + if(send_to_ten_gig) + return setDynamicRange(-1) * ONE_GIGA_CONSTANT * TEN_GIGA_BUFFER_SIZE; + else + return setDynamicRange(-1) * TEN_GIGA_CONSTANT * ONE_GIGA_BUFFER_SIZE; +} + + +int getTotalNumberOfChannels(){return ((int)getNumberOfChannelsPerModule() * (int)getTotalNumberOfModules());} +int getTotalNumberOfChips(){return ((int)getNumberOfChipsPerModule() * (int)getTotalNumberOfModules());} +int getTotalNumberOfModules(){return NMOD;} +int getNumberOfChannelsPerModule(){return ((int)getNumberOfChannelsPerChip() * (int)getTotalNumberOfChips());} +int getNumberOfChipsPerModule(){return NCHIP;} +int getNumberOfDACsPerModule(){return NDAC;} +int getNumberOfADCsPerModule(){return NADC;} +int getNumberOfChannelsPerChip(){return NCHAN;} +int getNumberOfGainsPerModule(){return NGAIN;} +int getNumberOfOffsetsPerModule(){return NOFFSET;} + + + + + + +/* sync */ + +enum masterFlags setMaster(enum masterFlags arg){ + return NO_MASTER; +} + + + +enum synchronizationMode setSynchronization(enum synchronizationMode arg){ + return NO_SYNCHRONIZATION; +} + + + + + + + +#endif diff --git a/slsDetectorSoftware/gitInfo.txt b/slsDetectorSoftware/gitInfo.txt index f80b69fa5..f3623cd3d 100644 --- a/slsDetectorSoftware/gitInfo.txt +++ b/slsDetectorSoftware/gitInfo.txt @@ -1,9 +1,9 @@ Path: slsDetectorsPackage/slsDetectorSoftware 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: 2dfbd9016b501eca6ee2c00a08e49a3f7e7990d8 -Revision: 1452 -Branch: 3.0-rc +Repsitory UUID: 5d45181f177b552819bd60947c6cf4f0abae7681 +Revision: 1543 +Branch: 3.0 Last Changed Author: Dhanya_Maliakal -Last Changed Rev: 1457 -Last Changed Date: 2017-08-09 11:36:51.000000002 +0200 ./multiSlsDetector/multiSlsDetector.cpp +Last Changed Rev: 1548 +Last Changed Date: 2017-08-28 12:02:38.000000002 +0200 ./multiSlsDetector/multiSlsDetector.cpp diff --git a/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c b/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c index 08ba5e901..ee2771699 100755 --- a/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c +++ b/slsDetectorSoftware/gotthardDetectorServer/firmware_funcs.c @@ -244,15 +244,6 @@ u_int32_t bus_r(u_int32_t offset) { void setMasterSlaveConfiguration(){ -/* - int masterflags = NO_MASTER; - int masterdefaultdelay = 62; - int patternphase = 0; - int adcphase = 0; - int slavepatternphase = 0; - int slaveadcphase = 0; - int sw1torstdelay = 2; -*/ // global master default delay picked from config file FILE* fd=fopen(CONFIG_FILE,"r"); if(fd==NULL){ @@ -354,17 +345,15 @@ void setMasterSlaveConfiguration(){ setPhaseShift(slaveadcphase); } + /* Set RST to SW1 delay */ + val=bus_r(MULTI_PURPOSE_REG); + //#ifdef VERBOSE + printf("Value of multipurpose reg:%d\n",bus_r(MULTI_PURPOSE_REG)); + //#endif + val = (val & (~(RST_TO_SW1_DELAY_MSK))) | ((rsttosw1delay << RST_TO_SW1_DELAY_OFFSET) & (RST_TO_SW1_DELAY_MSK)); + bus_w(MULTI_PURPOSE_REG,val); - if (masterflags == IS_MASTER || masterflags == IS_SLAVE) { - val=bus_r(MULTI_PURPOSE_REG); -//#ifdef VERBOSE - printf("Value of multipurpose reg:%d\n",bus_r(MULTI_PURPOSE_REG)); -//#endif - val = (val & (~(RST_TO_SW1_DELAY_MSK))) | ((rsttosw1delay << RST_TO_SW1_DELAY_OFFSET) & (RST_TO_SW1_DELAY_MSK)); - bus_w(MULTI_PURPOSE_REG,val); - } - fclose(fd); } diff --git a/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt b/slsDetectorSoftware/gotthardDetectorServer/gitInfo.txt index 0b0fd3c25..331da9c31 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: a0ae3985068425e7142df8271eac6ce09a238dc9 -Revision: 206 +Repsitory UUID: e4fa807b5d987714a047b9d2cac271c89f6c2fef +Revision: 208 Branch: developer Last Changed Author: Dhanya_Maliakal -Last Changed Rev: 1454 -Last Changed Date: 2017-08-04 09:28:44.000000002 +0200 ./firmware_funcs.c +Last Changed Rev: 1487 +Last Changed Date: 2017-08-16 16:01:46.000000002 +0200 ./firmware_funcs.c diff --git a/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h b/slsDetectorSoftware/gotthardDetectorServer/gitInfoGotthard.h index b1430c924..f5a2ab5e4 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 "a0ae3985068425e7142df8271eac6ce09a238dc9" -//#define SVNREV 0x1454 +#define SVNREPUUID "e4fa807b5d987714a047b9d2cac271c89f6c2fef" +//#define SVNREV 0x1487 //#define SVNKIND "" //#define SVNSCHED "" #define SVNAUTH "Dhanya_Maliakal" -#define SVNREV 0x1454 -#define SVNDATE 0x20170804 +#define SVNREV 0x1487 +#define SVNDATE 0x20170816 // diff --git a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.4 b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.4 deleted file mode 100755 index 4d2a29ceb..000000000 Binary files a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.4 and /dev/null differ diff --git a/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 new file mode 100755 index 000000000..e802907cb Binary files /dev/null and b/slsDetectorSoftware/gotthardDetectorServer/gotthardDetectorServerv3.0.0.5 differ diff --git a/slsDetectorSoftware/include/slsReceiverUsers.h b/slsDetectorSoftware/include/slsReceiverUsers.h index d73c332c0..c8727f200 120000 --- a/slsDetectorSoftware/include/slsReceiverUsers.h +++ b/slsDetectorSoftware/include/slsReceiverUsers.h @@ -1 +1 @@ -../slsReceiver/slsReceiverUsers.h \ No newline at end of file +../../slsReceiverSoftware/include/slsReceiverUsers.h \ No newline at end of file diff --git a/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.5 b/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.6 similarity index 78% rename from slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.5 rename to slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.6 index 0e633eb8f..34021f5b7 100755 Binary files a/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.5 and b/slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.6 differ diff --git a/slsDetectorSoftware/jungfrauDetectorServer/gitInfo.txt b/slsDetectorSoftware/jungfrauDetectorServer/gitInfo.txt index 24e407864..ad8848f56 100644 --- a/slsDetectorSoftware/jungfrauDetectorServer/gitInfo.txt +++ b/slsDetectorSoftware/jungfrauDetectorServer/gitInfo.txt @@ -1,9 +1,9 @@ Path: slsDetectorsPackage/slsDetectorSoftware/jungfrauDetectorServer 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: 9f1b82c18ab0893d65bfadeb646b8ea244614632 -Revision: 88 -Branch: developer +Repsitory UUID: c58dfe801770ceb63a9baab0be5b4cd16794b57e +Revision: 89 +Branch: 3.0-rc Last Changed Author: Dhanya_Maliakal -Last Changed Rev: 1443 -Last Changed Date: 2017-07-10 10:40:23.000000002 +0200 ./Makefile +Last Changed Rev: 1495 +Last Changed Date: 2017-08-15 14:14:32.000000002 +0200 ./RegisterDefs.h diff --git a/slsDetectorSoftware/jungfrauDetectorServer/gitInfoJungfrau.h b/slsDetectorSoftware/jungfrauDetectorServer/gitInfoJungfrau.h index 3f01d08bf..f3a3310d0 100644 --- a/slsDetectorSoftware/jungfrauDetectorServer/gitInfoJungfrau.h +++ b/slsDetectorSoftware/jungfrauDetectorServer/gitInfoJungfrau.h @@ -1,11 +1,11 @@ //#define SVNPATH "" #define SVNURL "git@git.psi.ch:sls_detectors_software/sls_detector_software.git" //#define SVNREPPATH "" -#define SVNREPUUID "9f1b82c18ab0893d65bfadeb646b8ea244614632" -//#define SVNREV 0x1443 +#define SVNREPUUID "c58dfe801770ceb63a9baab0be5b4cd16794b57e" +//#define SVNREV 0x1495 //#define SVNKIND "" //#define SVNSCHED "" #define SVNAUTH "Dhanya_Maliakal" -#define SVNREV 0x1443 -#define SVNDATE 0x20170710 +#define SVNREV 0x1495 +#define SVNDATE 0x20170815 // diff --git a/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c b/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c index 839a86e63..872b2e823 100644 --- a/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorSoftware/jungfrauDetectorServer/slsDetectorFunctionList.c @@ -347,7 +347,7 @@ void setupDetector() { setTimer(FRAME_NUMBER, DEFAULT_NUM_FRAMES); setTimer(CYCLES_NUMBER, DEFAULT_NUM_CYCLES); - setTimer(ACQUISITION_TIME, DEFAULT_PERIOD); + setTimer(ACQUISITION_TIME, DEFAULT_EXPTIME); setTimer(FRAME_PERIOD, DEFAULT_PERIOD); setTimer(DELAY_AFTER_TRIGGER, DEFAULT_DELAY); /*setSpeed(CLOCK_DIVIDER, HALF_SPEED); depends if all the previous stuff works*/ diff --git a/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.cpp b/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.cpp index 000b7c82d..546065db0 100644 --- a/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.cpp +++ b/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.cpp @@ -207,6 +207,7 @@ multiSlsDetector::multiSlsDetector(int id) : slsDetectorUtils(), shmId(-1) thisMultiDetector->receiver_read_freq = 0; thisMultiDetector->acquiringFlag = false; + thisMultiDetector->externalgui = false; thisMultiDetector->alreadyExisting=1; } @@ -278,6 +279,7 @@ multiSlsDetector::multiSlsDetector(int id) : slsDetectorUtils(), shmId(-1) threadpool = 0; if(createThreadPool() == FAIL) exit(-1); + gainDataEnable = false; } @@ -3615,11 +3617,11 @@ string multiSlsDetector::getNetworkParameter(networkParameter p) { string multiSlsDetector::setNetworkParameter(networkParameter p, string s){ // disable data streaming before changing zmq port (but only if they were on) - /*int prev_streaming = 0;*/ - if (p == RECEIVER_STREAMING_PORT) { - /*prev_streaming = getStreamingSocketsCreatedInClient();*/ - enableDataStreamingFromReceiver(0); - } + int prev_streaming = 0; + if (p == RECEIVER_STREAMING_PORT) { + prev_streaming = getStreamingSocketsCreatedInClient(); + enableDataStreamingFromReceiver(0); + } if (s.find('+')==string::npos) { @@ -3672,11 +3674,11 @@ string multiSlsDetector::setNetworkParameter(networkParameter p, string s){ } } -/* + //enable data streaming if it was on if (p == RECEIVER_STREAMING_PORT && prev_streaming) enableDataStreamingFromReceiver(1); -*/ + return getNetworkParameter(p); } @@ -5350,16 +5352,6 @@ slsDetectorDefs::runStatus multiSlsDetector::getReceiverStatus(){ int multiSlsDetector::getFramesCaughtByReceiver() { int ret=0,ret1=0; - if(thisMultiDetector->numberOfDetectors>10) { - if (detectors[0]){ - ret =detectors[0]->getFramesCaughtByReceiver(); - if(detectors[0]->getErrorMask()) - setErrorMask(getErrorMask()|(1<<0)); - } - return ret; - } - - for (int i=0; inumberOfDetectors; i++) if (detectors[i]){ ret1+=detectors[i]->getFramesCaughtByReceiver(); @@ -5471,7 +5463,7 @@ int multiSlsDetector::createReceivingDataSockets(const bool destroy){ -int multiSlsDetector::getData(const int isocket, const bool masking, int* image, const int size, +int multiSlsDetector::getData(const int isocket, int* image, const int size, uint64_t &acqIndex, uint64_t &frameIndex, uint32_t &subframeIndex, string &filename) { //fail is on parse error or end of acquisition @@ -5481,14 +5473,6 @@ int multiSlsDetector::getData(const int isocket, const bool masking, int* image, //receiving incorrect size is replaced by 0xFF zmqSocket[isocket]->ReceiveData(isocket, image, size); - //jungfrau masking adcval - if(masking){ - unsigned int snel = size/sizeof(int); - for(unsigned int i=0;inumberOfDetectors; int numSocketsPerSLSDetector = 1; bool jungfrau = false; + double* gdata = NULL; switch(getDetectorsType()){ case EIGER: numSocketsPerSLSDetector = 2; @@ -5561,6 +5546,9 @@ void multiSlsDetector::readFrameFromReceiver(){ return; } int* multiframe=new int[nel](); + int* multiframegain=NULL; + if (jungfrau) + multiframegain = new int[nel](); int nch; bool runningList[numSockets]; @@ -5587,7 +5575,7 @@ void multiSlsDetector::readFrameFromReceiver(){ //if running if (runningList[isocket]) { //get individual images - if(FAIL == getData(isocket, jungfrau, image, expectedslssize, currentAcquisitionIndex,currentFrameIndex,currentSubFrameIndex,currentFileName)){ + if(FAIL == getData(isocket, image, expectedslssize, currentAcquisitionIndex,currentFrameIndex,currentSubFrameIndex,currentFileName)){ runningList[isocket] = false; numRunning--; continue; @@ -5641,12 +5629,29 @@ void multiSlsDetector::readFrameFromReceiver(){ //send data to callback if(running){ + if (jungfrau) { + // with gain data + if (gainDataEnable) { + memcpy(multiframegain, multiframe, nel * sizeof(int)); + for(unsigned int i=0;i> 14) | ((multiframe[i] & 0x0000C000) >> 14) ; + multiframe[i] = (multiframe[i] & 0x3FFF3FFF); + } + gdata = decodeData(multiframegain,nch); + } + // without gain data + else { + for(unsigned int i=0;i= 0){ - /*if(dataSocketsStarted != enable){*/ + //create client sockets only if no external gui + if (!thisMultiDetector->externalgui) { + if(enable >= 0){ + //destroy data threads if(dataSocketsStarted) createReceivingDataSockets(true); @@ -5925,12 +5934,10 @@ int multiSlsDetector::enableDataStreamingFromReceiver(int enable){ return -1; } } - /*}*/ - + } } - int ret=-100; if(!threadpool){ cout << "Error in creating threadpool. Exiting" << endl; @@ -5963,9 +5970,10 @@ int multiSlsDetector::enableDataStreamingFromReceiver(int enable){ } } - if(ret != dataSocketsStarted) - ret = -1; - + if (!thisMultiDetector->externalgui) { + if (ret != dataSocketsStarted) + ret = -1; + } return ret; } @@ -6281,3 +6289,17 @@ void multiSlsDetector::setAcquiringFlag(bool b){ bool multiSlsDetector::getAcquiringFlag(){ return thisMultiDetector->acquiringFlag; } + + +void multiSlsDetector::setExternalGuiFlag(bool b){ + thisMultiDetector->externalgui = b; +} + +bool multiSlsDetector::getExternalGuiFlag(){ + return thisMultiDetector->externalgui; +} + + +void multiSlsDetector::setGainDataEnableinDataCallback(bool e) { + gainDataEnable = e; +} diff --git a/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.h b/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.h index 3a095a20d..5a1fc4139 100644 --- a/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.h +++ b/slsDetectorSoftware/multiSlsDetector/multiSlsDetector.h @@ -201,6 +201,9 @@ class multiSlsDetector : public slsDetectorUtils { /** flag for acquiring */ bool acquiringFlag; + /** external gui */ + bool externalgui; + } sharedMultiSlsDetector; @@ -1442,13 +1445,32 @@ class multiSlsDetector : public slsDetectorUtils { */ bool getAcquiringFlag(); + /** + Set external gui flag in shared memory + \param b set external gui flag + */ + void setExternalGuiFlag(bool b=false); + + /** + Get external gui flag from shared memory + \returns external gui flag + */ + bool getExternalGuiFlag(); + + /** + * Set Gain Data enable for gain plot + * in data call back + * @param e enable + */ + void setGainDataEnableinDataCallback(bool e); + + private: /** * Gets data from socket * @param isocket socket index - * @param masking if masking required (jungfrau) * @param image image buffer * @param size size of image * @param acqIndex address of acquisition index @@ -1456,7 +1478,7 @@ private: * @param subframeIndex address of subframe index * @param filename address of file name */ - int getData(const int isocket, const bool masking, int* image, const int size, uint64_t &acqIndex, uint64_t &frameIndex, uint32_t &subframeIndex, string &filename); + int getData(const int isocket, int* image, const int size, uint64_t &acqIndex, uint64_t &frameIndex, uint32_t &subframeIndex, string &filename); /** Ensures if sockets created successfully */ @@ -1480,6 +1502,9 @@ private: private: ThreadPool* threadpool; + /** Gain Data enabled in data call back */ + bool gainDataEnable; + }; diff --git a/slsDetectorSoftware/slsADCReader/Makefile b/slsDetectorSoftware/slsADCReader/Makefile new file mode 100644 index 000000000..ce48d2874 --- /dev/null +++ b/slsDetectorSoftware/slsADCReader/Makefile @@ -0,0 +1,21 @@ +CC = g++ +#CC = bfin-uclinux- +SRC = slsADCReader.cpp +INCLUDES = -I ../../slsReceiverSoftware/include -I ../commonFiles +CFLAGS = -Wall -lm -lstdc++ + + +all: clean slsADCReader + + +slsADCReader: $(SRC) + echo "creating adc reader" + $(CC) -o $@ $^ $(CFLAGS) $(INCLUDES) + + +clean: + echo "cleaning" + rm -rf *.o + + + diff --git a/slsDetectorSoftware/slsADCReader/slsADCReader b/slsDetectorSoftware/slsADCReader/slsADCReader new file mode 100755 index 000000000..3117fc8bf Binary files /dev/null and b/slsDetectorSoftware/slsADCReader/slsADCReader differ diff --git a/slsDetectorSoftware/slsADCReader/slsADCReader.cpp b/slsDetectorSoftware/slsADCReader/slsADCReader.cpp new file mode 100644 index 000000000..f27eb3a86 --- /dev/null +++ b/slsDetectorSoftware/slsADCReader/slsADCReader.cpp @@ -0,0 +1,118 @@ +#include "MySocketTCP.h" + +#include "sls_detector_defs.h" +#include "sls_receiver_defs.h" + +#include "sls_detector_funcs.h" + +#include +#include + +#define INVALID -999 + +enum detectorFunctions{ + F_GET_ADC=13 +}; + +void help() { + cerr << "Usage:\n" + "slsAdcReader [hostname] [adcval]" << endl; + exit(EXIT_FAILURE); +} + + +slsDetectorDefs::dacIndex getADCEnum(char* cval){ + int idac; + string cmd; + cmd.assign(cval); + + if (sscanf(cval,"adc:%d",&idac)==1) { + return (slsDetectorDefs::dacIndex)(idac+1000); + } else if (cmd=="temp_adc") + return slsDetectorDefs::TEMPERATURE_ADC; + else if (cmd=="temp_fpga") + return slsDetectorDefs::TEMPERATURE_FPGA; + else if (cmd=="temp_fpgaext") + return slsDetectorDefs::TEMPERATURE_FPGAEXT; + else if (cmd=="temp_10ge") + return slsDetectorDefs::TEMPERATURE_10GE; + else if (cmd=="temp_dcdc") + return slsDetectorDefs::TEMPERATURE_DCDC; + else if (cmd=="temp_sodl") + return slsDetectorDefs::TEMPERATURE_SODL; + else if (cmd=="temp_sodr") + return slsDetectorDefs::TEMPERATURE_SODR; + else if (cmd=="temp_fpgafl") + return slsDetectorDefs::TEMPERATURE_FPGA2; + else if (cmd=="temp_fpgafr") + return slsDetectorDefs::TEMPERATURE_FPGA3; + else if (cmd=="i_a") + return slsDetectorDefs::I_POWER_A; + else if (cmd=="i_b") + return slsDetectorDefs::I_POWER_B; + else if (cmd=="i_c") + return slsDetectorDefs::I_POWER_C; + else if (cmd=="i_d") + return slsDetectorDefs::I_POWER_D; + else if (cmd=="vm_a") + return slsDetectorDefs::V_POWER_A; + else if (cmd=="vm_b") + return slsDetectorDefs::V_POWER_B; + else if (cmd=="vm_c") + return slsDetectorDefs::V_POWER_C; + else if (cmd=="vm_d") + return slsDetectorDefs::V_POWER_D; + else if (cmd=="vm_io") + return slsDetectorDefs::V_POWER_IO; + else if (cmd=="i_io") + return slsDetectorDefs::I_POWER_IO; + else { + cerr << "cannot decode dac " << cmd << endl; + help(); + return slsDetectorDefs::I_POWER_IO; + } +}; + + + +int main(int argc, char* argv[]) +{ + if (argc < 3) + help(); + slsDetectorDefs::dacIndex idx=getADCEnum(argv[2]); + + + char mess[MAX_STR_LENGTH]=""; + detectorFunctions fnum=F_GET_ADC; + int retval=-1; + int ret=slsReceiverDefs::FAIL; + int arg[2]={idx,0}; + + + MySocketTCP* tempSocket=new MySocketTCP(argv[1],1952); + if (tempSocket->getErrorStatus()){ + cerr << "could not create socket with " << argv[1] << endl; + help(); + } + + if (tempSocket->Connect()) { + tempSocket->SendDataOnly(&fnum, sizeof(fnum)); + tempSocket->SendDataOnly(arg,sizeof(arg)); + tempSocket->ReceiveDataOnly(&ret, sizeof(ret)); + if (ret != slsReceiverDefs::FAIL) { + tempSocket->ReceiveDataOnly(&retval, sizeof(retval)); + } else { + tempSocket->ReceiveDataOnly(mess,sizeof(mess)); + printf("Detector returned Error: %s",mess); + } + tempSocket->Disconnect(); + } else + cerr << "could not connect to " << argv[1] << endl; + + if (idx <= 100) { + printf("%.2f°C\n",(double)retval/1000.00); + }else + printf("%dmV\n",retval); + + return EXIT_SUCCESS; +} diff --git a/slsDetectorSoftware/slsDetector/gitInfoLib.h b/slsDetectorSoftware/slsDetector/gitInfoLib.h index 1b50b021d..132820c0f 100644 --- a/slsDetectorSoftware/slsDetector/gitInfoLib.h +++ b/slsDetectorSoftware/slsDetector/gitInfoLib.h @@ -1,11 +1,11 @@ //#define SVNPATH "" #define SVNURLLIB "git@git.psi.ch:sls_detectors_software/sls_detector_software.git" //#define SVNREPPATH "" -#define SVNREPUUIDLIB "2dfbd9016b501eca6ee2c00a08e49a3f7e7990d8" -//#define SVNREV 0x1457 +#define SVNREPUUIDLIB "5d45181f177b552819bd60947c6cf4f0abae7681" +//#define SVNREV 0x1548 //#define SVNKIND "" //#define SVNSCHED "" #define SVNAUTHLIB "Dhanya_Maliakal" -#define SVNREVLIB 0x1457 -#define SVNDATELIB 0x20170809 +#define SVNREVLIB 0x1548 +#define SVNDATELIB 0x20170828 // diff --git a/slsDetectorSoftware/slsDetector/slsDetector.cpp b/slsDetectorSoftware/slsDetector/slsDetector.cpp index 38ab1e404..c4d2150f1 100644 --- a/slsDetectorSoftware/slsDetector/slsDetector.cpp +++ b/slsDetectorSoftware/slsDetector/slsDetector.cpp @@ -6090,7 +6090,8 @@ string slsDetector::setReceiver(string receiverIP){ setTimer(FRAME_PERIOD,thisDetector->timerValue[FRAME_PERIOD]); setTimer(FRAME_NUMBER,thisDetector->timerValue[FRAME_NUMBER]); setTimer(ACQUISITION_TIME,thisDetector->timerValue[ACQUISITION_TIME]); - setTimer(SUBFRAME_ACQUISITION_TIME,thisDetector->timerValue[SUBFRAME_ACQUISITION_TIME]); + if(thisDetector->myDetectorType == EIGER) + setTimer(SUBFRAME_ACQUISITION_TIME,thisDetector->timerValue[SUBFRAME_ACQUISITION_TIME]); setDynamicRange(thisDetector->dynamicRange); if(thisDetector->myDetectorType == EIGER){ setFlippedData(X,-1); @@ -9078,3 +9079,15 @@ void slsDetector::setAcquiringFlag(bool b){ bool slsDetector::getAcquiringFlag(){ return thisDetector->acquiringFlag; } + + +void slsDetector::setExternalGuiFlag(bool b){ + pthread_mutex_lock(&ms); + parentDet->setExternalGuiFlag(b); + pthread_mutex_unlock(&ms); +} + +bool slsDetector::getExternalGuiFlag(){ + return parentDet->getExternalGuiFlag(); +} + diff --git a/slsDetectorSoftware/slsDetector/slsDetector.h b/slsDetectorSoftware/slsDetector/slsDetector.h index d6005448b..07a92ab14 100644 --- a/slsDetectorSoftware/slsDetector/slsDetector.h +++ b/slsDetectorSoftware/slsDetector/slsDetector.h @@ -1884,6 +1884,18 @@ class slsDetector : public slsDetectorUtils, public energyConversion { */ bool getAcquiringFlag(); + /** + Set external gui flag in shared memory + \param b set external gui flag + */ + void setExternalGuiFlag(bool b=false); + + /** + Get external gui flag from shared memory + \returns external gui flag + */ + bool getExternalGuiFlag(); + protected: diff --git a/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp b/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp index 9d4e1820c..5a16bef22 100644 --- a/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp +++ b/slsDetectorSoftware/slsDetector/slsDetectorCommand.cpp @@ -45,15 +45,18 @@ To address a specific controller i of detector j use: For additional questions concerning the indexing of the detector, please refer to the SLS Detectors FAQ documentation. The commands are sudivided into different pages depending on their functionalities: - - \ref acquisition Acquisition: commands to start/stop the acquisition and retrieve data - - \ref config Configuration: commands to configure the detector + - \ref acquisition "Acquisition": commands to start/stop the acquisition and retrieve data + - \ref config "Configuration": commands to configure the detector + - \ref timing "Timing": commands to configure the detector timing - \ref data "Data postprocessing": commands to process the data - mainly for MYTHEN except for rate corrections. - \ref settings "Settings": commands to define detector settings/threshold. - \ref output "Output": commands to define output file destination and format - \ref actions "Actions": commands to define scripts to be executed during the acquisition flow - \ref network "Network": commands to setup the network between client, detector and receiver - \ref receiver "Receiver": commands to configure the receiver - - \ref test Developer: commands to be used only for software debugging. Avoid using them! + - \ref ctb "Chiptest board": commands specific for the new chiptest board as pattern generator + - \ref test "Developer": commands to be used only for software debugging. Avoid using them! + */ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { @@ -72,122 +75,6 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { descrToFuncMap[i].m_pFuncName="test"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdUnderDevelopment; i++; - /* Acquisition and status commands */ - /*! \page acquisition Acquition commands - Commands to control the acquisition - */ - /*! \page acquisition - - \b acquire blocking acquisition (like calling sls_detector_acquire). Starts receiver and detector, writes and processes the data, stops detector. Only get! - */ - descrToFuncMap[i].m_pFuncName="acquire"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAcquire; - i++; - - /*! \page acquisition - - \b data gets all data from the detector (if any) processes them and writes them to file according to the preferences already setup (MYTHEN only). Only get! - */ - descrToFuncMap[i].m_pFuncName="data"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdData; - i++; - - /*! \page acquisition - - \b frame gets a single frame from the detector (if any) processes it and writes it to file according to the preferences already setup (MYTHEN only). Only get! - */ - descrToFuncMap[i].m_pFuncName="frame"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFrame; - i++; - - /*! \page acquisition - - \b status \c returns the detector status (string)- can be: \c running, \c error, \c transmitting, \c finished, \c waiting or \c idle; \c put can be \c start or \c stop - */ - descrToFuncMap[i].m_pFuncName="status"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdStatus; - i++; - - /*! \page acquisition - - \b busy returns \c 1 if the acquisition is active, \c 0 otherwise. Works when the acquisition is started in non-blocking mode. Only get! - */ - descrToFuncMap[i].m_pFuncName="busy"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdStatus; - i++; - - - /* Detector structure configuration and debugging commands */ - - /*! \page config Configuration commands - Commands to configure the detector. these commands are often left to the configuration file. - */ - - /*! \page config - - \b datastream enables/disables the 0MQ data stream (0MQ threads created) from receiver to client. - */ - descrToFuncMap[i].m_pFuncName="datastream"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDataStream; - i++; - - /*! \page config - - \b free Free shared memory on the control PC - */ - - descrToFuncMap[i].m_pFuncName="free";//OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFree; - i++; - - - /*! \page config - - \b add Adds a detector at the end of the multi-detector structure. \c put argument is the hostname or IP adress. Returns the chained list of detector hostnames. - */ - - descrToFuncMap[i].m_pFuncName="add";//OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdd; - i++; - - /*! \page config - - remove i Removes controller \c i from the multi-detector structure. Can be used for partial readout of the detector. - */ - - descrToFuncMap[i].m_pFuncName="remove";//OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRemove; - i++; - - - /*! \page config - - type Sets/gets detector type (string). - */ - - descrToFuncMap[i].m_pFuncName="type"; //OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdHostname; - i++; - - /*! \page config - - hostname \c put adds the hostname (ot IP adress) at the end of the multi-detector structure. If used for a single controlled (i:) replaces the current hostname. Returns the list of the hostnames of the multi-detector structure. - */ - - descrToFuncMap[i].m_pFuncName="hostname"; //OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdHostname; - i++; - - /*! \page config - - id[:i] Returns the id of the detector structure. i is the detector position in a multi detector system. If used a \c put, configures the id of the detector structure. i is the detector position in a multi detector system and l is the id of the detector to be added. - */ - - descrToFuncMap[i].m_pFuncName="id"; //OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdId; - i++; - - /*! \page config - - master i \c put sets the position of the master of the acquisition (-1 if none). Returns the position of the master of the detector structure (-1 if none). - */ - descrToFuncMap[i].m_pFuncName="master"; //OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdMaster; - i++; - - /*! \page config - - sync Sets/gets the synchronization mode of the detectors in the multi-detector structure. Can be: \c none, \c gating, \c trigger, \c complementary. Mainly used by MYTHEN/GOTTHARD. - */ - descrToFuncMap[i].m_pFuncName="sync"; //OK - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSync; - i++; /*! \page test - help Returns a list of possible commands. @@ -210,6 +97,748 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdExitServer; i++; + /*! \page test + - flippeddatay [i] enables/disables data being flipped across y axis. 1 enables, 0 disables. Not implemented. + */ + descrToFuncMap[i].m_pFuncName="flippeddatay"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /* digital test and debugging */ + + /*! \page test + - digitest [i] will perform test which will plot the unique channel identifier, instead of data. Only get! + */ + descrToFuncMap[i].m_pFuncName="digitest"; // /* find command! */ + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; + i++; + + /*! \page test + - bustest performs test of the bus interface between FPGA and embedded Linux system. Can last up to a few minutes. Cannot set! Used for Mythen only. Only get! + */ + descrToFuncMap[i].m_pFuncName="bustest"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; + i++; + + /*! \page test + - digibittest:[i] performs digital test of the module i. Returns 0 if succeeded, otherwise error mask. Only put! + */ + descrToFuncMap[i].m_pFuncName="digibittest"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; + i++; + + /*! \page test + - reg [addr] [val] ??? writes to an register \c addr with \c value in hexadecimal format. + */ + descrToFuncMap[i].m_pFuncName="reg"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; + i++; + + /*! \page test + - adcreg [addr] [val] ??? writes to an adc register \c addr with \c value in hexadecimal format. Only put! + */ + descrToFuncMap[i].m_pFuncName="adcreg"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; + i++; + + /*! \page test + - setbit ??? Only put! + */ + descrToFuncMap[i].m_pFuncName="setbit"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; + i++; + + /*! \page test + - clearbit ??? Only put! + */ + descrToFuncMap[i].m_pFuncName="clearbit"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; + i++; + + /*! \page test + - getbit ??? Only get! + */ + descrToFuncMap[i].m_pFuncName="getbit"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; + i++; + + /*! \page test + - r_compression [i] sets/gets compression in receiver. 1 sets, 0 unsets. Not implemented. + */ + descrToFuncMap[i].m_pFuncName="r_compression"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; + i++; + + + + /* Acquisition and status commands */ + /*! \page acquisition Acquition commands + Commands to control the acquisition + */ + /*! \page acquisition + - \b acquire blocking acquisition (like calling sls_detector_acquire). Starts receiver and detector, writes and processes the data, stops detector. Only get! + \c Returns (string)\c "acquire unsuccessful" if fails, else "" for MYTHEN, \c "Acquired (int)" for others, where int is number of frames caught. + */ + descrToFuncMap[i].m_pFuncName="acquire"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAcquire; + i++; + + /*! \page acquisition + - \b busy returns \c 1 if the acquisition is active, \c 0 otherwise. Works when the acquisition is started in blocking mode. Only get! \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="busy"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdStatus; + i++; + + /*! \page acquisition + - status [s] starts or stops acquisition in detector in non blocking mode. \c s: [\c start, \c stop]. \c Returns the detector status: [\c running, \c error, \c transmitting, \c finished, \c waiting, \c idle]. \c Returns \c (string) + */ + descrToFuncMap[i].m_pFuncName="status"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdStatus; + i++; + + /*! \page acquisition + - \b data gets all data from the detector (if any) processes them and writes them to file according to the preferences already setup (MYTHEN only). Only get! + */ + descrToFuncMap[i].m_pFuncName="data"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdData; + i++; + + /*! \page acquisition + - \b frame gets a single frame from the detector (if any) processes it and writes it to file according to the preferences already setup (MYTHEN only). Only get! + */ + descrToFuncMap[i].m_pFuncName="frame"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFrame; + i++; + + /*! \page acquisition + - readctr Reads the counters from the detector memory (analog detector returning values translated into number of photons - only GOTTHARD). Cannot put. + */ + descrToFuncMap[i].m_pFuncName="readctr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; + i++; + + /*! \page acquisition + - resetctr i Resets counter in detector, restarts acquisition if i=1(analog detector returning values translated into number of photons - only GOTTHARD). Cannot put. + */ + descrToFuncMap[i].m_pFuncName="resetctr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; + i++; + + /*! \page acquisition + - resmat i sets/resets counter bit in detector.gets the counter bit in detector ???? + */ + descrToFuncMap[i].m_pFuncName="resmat"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; + i++; + + + + + /*! \page config Configuration commands + Commands to configure the detector. these commands are often left to the configuration file. + - \ref configstructure "Data Structure": commands to configure detector data structure + - \ref configstatus "Status": commands to configure detector status + - \ref configsize "Data Size": commands to configure detector data size + - \ref configflags "Flags": commands to configure detector flags + - \ref configchip "Chip": commands to configure chip of the detector + - \ref configversions "Versions": commands to check version of each subsytem + - \ref configspeed "Speed": commands to configure speed of detector + - \ref configsettings "Detector Parameters": commands to configure/retrieve configuration of detector + */ + /*! \page timing Timing commands + Commands to setup the timing + */ + /* Detector structure configuration and debugging commands */ + /*! \page config + \section configstructure Data Structure + commands to configure detector data structure + */ + + /*! \page config + - externalgui sets/gets external gui flag. 1 sets and enables the 0MQ data stream (0MQ threads created) from receiver to client, while 0 unsets and disables. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="externalgui"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDataStream; + i++; + + /*! \page config + - \b free Free shared memory on the control PC + */ + descrToFuncMap[i].m_pFuncName="free";//OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFree; + i++; + + /*! \page config + - \b add Adds a detector at the end of the multi-detector structure. \c put argument is the hostname or IP adress. Returns the chained list of detector hostnames. + */ + descrToFuncMap[i].m_pFuncName="add";//OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdd; + i++; + + /*! \page config + - remove i Removes controller \c i from the multi-detector structure. Can be used for partial readout of the detector. + */ + descrToFuncMap[i].m_pFuncName="remove";//OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRemove; + i++; + + /*! \page config + - type Sets/gets detector type. \c Returns \c (string). Normally not used. Using hostname is enough. + */ + descrToFuncMap[i].m_pFuncName="type"; //OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdHostname; + i++; + + /*! \page config + - hostname \c put adds the hostname (ot IP adress) at the end of the multi-detector structure. If used for a single controlled (i:) replaces the current hostname. Returns the list of the hostnames of the multi-detector structure. \c Returns \c (string) + */ + descrToFuncMap[i].m_pFuncName="hostname"; //OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdHostname; + i++; + + /*! \page config + - id[:i] Returns the id of the detector structure. i is the detector position in a multi detector system. If used a \c put, configures the id of the detector structure. i is the detector position in a multi detector system and l is the id of the detector to be added. + */ + descrToFuncMap[i].m_pFuncName="id"; //OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdId; + i++; + + /*! \page config + - master i \c put sets the position of the master of the acquisition (-1 if none). Returns the position of the master of the detector structure (-1 if none). + */ + descrToFuncMap[i].m_pFuncName="master"; //OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdMaster; + i++; + + /*! \page config + - sync Sets/gets the synchronization mode of the detectors in the multi-detector structure. Can be: \c none, \c gating, \c trigger, \c complementary. Mainly used by MYTHEN/GOTTHARD. + */ + descrToFuncMap[i].m_pFuncName="sync"; //OK + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSync; + i++; + + /*! \page config + \section configstatus Status + commands to configure detector status + */ + + /*! \page config + - online [i] sets the detector in online (1) or offline (0) mode. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="online"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; + i++; + + /*! \page config + - checkonline returns the hostnames of all detectors without connecting to them. \c Returns (string) "All online" or "[list of offline hostnames] : Not online". + */ + descrToFuncMap[i].m_pFuncName="checkonline"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; + i++; + /*! \page config + - activate Activates/Deactivates the detector. Deactivated detector does not send data. Used for EIGER only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="activate"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; + i++; + + + /* detector and data size */ + /*! \page config + \section configsize Data Size + commands to configure detector data size + */ + + /*! \page config + - nmod [i] sets/gets the number of modules of the detector. Used for MYTHEN only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="nmod"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - maxmod Gets the maximum number of modules of the detector. Used for MYTHEN only. Cannot put! \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="maxmod"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - dr [i] sets/gets the dynamic range of detector. Mythen [4,8,16,24]. Eiger [4,8,16,32]. Others cannot put! \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="dr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - roi [i] [xmin] [xmax] [ymin] [ymax] sets region of interest of the detector, where i is number of rois;i=0 to clear rois. Used for GOTTHARD only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="roi"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - detsizechan [xmax] [ymax] sets the maximum number of channels in each dimension for complete detector set; -1 is no limit. Use for multi-detector system as first command in config file. \c Returns \c ("int int") + */ + descrToFuncMap[i].m_pFuncName="detsizechan"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - roimask [i] ?? \c Returns \c (int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="roimask"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - flippeddatax [i] enables/disables data being flipped across x axis. 1 enables, 0 disables. Used for EIGER only. 1 for bottom half-module, 0 for top-half module. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="flippeddatax"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; + i++; + + /*! \page config + - tengiga [i] enables/disables 10GbE in system (detector & receiver). 1 enabled 10GbE, 0 enables 1GbE. Used in EIGER only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="tengiga"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; + i++; + + + /* flags */ + /*! \page config + \section configflags Flags + commands to configure detector flags + */ + + /*! \page config + - flags [flag] sets/gets the readout flags to mode. Options: none, storeinram, tot, continous, parallel, nonparallel, safe, digital, analog_digital, unknown. Used for MYTHEN and EIGER only. \c Returns \c (string). put takes one string and \c returns concatenation of all active flags separated by spaces. + */ + descrToFuncMap[i].m_pFuncName="flags"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + /*! \page config + - extsig:[i] [flag] sets/gets the mode of the external signal i. Options: \c off, \c gate_in_active_high, \c gate_in_active_low, \c trigger_in_rising_edge, \c trigger_in_falling_edge, + \c ro_trigger_in_rising_edge, \c ro_trigger_in_falling_edge, \c gate_out_active_high, \c gate_out_active_low, \c trigger_out_rising_edge, \c trigger_out_falling_edge, \c ro_trigger_out_rising_edge, + \c ro_trigger_out_falling_edge. \n Used in MYTHEN, GOTTHARD, PROPIX only. \c Returns \c (string) + */ + descrToFuncMap[i].m_pFuncName="extsig"; /* find command! */ + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + + /* fpga */ + + + /*! \page config + - programfpga [file] programs the FPGA with file f (with .pof extension). Used for JUNGFRAU, MOENCH only. Only put! \c Returns \c ("successful", "unsuccessful") + */ + descrToFuncMap[i].m_pFuncName="programfpga"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + /*! \page config + - resetfpga [f] resets FPGA, where f can be any value. Used for JUNGFRAU only. Only put! \c Returns \c ("successful", "unsuccessful") + */ + descrToFuncMap[i].m_pFuncName="resetfpga"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + + /* chip */ + /*! \page config + \section configchip Chip + commands to configure chip of the detector + */ + + /*! \page config + - powerchip [i] Powers on/off the chip. 1 powers on, 0 powers off. Can also get the power status. Used for JUNGFRAU only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="powerchip"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + /*! \page config + - led [i] sets/gets the led status. 1 on, 0 off. Used for MOENCH only ?? \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="led"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; + i++; + + /*! \page config + - pulse [n] [x] [y] pulses pixel at coordinates (x,y) n number of times. Used in EIGER only. Only put! \c Returns \c ("successful", "unsuccessful") + */ + descrToFuncMap[i].m_pFuncName="pulse"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; + i++; + + /*! \page config + - pulsenmove [n] [x] [y] pulses pixel n number of times and moves relatively by x value (x axis) and y value(y axis). Used in EIGER only. Only put! \c Returns \c ("successful", "unsuccessful") + */ + descrToFuncMap[i].m_pFuncName="pulsenmove"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; + i++; + + /*! \page config + - pulsechip [n]pulses chip n number of times, while n=-1 will reset it to normal mode. Used in EIGER only. Only put! \c Returns \c ("successful", "unsuccessful") + */ + descrToFuncMap[i].m_pFuncName="pulsechip"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; + i++; + + + + + /* versions/ serial numbers getId */ + /*! \page config + \section configversions Versions + Commands to check versions of each subsystem + */ + + /*! \page config + - moduleversion:[i] Gets the firmware version of module i. Used for MYTHEN only. Only get! \c Returns \c (long int) in hexadecimal or "undefined module number" + */ + descrToFuncMap[i].m_pFuncName="moduleversion"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - detectornumber Gets the serial number or MAC of detector. Only get! \c Returns \c (long int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="detectornumber"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - modulenumber:[i] Gets the serial number of module i. Used for MYTHEN only. Only get! \c Returns \c (long int) in hexadecimal or "undefined module number" + */ + descrToFuncMap[i].m_pFuncName="modulenumber"; /* find command! */ + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - detectorversion Gets the firmware version of detector. Only get! \c Returns \c (long int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="detectorversion"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - softwareversion Gets the software version of detector server. Only get! \c Returns \c (long int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="softwareversion"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - thisversion Gets the software version of this client software. Only get! \c Returns \c (long int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="thisversion"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /*! \page config + - receiverversion Gets the software version of receiver. Only get! \c Returns \c (long int) in hexadecimal + */ + descrToFuncMap[i].m_pFuncName="receiverversion"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; + i++; + + /* r/w timers */ + + + /*! \page timing + - timing [mode] sets/gets synchronization mode of the detector. Mode: auto, trigger, ro_trigger, gating, triggered_gating (string) + */ + descrToFuncMap[i].m_pFuncName="timing"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTiming; + i++; + + + /*! \page timing + - exptime [i] sets/gets exposure time in s. \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="exptime"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - subexptime [i] sets/gets sub exposure time in s. Used in EIGER only in 32 bit mode. \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="subexptime"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - period [i] sets/gets frame period in s. \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="period"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - delay [i] sets/gets delay in s. Used in MYTHEN, GOTTHARD only. \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="delay"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - gates [i] sets/gets number of gates. Used in MYTHEN, GOTTHARD only. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="gates"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - frames [i] sets/gets number of frames. If \c timing is not \c auto, then it is the number of frames per cycle/trigger. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="frames"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - cycles [i] sets/gets number of triggers. Timing mode should be set appropriately. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="cycles"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - probes [i] sets/gets number of probes to accumulate. When setting, max 3! cycles should be set to 1, frames to the number of pump-probe events. Used in MYTHEN only. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="probes"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - measurements [i] sets/gets number of measurements. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="measurements"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /*! \page timing + - samples [i] sets/gets number of samples expected from the jctb. Used in CHIP TEST BOARD only. \c Returns \c (long long int) + */ + descrToFuncMap[i].m_pFuncName="samples"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + i++; + + /* read only timers */ + + /*! \page timing + - exptimel gets exposure time left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="exptimel"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - periodl gets frame period left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="periodl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - delayl gets delay left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="delayl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - gatesl gets number of gates left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="gatesl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page config + - framesl gets number of frames left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="framesl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - cyclesl gets number of cylces left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="cyclesl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - probesl gets number of probes left. Used in MYTHEN, GOTTHARD only. Only get! \c Returns \c (double with 9 decimal digits) + */ + descrToFuncMap[i].m_pFuncName="probesl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + // descrToFuncMap[i].m_pFuncName="progress"; + // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; + // i++; + + /*! \page timing + - now Actual time of the detector. Only get! + */ + descrToFuncMap[i].m_pFuncName="now"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - timestamp Last frame timestamp for MYTHEN. Only get! + */ + descrToFuncMap[i].m_pFuncName="timestamp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /*! \page timing + - nframes ??? Only get! + */ + descrToFuncMap[i].m_pFuncName="nframes"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; + i++; + + /* speed */ + /*! \page config + \section configspeed Speed + commands to configure speed of detector + */ + + /*! \page config + - clkdivider [i] sets/gets the readout clock divider. EIGER, JUNGFRAU [0(fast speed), 1(half speed), 2(quarter speed)]. MYTHEN[???]. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="clkdivider"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - setlength [i] sets/gets length of set/reset signals (in clock cycles). Used in MYTHEN only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="setlength"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - waitstates [i] sets/gets waitstates of the bus interface (in clock cycles). Used in MYTHEN only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="waitstates"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - totdivider [i] sets/gets clock divider in tot mode. Used in MYTHEN only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="totdivider"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - totdutycycle [i] sets/gets duty cycle of the tot clock. Used in MYTHEN only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="totdutycycle"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - phasestep [i] Only put for gotthard. Moves the phase of the ADC clock.\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="phasestep"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - oversampling [i] Sets/gets the number of adcsamples per clock. For the new chiptestboard.\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="oversampling"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - adcclk [i] sets/gets the ADC clock frequency in MHz. For the new chiptestboard!\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="adcclk"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - adcphase [i] Sets/gets the ADC clock frequency in MHz. For the new chiptestboard!\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="adcphase"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - adcpipeline [i] Sets/gets the pipeline of the ADC. For the new chiptestbaord!\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="adcpipeline"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - dbitclk [i] Sets/gets the clock frequency of the latching of the digital bits in MHz. For the new chiptestboard!\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="dbitclk"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - dbitphase [i] Sets/gets the phase of the clock for latching of the digital bits. For the new chiptestboard!?\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="dbitphase"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + /*! \page config + - dbitpipeline [i] Sets/gets the pipeline of the latching of the digital bits. For the new chiptestbaord!\c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="dbitpipeline"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; + i++; + + + /* settings dump/retrieve */ + /*! \page config + \section configsettings Detector Parameters + commands to configure/retrieve configuration of detector + */ + + /*! \page config + - config [fname] sets/saves detector/receiver to configuration contained in fname. Same as executing sls_detector_put for every line. Normally a one time operation. \c Returns \c (string) fname + */ + descrToFuncMap[i].m_pFuncName="config"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; + i++; + + /* settings dump/retrieve */ + /*! \page config + - rx_printconfig prints the receiver configuration. Only get! \c Returns \c (string) + */ + descrToFuncMap[i].m_pFuncName="rx_printconfig"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; + i++; + + /*! \page config + - parameters [fname] sets/saves detector parameters contained in fname. Normally once per different measurement. \c Returns \c (string) fname + */ + descrToFuncMap[i].m_pFuncName="parameters"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; + i++; + + /*! \page config + - setup [fname] sets/saves detector complete setup contained in fname (extensions automatically generated), including trimfiles, ff coefficients etc. \c Returns \c (string) fname + */ + descrToFuncMap[i].m_pFuncName="setup"; + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; + i++; + + + /* data processing commands */ @@ -217,7 +846,7 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { Commands to setup the data processing (mainly MYTHEN related) */ /*! \page data - - flatfield [fn] \c put sets flatfield file to \c fn (relative to \c ffdir). \get returns the flatfield file name relative to \c ffdir (string). If \fn is specified, it writes the flat field correction factors and errors to \c fn. + - flatfield [fn] \c put sets flatfield file to \c fn (relative to \c ffdir). \get returns the flatfield file name relative to \c ffdir (string). If \fn is specified, it writes the flat field correction factors and errors to \c fn. \c Returns \c (string) fn \c none disables flat field corrections. */ descrToFuncMap[i].m_pFuncName="flatfield"; // @@ -225,35 +854,29 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { i++; /*! \page data - - ffdir [d] Sets/gets the directory in which the flat field file is located. + - ffdir [d] Sets/gets the directory in which the flat field file is located. \c Returns \c (string) ffdir */ descrToFuncMap[i].m_pFuncName="ffdir"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFlatField; i++; /*! \page data - - ratecorr [ns] Returns the dead time used for rate correections in ns (int). \c put sets the deadtime correction constant in ns, -1 will set it to default tau of settings (0 unset). - + - ratecorr [ns] Returns the dead time used for rate correections in ns (int). \c put sets the deadtime correction constant in ns, -1 will set it to default tau of settings (0 unset). \c Returns \c (double with 9 decimal digit precision) */ descrToFuncMap[i].m_pFuncName="ratecorr"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRateCorr; i++; - /*! \page data - badchannels [fn] \c put sets the badchannels file to \c fn . \get returns the bad channels file name. If \fn is specified, it writes the badchannels to \c fn. \c none disables badchannel corrections. - */ descrToFuncMap[i].m_pFuncName="badchannels"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdBadChannels; i++; - /*! \page data - angconv [fn] \c put sets the angular conversion file to \c fn . \get returns the angular conversion file name. If \fn is specified, it writes the angular conversion factors to \c fn. \c none disables angular corrections. - */ - descrToFuncMap[i].m_pFuncName="angconv"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; @@ -261,7 +884,6 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { /*! \page data - globaloff [f] Sets/gets the beamline angular global offset (float). */ - descrToFuncMap[i].m_pFuncName="globaloff"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; @@ -270,7 +892,6 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { - fineoff [f] Sets/gets the angular fine offset of the measurement (float). */ //2017/08/15 - descrToFuncMap[i].m_pFuncName="fineoff"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; @@ -278,20 +899,17 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { /*! \page data - binsize [f] Sets/gets the bin size used for the angular conversion (float). */ - descrToFuncMap[i].m_pFuncName="binsize" ;// descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; /*! \page data - - angdir [i] Sets/gets the angular direction. 1 means increasing channels number as increasing angle, -1 increasing channel number decreasing angle. + - angdir [i] Sets/gets the angular direction. 1 means increasing channels number as increasing angle, -1 increasing channel number decreasing angle. */ - descrToFuncMap[i].m_pFuncName="angdir" ;// descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; - /*! \page data - moveflag [i] Sets/gets the flag for physically moving the detector during the acquisition of several positions. 1 sets (moves), 0 unsets. */ @@ -306,7 +924,6 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; - /*! \page data - sampley [f] Sets/gets the sample displacement in th direction orthogonal to the beam in um. Unused! */ @@ -314,7 +931,6 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAngConv; i++; - /*! \page data - threaded [i] Sets/gets the data processing threaded flag. 1 is threaded, 0 unthreaded. */ @@ -336,140 +952,682 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdImage; i++; - /*! \page acquisition - - readctr Reads the counters from the detector memory (analog detector returning values translated into number of photons - only GOTTHARD). Cannot put. - */ - descrToFuncMap[i].m_pFuncName="readctr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; - i++; - /*! \page acquisition - - resetctr i Resets counter in detector, restarts acquisition if i=1(analog detector returning values translated into number of photons - only GOTTHARD). Cannot put. - */ - descrToFuncMap[i].m_pFuncName="resetctr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; - i++; - /*! \page acquisition - - resmat i sets/resets counter bit in detector.gets the counter bit in detector ???? - */ - descrToFuncMap[i].m_pFuncName="resmat"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCounter; - i++; - /* trim/cal directories */ + /*! \page settings Detector settings commands Commands to setup the settings of the detector + - \ref settingsdir "Settings, trim & cal Directories": commands to setup settings/trim/cal directories + - \ref settingssett "Settings and Threshold": commands to configure settings and threshold of detector + - \ref settingsdacs "DACs": commands to configure DACs of detector + - \ref settingsadcs "ADCs": commands to readout ADCs of detector */ + /* trim/cal directories */ /*! \page settings - - settingsdir [dir] Sets/gets the directory where the settings files are located (string) + \section settingsdir Settings, trim & cal Directories + commands to setup settings/trim/cal directories + */ + /*! \page settings + - settingsdir [dir] Sets/gets the directory where the settings files are located. \c Returns \c (string) dir */ descrToFuncMap[i].m_pFuncName="settingsdir"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettingsDir; i++; /*! \page settings - - trimdir [dir] obsolete \c settingsdir + - trimdir [dir] obsolete \c settingsdir. \c Returns \c (string) dir */ descrToFuncMap[i].m_pFuncName="trimdir"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettingsDir; i++; /*! \page settings - - caldir [dir] Sets/gets the directory where the calibration files are located (string) + - caldir [dir] Sets/gets the directory where the calibration files are located. \c Returns \c (string) dir */ descrToFuncMap[i].m_pFuncName="caldir"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdCalDir; i++; /*! \page settings - - trimen [n e0 e1...e(n-1)] Sets/gets the number of energies n at which the detector has default trim file and their values in eV (int) + - trimen [n e0 e1...e(n-1)] Sets/gets the number of energies n at which the detector has default trim file and their values in eV (int). \c Returns \c (int int...) n e0 e1...e(n-1) */ descrToFuncMap[i].m_pFuncName="trimen"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTrimEn; i++; + /* settings, threshold */ + /*! \page settings + \section settingssett Settings and Threshold + commands to configure settings and threshold of detector + */ + + /*! \page settings + - settings [s] sets/gets the settings of the detector. Options: \c standard, \c fast, \c highgain, \c dynamicgain, \c lowgain, \c mediumgain, \c veryhighgain, + \c lownoise, \c dynamichg0, \c fixgain1, \c fixgain2, \c forceswitchg1, \c forceswitchg2. + \n In Eiger, only sets in client shared memory. Use \c threshold or \c thresholdnotb to pass to detector. Gets from detector. \c Returns \c (string) s + */ + descrToFuncMap[i].m_pFuncName="settings"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - threshold [eV] [sett] sets/gets the detector threshold in eV. sett is optional and if provided also sets the settings. Use this for Eiger instead of \c settings. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="threshold"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - thresholdnotb [eV] [sett] sets/gets the detector threshold in eV without loading trimbits. sett is optional and if provided also sets the settings. Use this for Eiger instead of \c settings. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="thresholdnotb"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - trimbits [fname] loads/stores the trimbits to/from the detector. If no extension is specified, the serial number of each module will be attached. \c Returns \c (string) fname + */ + descrToFuncMap[i].m_pFuncName="trimbits"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - trim:[mode] [fname] trims the detector according to mode and saves resulting trimbits to file. Mode: noise, beam, improve, fix. Used in MYTHEN only. Only put! \c Returns \c ("done") + */ + descrToFuncMap[i].m_pFuncName="trim"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - trimval [i] sets all trimbits to i. Used in EIGER only. \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="trimval"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + /*! \page settings + - pedestal [i] starts acquisition for i frames, calculates pedestal and writes back to fpga. Used in GOTTHARD only. Only put! \c Returns \c (int) + */ + descrToFuncMap[i].m_pFuncName="pedestal"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; + i++; + + + + /* pots */ + /*! \page settings + \section settingsdacs DACs + commands to configure DACs of detector + */ + + /*! \page settings + - vthreshold [i] [mv] Sets/gets detector threshold voltage for single photon counters. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vthreshold"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcalibration [i] [mv] Sets/gets the voltage of the calibration pulses. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcalibration"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vtrimbit [i] [mv] Sets/gets the voltage to set the width of the trimbits. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vtrimbit"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vpreamp [i] [mv] Sets/gets the voltage to define the preamplifier feedback resistance. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vpreamp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vhaper1 [i] [mv] Sets/gets the voltage to define the feedback resistance of the first shaper. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vshaper1"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vshaper2 [i] [mv] Sets/gets the voltage to define the feedback resistance of the second shaper. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vshaper2"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vhighvoltage [i] Sets/gets the high voltage to the sensor in V. \c Returns \c (int ["mV"]). + */ + descrToFuncMap[i].m_pFuncName="vhighvoltage"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vapower [i] Sets/gets the analog power supply for the old chiptest board in DAC units. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vapower"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vddpower [i] Sets/gets the digital power supply for the old chiptest board in DAC units. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vddpower"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vshpower [i] Sets/gets the comparator power supply for the old chiptest board in DAC units. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vshpower"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - viopower [i] Sets/gets the power supply of the FPGA I/Os for the old chiptest board in DAC units. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="viopower"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vrefds [i] [mv] Sets/gets vrefds. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vref_ds"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcascn_pb [i] [mv] Sets/gets vcascn_pb. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcascn_pb"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcasc_pb [i] [mv] Sets/gets vcasc_pb. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcascp_pb"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vout_cm [i] [mv] Sets/gets vout_cm. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vout_cm"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcasc_out [i] [mv] Sets/gets vcasc_out. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcasc_out"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vin_com [i] [mv] Sets/gets vin_com. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vin_cm"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vref_comp [i] [mv] Sets/gets vref_comp. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vref_comp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - ib_test_c [i] [mv] Sets/gets ib_test_c. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="ib_test_c"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - dac[0..7] [i] [mv] Sets/gets dac[0..7] for MOENCH02. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="dac0"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac1"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac2"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac3"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac4"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac5"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac6"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + descrToFuncMap[i].m_pFuncName="dac7"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vsvp [i] [mv] Sets/gets vsvp. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vsvp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vsvn [i] [mv] Sets/gets vsvn. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vsvn"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vtr [i] [mv] Sets/gets vtr. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vtr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vrf [i] [mv] Sets/gets vrf. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vrf"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vrs [i] [mv] Sets/gets vrs. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vrs"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vtgstv [i] [mv] Sets/gets vtgstv. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vtgstv"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcmp_ll [i] [mv] Sets/gets vcmp_ll. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcmp_ll"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcmp_lr [i] [mv] Sets/gets vcmp_lr. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcmp_lr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcal_l [i] [mv] Sets/gets vcal_l. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcall"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcomp_rl [i] [mv] Sets/gets vcomp_rl. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcmp_rl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcomp_rr [i] [mv] Sets/gets vcomp_rr. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcmp_rr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - rxb_rb [i] [mv] Sets/gets rxb_rb. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="rxb_rb"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - rxb_lb [i] [mv] Sets/gets rxb_lb. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="rxb_lb"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcp [i] [mv] Sets/gets vcp. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vcn [i] [mv] Sets/gets vcn. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vcn"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - vis [i] [mv] Sets/gets vis. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="vis"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - iodelay [i] [mv] Sets/gets iodelay. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="iodelay"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + + /*! \page settings + - dac:j [i] [mv] Sets/gets value for DAC number j for the new chiptestboard. Normally in DAC units unless \c mv is specified at the end of the command line. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="dac"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + + + /*! \page settings + - adcvpp [i] Sets/gets the Vpp of the ADC 0 -> 1V ; 1 -> 1.14V ; 2 -> 1.33V ; 3 -> 1.6V ; 4 -> 2V . \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="adcvpp"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + + /*! \page settings + - v_a [i] mv Sets/gets value for Va on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_a"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - v_b [i] mv Sets/gets value for Vb on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_b"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - v_c [i] mv Sets/gets value for Vc on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_c"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - v_d [i] mv Sets/gets value for Vd on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_d"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - v_io [i] mv Sets/gets value for Vio on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_io"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + + /*! \page settings + - v_chip [i] mv Sets/gets value for Vchip on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]). Normally don't use it! + */ + descrToFuncMap[i].m_pFuncName="v_chip"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /*! \page settings + - v_limit [i] mv Sets/gets a soft limit for the power supplies and the DACs on the new chiptest board. Must be in mV. \c Returns \c (int ["mV"]) + */ + descrToFuncMap[i].m_pFuncName="v_limit"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; + i++; + + /* r/w timers */ + /*! \page settings + \section settingsadcs ADCs + commands to readout ADCs of detector + */ + + /*! \page settings + - temp_adc Gets the ADC temperature. \c Returns \c EIGER,JUNGFRAU(double"°C") Others \c (int"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_adc"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_fpga Gets the FPGA temperature. \c Returns \c EIGER,JUNGFRAU(double"°C") Others \c (int"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_fpga"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_fpgaext Gets the external FPGA temperature. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_fpgaext"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_10ge Gets the 10Gbe temperature. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_10ge"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_dcdc Gets the temperature of the DC/DC converter. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_dcdc"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_sodl Gets the temperature of the left so-dimm memory . Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_sodl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_sodr Gets the temperature of the right so-dimm memory. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_sodr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + + /*! \page settings + - adc:j Gets the values of the slow ADC number j for the new chiptest board. \c Returns \c (int"°C") + */ + descrToFuncMap[i].m_pFuncName="adc"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_fpgal Gets the temperature of the left frontend FPGA. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_fpgafl"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - temp_fpgar Gets the temperature of the right frontend FPGA. Used in EIGER only. \c Returns \c EIGER(double"°C") + */ + descrToFuncMap[i].m_pFuncName="temp_fpgafr"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + + /*! \page settings + - i_a Gets the current of the power supply a on the new chiptest board. \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="i_a"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - i_b Gets the current of the power supply b on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="i_b"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - i_c Gets the current of the power supply c on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="i_c"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - i_d Gets the current of the power supply d on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="i_d"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - i_io Gets the current of the power supply io on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="i_io"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - vm_a Gets the measured voltage of the power supply a on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="vm_a"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - vm_b Gets the measured voltage of the power supply b on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="vm_b"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - vm_c Gets the measured voltage of the power supply c on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="vm_c"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - vm_d Gets the measured voltage of the power supply d on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="vm_d"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + /*! \page settings + - vm_io Gets the measured voltage of the power supply io on the new chiptest board \c Returns \c (int"mV") + */ + descrToFuncMap[i].m_pFuncName="vm_io"; // + descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; + i++; + + + /* file name */ - /*! \page output Output settings Commands to setup the file destination and format */ /*! \page output - - outdir [dir] Sets/gets the file output directory (string) + - outdir [dir] Sets/gets the file output directory. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="outdir"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOutDir; i++; /*! \page output - - fname [fn] Sets/gets the root of the output file name (string) + - fname [fn] Sets/gets the root of the output file name \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="fname"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFileName; i++; /*! \page output - - index [i] Sets/gets the current file index (int) + - index [i] Sets/gets the current file index. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="index"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFileIndex; i++; - - /*! \page config - - online [i] sets the detector in online (1) or offline (0) mode - */ - descrToFuncMap[i].m_pFuncName="online"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; - i++; - - /*! \page config - - checkonline returns the hostnames of all detectors without connecting to them - */ - descrToFuncMap[i].m_pFuncName="checkonline"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; - i++; - /*! \page config - - activate Activates/Deactivates the detector. Deactivated detector does not send data. Used for EIGER only. - */ - descrToFuncMap[i].m_pFuncName="activate"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; - i++; - /*! \page output - - enablefwrite [i] Enables/disables file writing. 1 enables, 0 disables. + - enablefwrite [i] Enables/disables file writing. 1 enables, 0 disables. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="enablefwrite"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdEnablefwrite; i++; /*! \page output - - overwrite [i] enables(1) /disables(0) file overwriting + - overwrite [i] enables(1) /disables(0) file overwriting. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="overwrite"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOverwrite; i++; /*! \page output - - currentfname gets the filename for the data without index and extension + - currentfname gets the filename for the data without index and extension. MYTHEN only. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="currentfname"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFileName; i++; /*! \page output - - fileformat gets the file format for data (no put?) What are the possible return values? + - fileformat sets/gets the file format for data in receiver. Options: [ascii, binary, hdf5]. Ascii is not implemented in Receiver. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="fileformat"; //OK descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdFileName; i++; + + + /* Acquisition actions */ /*! \page actions Actions @@ -477,114 +1635,110 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { */ /*! \page actions - - positions [n [p0..pn-1]] sets/gets number of angular position and positions to be acquired. + - positions [n [p0..pn-1]] sets/gets number of angular position and positions to be acquired.. \c Returns \c (int int..) n [p0..pn-1] */ descrToFuncMap[i].m_pFuncName="positions"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPositions; i++; /*! \page actions - - startscript [s] sets/gets the script to be executed at the beginning of the acquisition. \c none unsets. + - startscript [s] sets/gets the script to be executed at the beginning of the acquisition. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="startscript"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - startscriptpar [s] sets/gets a string to be passed as a parameter to the startscript + - startscriptpar [s] sets/gets a string to be passed as a parameter to the startscript. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="startscriptpar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - stopscript [s] sets/gets the script to be executed at the end of the acquisition. \c none unsets. + - stopscript [s] sets/gets the script to be executed at the end of the acquisition. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="stopscript"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - stopscriptpar [s] sets/gets a string to be passed as a parameter to the stopscript + - stopscriptpar [s] sets/gets a string to be passed as a parameter to the stopscript. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="stopscriptpar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - scriptbefore [s] sets/gets the script to be executed before starting the detector every time in the acquisition. \c none unsets. + - scriptbefore [s] sets/gets the script to be executed before starting the detector every time in the acquisition. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="scriptbefore"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - scriptbeforepar [s] sets/gets a string to be passed as a parameter to the scriptbefore + - scriptbeforepar [s] sets/gets a string to be passed as a parameter to the scriptbefore. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="scriptbeforepar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - scriptafter [s] sets/gets the script to be executed after the detector has finished every time in the acquisition. \c none unsets. + - scriptafter [s] sets/gets the script to be executed after the detector has finished every time in the acquisition. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="scriptafter"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - scriptafterpar [s] sets/gets a string to be passed as a parameter to the scriptafter + - scriptafterpar [s] sets/gets a string to be passed as a parameter to the scriptafter. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="scriptafterpar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - headerafter [s] sets/gets the script to be executed for logging the detector parameters. \c none unsets. + - headerafter [s] sets/gets the script to be executed for logging the detector parameters. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="headerafter"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - headerbefore [s] sets/gets the script to be executed for logging the detector parameters. \c none unsets. + - headerbefore [s] sets/gets the script to be executed for logging the detector parameters. \c none unsets. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="headerbefore"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - headerbeforepar [s] sets/gets a string to be passed as a parameter to the headerbefore script + - headerbeforepar [s] sets/gets a string to be passed as a parameter to the headerbefore script. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="headerbeforepar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - headerafterpar [s] sets/gets a string to be passed as a parameter to the headerafter script + - headerafterpar [s] sets/gets a string to be passed as a parameter to the headerafter script. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="headerafterpar"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - enacallog [i] enables/disables logging of the parameters necessary for the energy calibration. 1 sets, 0 unsets. + - enacallog [i] enables/disables logging of the parameters necessary for the energy calibration. 1 sets, 0 unsets. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="encallog"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; /*! \page actions - - angcallog [i] enables/disables logging of the parameters necessary for the angular calibration. 1 sets, 0 unsets. + - angcallog [i] enables/disables logging of the parameters necessary for the angular calibration. 1 sets, 0 unsets. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="angcallog"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdScripts; i++; - - - - /*! \page actions - scan0script [s] sets/gets the script to be executed for the scan 0 level. \c none unsets. */ @@ -657,1117 +1811,377 @@ slsDetectorCommand::slsDetectorCommand(slsDetectorUtils *det) { i++; + + + /* communication configuration */ /*! \page network Network Commands to setup the network between client, detector and receiver - - rx_hostname [s] sets/gets the receiver hostname or IP address, configures detector mac with all network parameters and updates receiver with acquisition parameters. Normally used for single detectors (Can be multi-detector). \c none disables. If used, use as last network command in configuring detector MAC. + - rx_hostname [s] sets/gets the receiver hostname or IP address, configures detector mac with all network parameters and updates receiver with acquisition parameters. Normally used for single detectors (Can be multi-detector). \c none disables. If used, use as last network command in configuring detector MAC. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="rx_hostname"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - rx_udpip [ip] sets/gets the ip address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector). Used if different from eth0. + - rx_udpip [ip] sets/gets the ip address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector). Used if different from eth0. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="rx_udpip"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - rx_udpmac [mac] sets/gets the mac address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector). + - rx_udpmac [mac] sets/gets the mac address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector). \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="rx_udpmac"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - rx_udpport [port] sets/gets the port of the receiver UDP interface where the data from the detector will be streamed to. Use single-detector command. + - rx_udpport [port] sets/gets the port of the receiver UDP interface where the data from the detector will be streamed to. Use single-detector command. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="rx_udpport"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - rx_udpport2 [port] sets/gets the second port of the receiver UDP interface where the data from the second half of the detector will be streamed to. Use single-detector command. Used for EIGER only. + - rx_udpport2 [port] sets/gets the second port of the receiver UDP interface where the data from the second half of the detector will be streamed to. Use single-detector command. Used for EIGER only. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="rx_udpport2"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - detectormac [mac] sets/gets the mac address of the detector UDP interface from where the detector will stream data. Use single-detector command. Normally unused. + - detectormac [mac] sets/gets the mac address of the detector UDP interface from where the detector will stream data. Use single-detector command. Normally unused. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="detectormac"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - detectorip [ip] sets/gets the ip address of the detector UDP interface from where the detector will stream data. Use single-detector command. Keep in same subnet as rx_udpip (if rx_udpip specified). + - detectorip [ip] sets/gets the ip address of the detector UDP interface from where the detector will stream data. Use single-detector command. Keep in same subnet as rx_udpip (if rx_udpip specified). \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="detectorip"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - txndelay_left [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's left UDP port. Use single-detector command. Used for EIGER only. + - txndelay_left [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's left UDP port. Use single-detector command. Used for EIGER only. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="txndelay_left"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - txndelay_right [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's right UDP port. Use single-detector command. Used for EIGER only. + - txndelay_right [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's right UDP port. Use single-detector command. Used for EIGER only. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="txndelay_right"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - txndelay_frame [delay] sets/gets the transmission frame period of entire frame being streamed out from the detector for both ports. Use single-detector command. Used for EIGER only. + - txndelay_frame [delay] sets/gets the transmission frame period of entire frame being streamed out from the detector for both ports. Use single-detector command. Used for EIGER only. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="txndelay_frame"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - flowcontrol_10g [delay] Enables/disables 10 GbE flow control. 1 enables, 0 disables. Used for EIGER only. + - flowcontrol_10g [delay] Enables/disables 10 GbE flow control. 1 enables, 0 disables. Used for EIGER only. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="flowcontrol_10g"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - zmqport [port] sets/gets the 0MQ (TCP) port of the receiver from where data is streamed to the client. Use single-detector command to set individually or multi-detector command to calculate based on \c port for the rest. + - zmqport [port] sets/gets the 0MQ (TCP) port of the receiver from where data is streamed to the client. Use single-detector command to set individually or multi-detector command to calculate based on \c port for the rest. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="zmqport"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdNetworkParameter; i++; /*! \page network - - configuremac [i] configures the MAC of the detector with these parameters: detectorip, detectormac, rx_udpip, rx_udpmac, rx_udpport, rx_udpport2 (if applicable). Only put! + - configuremac [i] configures the MAC of the detector with these parameters: detectorip, detectormac, rx_udpip, rx_udpmac, rx_udpport, rx_udpport2 (if applicable). This command is already included in \c rx_hsotname. Only put!. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="configuremac"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfigureMac; i++; /*! \page network - - rx_tcpport [port] sets/gets the port of the client-receiver TCP interface. Use single-detector command. Is different for each detector if same \c rx_hostname used. Must be first command to communicate with receiver. + - rx_tcpport [port] sets/gets the port of the client-receiver TCP interface. Use single-detector command. Is different for each detector if same \c rx_hostname used. Must be first command to communicate with receiver. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="rx_tcpport"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPort; i++; /*! \page network - - port [port] sets/gets the port of the client-detector control server TCP interface. Use single-detector command. Default value is 1952 for all detectors. Normally not changed. + - port [port] sets/gets the port of the client-detector control server TCP interface. Use single-detector command. Default value is 1952 for all detectors. Normally not changed. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="port"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPort; i++; /*! \page network - - stopport [port] sets/gets the port of the client-detector stop server TCP interface. Use single-detector command. Default value is 1953 for all detectors. Normally not changed. + - stopport [port] sets/gets the port of the client-detector stop server TCP interface. Use single-detector command. Default value is 1953 for all detectors. Normally not changed. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="stopport"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPort; i++; - /*! \page config - - lock [i] Locks/Unlocks the detector to communicate with this client. 1 locks, 0 unlocks. + + /*! \page network + - lock [i] Locks/Unlocks the detector to communicate with this client. 1 locks, 0 unlocks. \c Returns \c (int) */ descrToFuncMap[i].m_pFuncName="lock"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdLock; i++; /*! \page network - - lastclient Gets the last client communicating with the detector. Cannot put! + - lastclient Gets the last client communicating with the detector. Cannot put!. \c Returns \c (string) */ descrToFuncMap[i].m_pFuncName="lastclient"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdLastClient; i++; - /* detector and data size */ - /*! \page config - - nmod [i] sets/gets the number of modules of the detector. Used for MYTHEN only. - */ - descrToFuncMap[i].m_pFuncName="nmod"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - maxmod Gets the maximum number of modules of the detector. Used for MYTHEN only. Cannot put! - */ - descrToFuncMap[i].m_pFuncName="maxmod"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - dr [i] sets/gets the dynamic range of detector. Mythen [4,8,16,24]. Eiger [4,8,16,32]. Others cannot put! - */ - descrToFuncMap[i].m_pFuncName="dr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - roi [i] [xmin] [xmax] [ymin] [ymax] sets region of interest of the detector, where i is number of rois;i=0 to clear rois. Used for GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="roi"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - detsizechan [xmax] [ymax] sets the maximum number of channels in each dimension for complete detector set; -1 is no limit. Use for multi-detector system as first command in config file. - */ - descrToFuncMap[i].m_pFuncName="detsizechan"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - roimask [i] ?? - */ - descrToFuncMap[i].m_pFuncName="roimask"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page config - - flippeddatax [i] enables/disables data being flipped across x axis. 1 enables, 0 disables. Used for EIGER only. 1 for bottom half-module, 0 for top-half module. - */ - descrToFuncMap[i].m_pFuncName="flippeddatax"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /*! \page test - - flippeddatay [i] enables/disables data being flipped across y axis. 1 enables, 0 disables. Not implemented. - */ - descrToFuncMap[i].m_pFuncName="flippeddatay"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDetectorSize; - i++; - /* flags */ - /*! \page config - - flags [flag] sets/gets the readout flags to mode. Options: none, storeinram, tot, continous, parallel, nonparallel, safe, digital, analog_digital, unknown. Used for MYTHEN and EIGER only. - */ - descrToFuncMap[i].m_pFuncName="flags"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - /*! \page config - - extsig:[i] [flag] sets/gets the mode of the external signal i. Options: \c off, \c gate_in_active_high, \c gate_in_active_low, \c trigger_in_rising_edge, \c trigger_in_falling_edge, - \c ro_trigger_in_rising_edge, \c ro_trigger_in_falling_edge, \c gate_out_active_high, \c gate_out_active_low, \c trigger_out_rising_edge, \c trigger_out_falling_edge, \c ro_trigger_out_rising_edge, - \c ro_trigger_out_falling_edge. \n Used in MYTHEN, GOTTHARD, PROPIX only. - */ - descrToFuncMap[i].m_pFuncName="extsig"; /* find command! */ - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - - /* fpga */ - - /*! \page config - - programfpga [file] programs the FPGA with file f (with .pof extension). Used for JUNGFRAU, MOENCH only. Only put! - */ - descrToFuncMap[i].m_pFuncName="programfpga"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - /*! \page config - - resetfpga [f] resets FPGA, where f can be any value. Used for JUNGFRAU only. Only put! - */ - descrToFuncMap[i].m_pFuncName="resetfpga"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - - /* chip */ - - /*! \page config - - powerchip [i] Powers on/off the chip. 1 powers on, 0 powers off. Can also get the power status. Used for JUNGFRAU only. - */ - descrToFuncMap[i].m_pFuncName="powerchip"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - - - /* chip */ - - /*! \page config - - led [i] sets/gets the led status. 1 on, 0 off. Used for MOENCH only ?? - */ - descrToFuncMap[i].m_pFuncName="led"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdAdvanced; - i++; - - - - /* versions/ serial numbers getId */ - - /*! \page config - - moduleversion:[i] Gets the firmware version of module i. Used for MYTHEN only. Only get! - */ - descrToFuncMap[i].m_pFuncName="moduleversion"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - detectornumber Gets the serial number or MAC of detector. Only get! - */ - descrToFuncMap[i].m_pFuncName="detectornumber"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - modulenumber:[i] Gets the serial number of module i. Used for MYTHEN only. Only get! - */ - descrToFuncMap[i].m_pFuncName="modulenumber"; /* find command! */ - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - detectorversion Gets the firmware version of detector. Only get! - */ - descrToFuncMap[i].m_pFuncName="detectorversion"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - softwareversion Gets the software version of detector server. Only get! - */ - descrToFuncMap[i].m_pFuncName="softwareversion"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - thisversion Gets the software version of this client software. Only get! - */ - descrToFuncMap[i].m_pFuncName="thisversion"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - /*! \page config - - receiverversion Gets the software version of receiver. Only get! - */ - descrToFuncMap[i].m_pFuncName="receiverversion"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSN; - i++; - - - /* digital test and debugging */ - - /*! \page test - - digitest [i] will perform test which will plot the unique channel identifier, instead of data. Only get! - */ - descrToFuncMap[i].m_pFuncName="digitest"; // /* find command! */ - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; - i++; - - /*! \page test - - bustest performs test of the bus interface between FPGA and embedded Linux system. Can last up to a few minutes. Cannot set! Used for Mythen only. Only get! - */ - descrToFuncMap[i].m_pFuncName="bustest"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; - i++; - - /*! \page test - - digibittest:[i] performs digital test of the module i. Returns 0 if succeeded, otherwise error mask. Only put! - */ - descrToFuncMap[i].m_pFuncName="digibittest"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDigiTest; - i++; - - /*! \page test - - reg [addr] [val] ??? writes to an register \c addr with \c value in hexadecimal format. - */ - descrToFuncMap[i].m_pFuncName="reg"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; - i++; - - /*! \page test - - adcreg [addr] [val] ??? writes to an adc register \c addr with \c value in hexadecimal format. Only put! - */ - descrToFuncMap[i].m_pFuncName="adcreg"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; - i++; - - /*! \page test - - setbit ??? Only put! - */ - descrToFuncMap[i].m_pFuncName="setbit"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; - i++; - - /*! \page test - - clearbit ??? Only put! - */ - descrToFuncMap[i].m_pFuncName="clearbit"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; - i++; - - /*! \page test - - getbit ??? Only get! - */ - descrToFuncMap[i].m_pFuncName="getbit"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdRegister; - i++; - - - - - - - - - - - /* settings, threshold */ - - /*! \page settings - - settings [s] sets/gets the settings of the detector. Options: \c standard, \c fast, \c highgain, \c dynamicgain, \c lowgain, \c mediumgain, \c veryhighgain, - \c lownoise, \c dynamichg0, \c fixgain1, \c fixgain2, \c forceswitchg1, \c forceswitchg2. - \n In Eiger, only sets in client shared memory. Use \c threshold or \c thresholdnotb to pass to detector. Gets from detector. - */ - descrToFuncMap[i].m_pFuncName="settings"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - threshold [eV] [sett] sets/gets the detector threshold in eV. sett is optional and if provided also sets the settings. Use this for Eiger instead of \c settings. - */ - descrToFuncMap[i].m_pFuncName="threshold"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - thresholdnotb [eV] [sett] sets/gets the detector threshold in eV without loading trimbits. sett is optional and if provided also sets the settings. Use this for Eiger instead of \c settings. - */ - descrToFuncMap[i].m_pFuncName="thresholdnotb"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - trimbits [fname] loads/stores the trimbits to/from the detector. If no extension is specified, the serial number of each module will be attached. - */ - descrToFuncMap[i].m_pFuncName="trimbits"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - trim:[mode] [fname] trims the detector according to mode and saves resulting trimbits to file. Mode: noise, beam, improve, fix. Used in MYTHEN only. Only put! - */ - descrToFuncMap[i].m_pFuncName="trim"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - trimval [i] sets all trimbits to i. Used in EIGER only. - */ - descrToFuncMap[i].m_pFuncName="trimval"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - /*! \page settings - - pedestal [i] starts acquisition for i frames, calculates pedestal and writes back to fpga. Used in GOTTHARD only. Only put! - */ - descrToFuncMap[i].m_pFuncName="pedestal"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSettings; - i++; - - - - /* pots */ - - descrToFuncMap[i].m_pFuncName="vthreshold"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcalibration"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vtrimbit"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vpreamp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vshaper1"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vshaper2"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vhighvoltage"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vapower"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vddpower"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vshpower"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="viopower"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vref_ds"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcascn_pb"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcascp_pb"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vout_cm"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcasc_out"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vin_cm"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vref_comp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="ib_test_c"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac0"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac1"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac2"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac3"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac4"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac5"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac6"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="dac7"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vsvp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vsvn"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vtr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vrf"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vrs"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vtgstv"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcmp_ll"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcmp_lr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcall"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcmp_rl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcmp_rr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="rxb_rb"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="rxb_lb"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vcn"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="vis"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="iodelay"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - - descrToFuncMap[i].m_pFuncName="dac"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - - - descrToFuncMap[i].m_pFuncName="adcvpp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - - descrToFuncMap[i].m_pFuncName="v_a"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_b"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_c"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_d"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_io"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_chip"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - descrToFuncMap[i].m_pFuncName="v_limit"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdDAC; - i++; - - /* r/w timers */ - - descrToFuncMap[i].m_pFuncName="temp_adc"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_fpga"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_fpgaext"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_10ge"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_dcdc"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_sodl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_sodr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - - descrToFuncMap[i].m_pFuncName="adc"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_fpgafl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="temp_fpgafr"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - - descrToFuncMap[i].m_pFuncName="i_a"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="i_b"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="i_c"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="i_d"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="i_io"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="vm_a"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="vm_b"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="vm_c"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="vm_d"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - descrToFuncMap[i].m_pFuncName="vm_io"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdADC; - i++; - - /* r/w timers */ - - /*! \page config - - timing [mode] sets/gets synchronization mode of the detector. Mode: auto, trigger, ro_trigger, gating, triggered_gating - */ - descrToFuncMap[i].m_pFuncName="timing"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTiming; - i++; - - /*! \page config - - exptime [i] sets/gets exposure time in s - */ - descrToFuncMap[i].m_pFuncName="exptime"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - subexptime [i] sets/gets sub exposure time in s. Used in EIGER only in 32 bit mode. - */ - descrToFuncMap[i].m_pFuncName="subexptime"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - period [i] sets/gets frame period in s. - */ - descrToFuncMap[i].m_pFuncName="period"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - delay [i] sets/gets delay in s. Used in MYTHEN, GOTTHARD only - */ - descrToFuncMap[i].m_pFuncName="delay"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - gates [i] sets/gets number of gates. Used in MYTHEN, GOTTHARD, EIGER only - */ - descrToFuncMap[i].m_pFuncName="gates"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - gates [i] sets/gets number of frames. If \c timing is not \c auto, then it is the number of frames per cycle/trigger. - */ - descrToFuncMap[i].m_pFuncName="frames"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - cycles [i] sets/gets number of triggers. Timing mode should be set appropriately. - */ - descrToFuncMap[i].m_pFuncName="cycles"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - probes [i] sets/gets number of probes to accumulate. When setting, max 3! cycles should be set to 1, frames to the number of pump-probe events. Used in MYTHEN only - */ - descrToFuncMap[i].m_pFuncName="probes"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - measurements [i] sets/gets number of measurements. - */ - descrToFuncMap[i].m_pFuncName="measurements"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /*! \page config - - samples [i] sets/gets number of samples expected from the jctb. Used in CHIP TEST BOARD only. - */ - descrToFuncMap[i].m_pFuncName="samples"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - i++; - - /* read only timers */ - - /*! \page config - - exptimel [i] gets exposure time left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="exptimel"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - periodl [i] gets frame period left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="periodl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - delayl [i] gets delay left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="delayl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - gatesl [i] gets number of gates left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="gatesl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - framesl [i] gets number of frames left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="framesl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - cyclesl [i] gets number of cylces left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="cyclesl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /*! \page config - - probesl [i] gets number of probes left. Used in MYTHEN, GOTTHARD only. - */ - descrToFuncMap[i].m_pFuncName="probesl"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - // descrToFuncMap[i].m_pFuncName="progress"; - // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimer; - // i++; - - descrToFuncMap[i].m_pFuncName="now"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - descrToFuncMap[i].m_pFuncName="timestamp"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - descrToFuncMap[i].m_pFuncName="nframes"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdTimeLeft; - i++; - - /* speed */ - - descrToFuncMap[i].m_pFuncName="clkdivider"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="setlength"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="waitstates"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="totdivider"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="totdutycycle"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="phasestep"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="oversampling"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="adcclk"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="adcphase"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - - descrToFuncMap[i].m_pFuncName="adcpipeline"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - - descrToFuncMap[i].m_pFuncName="dbitclk"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - descrToFuncMap[i].m_pFuncName="dbitphase"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - - descrToFuncMap[i].m_pFuncName="dbitpipeline"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdSpeed; - i++; - - - - /* settings dump/retrieve */ - descrToFuncMap[i].m_pFuncName="config"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; - i++; - - descrToFuncMap[i].m_pFuncName="rx_printconfig"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; - i++; - - descrToFuncMap[i].m_pFuncName="parameters"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; - i++; - - descrToFuncMap[i].m_pFuncName="setup"; - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdConfiguration; - i++; /* receiver functions */ /*! \page receiver Receiver commands - Commands to configure the receiver + Commands to configure the receiver. Not used in MYTHEN. + */ + + /*! \page receiver + - receiver [s] starts/stops the receiver to listen to detector packets. Options: [ \c start, \c stop]. \c Returns \c (string) status of receiver[ \c idle, \c running]. */ descrToFuncMap[i].m_pFuncName="receiver"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; + /*! \page receiver + - r_online [i] sets/gets the receiver in online/offline mode. 1 is online, 0 is offline. Get is from shared memory. \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="r_online"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; i++; + /*! \page receiver + - r_checkonline Checks the receiver if it is online/offline mode. Only get! \c Returns (string) "All online" or "[list of offline hostnames] : Not online". + */ descrToFuncMap[i].m_pFuncName="r_checkonline"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdOnline; i++; + + /*! \page receiver + - framescaught gets the number of frames caught by receiver. Average of all for multi-detector command. Only get! \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="framescaught"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; + /*! \page receiver + - resetframescaught [i] resets the number of frames caught to 0. i can be any number. Use this if using status start, instead of acquire (this command is included). Only put! \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="resetframescaught"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; + /*! \page receiver + - frameindex [i] gets the current frame index of receiver. Average of all for multi-detector command. Only get! \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="frameindex"; descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; + /*! \page receiver + - r_lock [i] locks/unlocks the receiver to communicate with only this client. 1 locks, 0 unlocks. \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="r_lock"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdLock; i++; + /*! \page receiver + - r_lastclient gets the last client communicating with the receiver. Only get! \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="r_lastclient"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdLastClient; i++; + /*! \page receiver + - r_readfreq [i] sets/gets the stream frequency of data from receiver to client. i > 0 is the nth frame being streamed. 0 sets frequency to a default timer (200ms). \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="r_readfreq"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; - descrToFuncMap[i].m_pFuncName="r_compression"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; - i++; - - descrToFuncMap[i].m_pFuncName="tengiga"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; - i++; - + /*! \page receiver + - rx_fifodepth [i] sets/gets receiver fifo (between Listener and Writer Threads) depth to i number of frames. Can improve listener packet loss (loss due to packet processing time in Listener threads), not if limited by writing. \c Returns \c (int) + */ descrToFuncMap[i].m_pFuncName="rx_fifodepth"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdReceiver; i++; + + /* pattern generator */ - + /*! \page ctb Chiptest board + Commands specific for the new chiptest board as pattern generator + */ + + /*! \page ctb + - adcinvert [mask] Sets/gets ADC inversion mask (8 digits hex format) + */ descrToFuncMap[i].m_pFuncName="adcinvert"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; + /*! \page ctb + - adcdisable [mask] Sets/gets ADC disable mask (8 digits hex format) + */ descrToFuncMap[i].m_pFuncName="adcdisable"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; + /*! \page ctb + - pattern fn loads binary pattern file fn + */ descrToFuncMap[i].m_pFuncName="pattern"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patword addr [word] sets/gets 64 bit word at address addr of pattern memory. Both address and word in hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patword"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patioctrl [word] sets/gets 64 bit mask defining input (0) and output (1) signals. hex format. + */ descrToFuncMap[i].m_pFuncName="patioctrl"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patclkctrl [word] sets/gets 64 bit mask defining if output signal is a clock and runs. hex format. Unused at the moment. + */ descrToFuncMap[i].m_pFuncName="patclkctrl"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patlimits [addr1 addr2] sets/gets the start and stop limits of the pattern to be executed. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patlimits"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; + /*! \page ctb + - patloop0 [addr1 addr2] sets/gets the start and stop limits of the level 0 loop. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patloop0"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patnloop0 [n] sets/gets the number of cyclesof the level 0 loop (int). + */ descrToFuncMap[i].m_pFuncName="patnloop0"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwait0 [addr] sets/gets the address of the level 0 wait point. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patwait0"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwaittime0 [n] sets/gets the duration of the witing of the 0 waiting point in clock cycles (int). + */ descrToFuncMap[i].m_pFuncName="patwaittime0"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patloop1 [addr1 addr2] sets/gets the start and stop limits of the level 1 loop. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patloop1"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patnloop1 [n] sets/gets the number of cyclesof the level 1 loop (int). + */ descrToFuncMap[i].m_pFuncName="patnloop1"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwait1 [addr] sets/gets the address of the level 1 wait point. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patwait1"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwaittime1 [n] sets/gets the duration of the witing of the 1 waiting point in clock cycles (int). + */ descrToFuncMap[i].m_pFuncName="patwaittime1"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patloop2 [addr1 addr2] sets/gets the start and stop limits of the level 2 loop. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patloop2"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patnloop2 [n] sets/gets the number of cyclesof the level 2 loop (int). + */ descrToFuncMap[i].m_pFuncName="patnloop2"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwait2 [addr] sets/gets the address of the level 2 wait point. hex format. Advanced! + */ descrToFuncMap[i].m_pFuncName="patwait2"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - patwaittime2 [n] sets/gets the duration of the waiting of the 2 waiting point in clock cycles (int). + */ descrToFuncMap[i].m_pFuncName="patwaittime2"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - + /*! \page ctb + - dut_clk [i] sets/gets the signal to be used as a clock for the digital data coming from the device under test. Advanced! + */ descrToFuncMap[i].m_pFuncName="dut_clk"; // descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPattern; i++; - /* pulse */ - - descrToFuncMap[i].m_pFuncName="pulse"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; - i++; - - descrToFuncMap[i].m_pFuncName="pulsenmove"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; - i++; - - descrToFuncMap[i].m_pFuncName="pulsechip"; // - descrToFuncMap[i].m_pFuncPtr=&slsDetectorCommand::cmdPulse; - i++; - numberOfCommands=i; @@ -1881,7 +2295,10 @@ string slsDetectorCommand::cmdAcquire(int narg, char *args[], int action) { myDet->setOnline(ONLINE_FLAG); - if (myDet->setReceiverOnline(ONLINE_FLAG) == ONLINE_FLAG) { + + if (myDet->getExternalGuiFlag()) + myDet->setReceiverOnline(ONLINE_FLAG); + else if (myDet->setReceiverOnline(ONLINE_FLAG) == ONLINE_FLAG) { // command line: must be off, if receiver on or there was -1, then if (myDet->enableDataStreamingFromReceiver(-1) != 0){ //switch it off, if error @@ -2051,14 +2468,22 @@ string slsDetectorCommand::cmdDataStream(int narg, char *args[], int action) { myDet->setReceiverOnline(ONLINE_FLAG); if (action==HELP_ACTION) - return helpStatus(narg,args,HELP_ACTION); + return helpDataStream(narg,args,HELP_ACTION); if (action==PUT_ACTION) { if (!sscanf(args[1],"%d",&ival)) - return string ("cannot scan datastream mode"); + return string ("cannot scan externalgui mode"); + myDet->setExternalGuiFlag(ival>0?true:false); myDet->enableDataStreamingFromReceiver(ival); } - sprintf(ans,"%d",myDet->enableDataStreamingFromReceiver()); + + int retval = myDet->getExternalGuiFlag(); + //if external gui on and datastreaming off + if (retval && !myDet->enableDataStreamingFromReceiver()) { + retval=-1; + printf("Error: data streaming in receiver is switched off while external gui flag in shared memory is off.\n"); + } + sprintf(ans,"%d",myDet->getExternalGuiFlag()); return string(ans); } @@ -2067,9 +2492,9 @@ string slsDetectorCommand::helpDataStream(int narg, char *args[], int action) { ostringstream os; if (action==GET_ACTION || action==HELP_ACTION) - os << string("datastream \t gets if zmq data stream from receiver is enabled. \n"); + os << string("externalgui \t gets external gui flag. 1/0 means the 0MQ data stream (0MQ threads created) from receiver to client is enabled/disabled. -1 for inconsistency. \n"); if (action==PUT_ACTION || action==HELP_ACTION) - os << string("datastream i\t enables/disables the zmq data stream from receiver. \n"); + os << string("externalgui i\t sets external gui flag. 1/0 means the 0MQ data stream (0MQ threads created) from receiver to client is enabled/disabled. \n"); return os.str(); } @@ -2574,7 +2999,7 @@ string slsDetectorCommand::helpFileName(int narg, char *args[], int action){ } if (action==PUT_ACTION || action==HELP_ACTION){ os << string("fname s \t sets the filename for the data (index and extension will be automatically appended)\n"); - os << string("fname s \t sets the file format for the data (binary, ascii, hdf5)\n"); + os << string("fileformat s \t sets the file format for the data (binary, ascii, hdf5)\n"); } return os.str(); } @@ -2772,7 +3197,7 @@ string slsDetectorCommand::cmdRateCorr(int narg, char *args[], int action){ if (myDet->getRateCorrection(t)) { sprintf(answer,"%0.9f",t); } else { - sprintf(answer,"%f",0.); + sprintf(answer,"%0.9f",0.); } return string(answer); } @@ -3915,7 +4340,7 @@ string slsDetectorCommand::cmdDetectorSize(int narg, char *args[], int action) { if (cmd=="roimask") sprintf(ans,"0x%x",ret); else - sprintf(ans,"0x%d",ret); + sprintf(ans,"%d",ret); return string(ans); @@ -4439,7 +4864,7 @@ string slsDetectorCommand::cmdDAC(int narg, char *args[], int action) { int idac=-1; if (sscanf(args[0],"dac:%d",&idac)==1) { - printf("chiptestboard!\n"); + //printf("chiptestboard!\n"); dac=(dacIndex)idac; } else if (cmd=="adcvpp") @@ -4794,7 +5219,7 @@ string slsDetectorCommand::cmdADC(int narg, char *args[], int action) { sprintf(answer,"%f",myDet->getADC(adc)); #endif //if ((adc == TEMPERATURE_ADC) || (adc == TEMPERATURE_FPGA)) - if (adc<1000) + if (adc<=100) strcat(answer,"°C"); else strcat(answer,"mV"); @@ -4913,9 +5338,6 @@ string slsDetectorCommand::cmdTimer(int narg, char *args[], int action) { myDet->setReceiverOnline(ONLINE_FLAG); ret=myDet->setTimer(index,t); - if ((ret!=-1) && (index==ACQUISITION_TIME || index==SUBFRAME_ACQUISITION_TIME || index==FRAME_PERIOD || index==DELAY_AFTER_TRIGGER)) - rval=(double)ret*1E-9; - else rval=ret; // cout << "here!"<< endl; //set frame index @@ -4926,10 +5348,13 @@ string slsDetectorCommand::cmdTimer(int narg, char *args[], int action) { myDet->setFrameIndex(-1); } - if (index==FRAME_NUMBER || index==GATES_NUMBER || index==PROBES_NUMBER || index==CYCLES_NUMBER || index==MEASUREMENTS_NUMBER) - sprintf(answer,"%d",(int)rval); - else + if ((ret!=-1) && (index==ACQUISITION_TIME || index==SUBFRAME_ACQUISITION_TIME || index==FRAME_PERIOD || index==DELAY_AFTER_TRIGGER)) { + rval=(double)ret*1E-9; sprintf(answer,"%0.9f",rval); + } + else + sprintf(answer,"%lld",(long long int)ret); + return string(answer); @@ -5420,7 +5845,7 @@ string slsDetectorCommand::helpConfiguration(int narg, char *args[], int action) } if (action==GET_ACTION || action==HELP_ACTION) { - + os << "rx_printconfig \t prints the receiver configuration" << std::endl; os << "config fname \t saves the detector to the configuration to fname" << std::endl; os << "parameters fname \t saves the detector parameters to fname" << std::endl; os << "setup fname \t saves the detector complete detector setup to fname (extensions automatically generated), including trimfiles, ff coefficients etc." << std::endl; @@ -5454,7 +5879,7 @@ string slsDetectorCommand::cmdReceiver(int narg, char *args[], int action) { if (action==PUT_ACTION) { if(!strcasecmp(args[1],"start")) { //to ensure data streaming enable is the same across client and receiver - if (receivers == ONLINE_FLAG) { + if ((!myDet->getExternalGuiFlag()) && (receivers == ONLINE_FLAG)) { //if it was not off if (myDet->enableDataStreamingFromReceiver(-1) != 0){ //switch it off, if error @@ -5462,7 +5887,7 @@ string slsDetectorCommand::cmdReceiver(int narg, char *args[], int action) { return string("could not disable data streaming in receiver\n"); } } - } + } myDet->startReceiver(); } else if(!strcasecmp(args[1],"stop")){ @@ -6222,7 +6647,7 @@ string slsDetectorCommand::cmdPulse(int narg, char *args[], int action) { if(retval == OK) return string(" successful"); else - return string(" failed"); + return string(" unsuccessful"); } diff --git a/slsDetectorSoftware/slsDetector/slsDetectorUsers.h b/slsDetectorSoftware/slsDetector/slsDetectorUsers.h index 7c7ed1a18..a38471f76 100644 --- a/slsDetectorSoftware/slsDetector/slsDetectorUsers.h +++ b/slsDetectorSoftware/slsDetector/slsDetectorUsers.h @@ -60,14 +60,15 @@ detectorData is a structure containing the data and additional information which You can find examples of how this classes can be instatiated in mainClient.cpp and mainReceiver.cpp - \authors Anna Bergamaschi, Dhanya Maliakal - @version 0.2 + \authors Anna Bergamaschi, Dhanya Thattil + @version 3.0

Currently supported detectors

\li MYTHEN \li GOTTHARD controls \li GOTTHARD data receiver -

Coming soon

-\li EIGER +\li EIGER +\li JUNGFRAU + */ diff --git a/slsDetectorSoftware/slsDetector/slsDetectorUtils.h b/slsDetectorSoftware/slsDetector/slsDetectorUtils.h index 655c77d78..0eb80899d 100644 --- a/slsDetectorSoftware/slsDetector/slsDetectorUtils.h +++ b/slsDetectorSoftware/slsDetector/slsDetectorUtils.h @@ -846,6 +846,19 @@ virtual int setReceiverFifoDepth(int i = -1)=0; */ virtual bool getAcquiringFlag() = 0; + /** + Set external gui flag in shared memory + \param b set external gui flag + */ + virtual void setExternalGuiFlag(bool b=false) = 0; + + /** + Get external gui flag from shared memory + \returns external gui flag + */ + virtual bool getExternalGuiFlag() = 0; + + diff --git a/slsDetectorSoftware/slsDetectorAnalysis/detectorData.h b/slsDetectorSoftware/slsDetectorAnalysis/detectorData.h index 888993fa0..f0d238b4e 100644 --- a/slsDetectorSoftware/slsDetectorAnalysis/detectorData.h +++ b/slsDetectorSoftware/slsDetectorAnalysis/detectorData.h @@ -16,15 +16,16 @@ class detectorData { \param fname file name to which the data are saved \param np number of points in x coordinate defaults to the number of detector channels (1D detector) \param ny dimension in y (1D detector) + \param gval pointer to gain data (for jungfrau) */ - detectorData(double *val=NULL, double *err=NULL, double *ang=NULL, double p_ind=-1, const char *fname="", int np=-1, int ny=1) : values(val), errors(err), angles(ang), progressIndex(p_ind), npoints(np), npy(ny){ + detectorData(double *val=NULL, double *err=NULL, double *ang=NULL, double p_ind=-1, const char *fname="", int np=-1, int ny=1, double* gval=NULL) : values(val), errors(err), angles(ang), progressIndex(p_ind), npoints(np), npy(ny), gvalues(gval){ strcpy(fileName,fname); }; /** @short The destructor deletes also the arrays pointing to data/errors/angles if not NULL */ - ~detectorData() {if (values) delete [] values; if (errors) delete [] errors; if (angles) delete [] angles;}; + ~detectorData() {if (values) delete [] values; if (errors) delete [] errors; if (angles) delete [] angles; if (gvalues) delete [] gvalues;}; //private: double *values; /**< @short pointer to the data */ double *errors; /**< @short pointer to the errors */ @@ -33,6 +34,7 @@ class detectorData { char fileName[1000];/**< @short file name */ int npoints;/**< @short number of points */ int npy;/**< @short dimensions in y coordinate*/ + double *gvalues; /**< @short pointer to the gain data */ }; diff --git a/slsDetectorSoftware/slsDetectorClient.doxy b/slsDetectorSoftware/slsDetectorClient.doxy deleted file mode 100644 index c63f84d40..000000000 --- a/slsDetectorSoftware/slsDetectorClient.doxy +++ /dev/null @@ -1,86 +0,0 @@ -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = YES - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = NO - - - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = YES - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = YES - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base -# name of the file that contains the anonymous namespace. By default -# anonymous namespace are hidden. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = NO - -INTERNAL_DOCS = NO - -SHOW_INCLUDE_FILES = NO - -SHOW_FILES = NO - -SHOW_NAMESPACES = NO - -COMPACT_LATEX = YES - -PAPER_TYPE = a4 - -PDF_HYPERLINKS = YES - -USE_PDFLATEX = YES - -LATEX_HIDE_INDICES = YES - - -PREDEFINED = __cplusplus - -INPUT = slsDetector/slsDetectorCommand.cpp - -OUTPUT_DIRECTORY = slsDetectorClientDocs diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/acquisition.html b/slsDetectorSoftware/slsDetectorClientDocs/html/acquisition.html deleted file mode 100644 index a96418f67..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/acquisition.html +++ /dev/null @@ -1,85 +0,0 @@ - - - - - -Acquition commands - - - - - - - - - -
- - -

Acquition commands

Commands to control the acquisition

-
    -
  • acquire blocking acquisition (like calling sls_detector_acquire). Starts receiver and detector, writes and processes the data, stops detector. Only get!
  • -
-
    -
  • data gets all data from the detector (if any) processes them and writes them to file according to the preferences already setup (MYTHEN only). Only get!
  • -
-
    -
  • frame gets a single frame from the detector (if any) processes it and writes it to file according to the preferences already setup (MYTHEN only). Only get!
  • -
-
    -
  • status returns the detector status (string)- can be: running, error, transmitting, finished, waiting or idle; put can be start or stop
  • -
-
    -
  • busy returns 1 if the acquisition is active, 0 otherwise. Works when the acquisition is started in non-blocking mode. Only get!
  • -
-
    -
  • readctr Reads the counters from the detector memory (analog detector returning values translated into number of photons - only GOTTHARD). Cannot put.
  • -
-
    -
  • resetctr i Resets counter in detector, restarts acquisition if i=1(analog detector returning values translated into number of photons - only GOTTHARD). Cannot put.
  • -
-
    -
  • resmat i sets/resets counter bit in detector.gets the counter bit in detector ????
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/actions.html b/slsDetectorSoftware/slsDetectorClientDocs/html/actions.html deleted file mode 100644 index 2beec987a..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/actions.html +++ /dev/null @@ -1,136 +0,0 @@ - - - - - -Actions - - - - - - - - - -
- - -

Actions

Commands to define scripts to be executed during the acquisition flow

-
    -
  • positions [n [p0..pn-1]] sets/gets number of angular position and positions to be acquired.
  • -
-
    -
  • startscript [s] sets/gets the script to be executed at the beginning of the acquisition. none unsets.
  • -
-
    -
  • startscriptpar [s] sets/gets a string to be passed as a parameter to the startscript
  • -
-
    -
  • stopscript [s] sets/gets the script to be executed at the end of the acquisition. none unsets.
  • -
-
    -
  • stopscriptpar [s] sets/gets a string to be passed as a parameter to the stopscript
  • -
-
    -
  • scriptbefore [s] sets/gets the script to be executed before starting the detector every time in the acquisition. none unsets.
  • -
-
    -
  • scriptbeforepar [s] sets/gets a string to be passed as a parameter to the scriptbefore
  • -
-
    -
  • scriptafter [s] sets/gets the script to be executed after the detector has finished every time in the acquisition. none unsets.
  • -
-
    -
  • scriptafterpar [s] sets/gets a string to be passed as a parameter to the scriptafter
  • -
-
    -
  • headerafter [s] sets/gets the script to be executed for logging the detector parameters. none unsets.
  • -
-
    -
  • headerbefore [s] sets/gets the script to be executed for logging the detector parameters. none unsets.
  • -
-
    -
  • headerbeforepar [s] sets/gets a string to be passed as a parameter to the headerbefore script
  • -
-
    -
  • headerafterpar [s] sets/gets a string to be passed as a parameter to the headerafter script
  • -
-
    -
  • enacallog [i] enables/disables logging of the parameters necessary for the energy calibration. 1 sets, 0 unsets.
  • -
-
    -
  • angcallog [i] enables/disables logging of the parameters necessary for the angular calibration. 1 sets, 0 unsets.
  • -
-
    -
  • scan0script [s] sets/gets the script to be executed for the scan 0 level. none unsets.
  • -
-
    -
  • scan0par [s] sets/gets a string to be passed as a parameter to the scan0script
  • -
-
    -
  • scan0prec [i] sets/gets number of digits to be used for the scan0 variable in the file name.
  • -
-
    -
  • scan0steps [i [s0..sn-1]] sets/gets number of steps (int) of the scan0 level and their values (float).
  • -
-
    -
  • scan0range [smin smax sstep] sets scan0 min, max and step, returns the number of steps and their values as scan0steps.
  • -
-
    -
  • scan1script [s] sets/gets the script to be executed for the scan1 level. none unsets.
  • -
-
    -
  • scan1par [s] sets/gets a string to be passed as a parameter to the scan1script
  • -
-
    -
  • scan1prec [i] sets/gets number of digits to be used for the scan1 variable in the file name.
  • -
-
    -
  • scan1steps [i [s0..sn-1]] sets/gets number of steps (int) of the scan1 level and their values (float).
  • -
-
    -
  • scan1range [smin smax sstep] sets scan1 min, max and step, returns the number of steps and their values as scan1steps.
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/advanced.html b/slsDetectorSoftware/slsDetectorClientDocs/html/advanced.html deleted file mode 100644 index b24667eb2..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/advanced.html +++ /dev/null @@ -1,61 +0,0 @@ - - - - - -Advanced Usage - - - - - - - - - -
- - -

Advanced Usage

This page is for advanced users. Make sure you have first read the introduction.

-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/config.html b/slsDetectorSoftware/slsDetectorClientDocs/html/config.html deleted file mode 100644 index f56fa32ce..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/config.html +++ /dev/null @@ -1,215 +0,0 @@ - - - - - -Configuration commands - - - - - - - - - -
- - -

Configuration commands

Commands to configure the detector. these commands are often left to the configuration file.

-
    -
  • datastream enables/disables the 0MQ data stream (0MQ threads created) from receiver to client.
  • -
-
    -
  • free Free shared memory on the control PC
  • -
-
    -
  • add Adds a detector at the end of the multi-detector structure. put argument is the hostname or IP adress. Returns the chained list of detector hostnames.
  • -
-
    -
  • remove i Removes controller i from the multi-detector structure. Can be used for partial readout of the detector.
  • -
-
    -
  • type Sets/gets detector type (string).
  • -
-
    -
  • hostname put adds the hostname (ot IP adress) at the end of the multi-detector structure. If used for a single controlled (i:) replaces the current hostname. Returns the list of the hostnames of the multi-detector structure.
  • -
-
    -
  • id[:i] Returns the id of the detector structure. i is the detector position in a multi detector system. If used a put, configures the id of the detector structure. i is the detector position in a multi detector system and l is the id of the detector to be added.
  • -
-
    -
  • master i put sets the position of the master of the acquisition (-1 if none). Returns the position of the master of the detector structure (-1 if none).
  • -
-
    -
  • sync Sets/gets the synchronization mode of the detectors in the multi-detector structure. Can be: none, gating, trigger, complementary. Mainly used by MYTHEN/GOTTHARD.
  • -
-
    -
  • online [i] sets the detector in online (1) or offline (0) mode
  • -
-
    -
  • checkonline returns the hostnames of all detectors without connecting to them
  • -
-
    -
  • activate Activates/Deactivates the detector. Deactivated detector does not send data. Used for EIGER only.
  • -
-
    -
  • lock [i] Locks/Unlocks the detector to communicate with this client. 1 locks, 0 unlocks.
  • -
-
    -
  • nmod [i] sets/gets the number of modules of the detector. Used for MYTHEN only.
  • -
-
    -
  • maxmod Gets the maximum number of modules of the detector. Used for MYTHEN only. Cannot put!
  • -
-
    -
  • dr [i] sets/gets the dynamic range of detector. Mythen [4,8,16,24]. Eiger [4,8,16,32]. Others cannot put!
  • -
-
    -
  • roi [i] [xmin] [xmax] [ymin] [ymax] sets region of interest of the detector, where i is number of rois;i=0 to clear rois. Used for GOTTHARD only.
  • -
-
    -
  • detsizechan [xmax] [ymax] sets the maximum number of channels in each dimension for complete detector set; -1 is no limit. Use for multi-detector system as first command in config file.
  • -
-
    -
  • roimask [i] ??
  • -
-
    -
  • flippeddatax [i] enables/disables data being flipped across x axis. 1 enables, 0 disables. Used for EIGER only. 1 for bottom half-module, 0 for top-half module.
  • -
-
    -
  • flags [flag] sets/gets the readout flags to mode. Options: none, storeinram, tot, continous, parallel, nonparallel, safe, digital, analog_digital, unknown. Used for MYTHEN and EIGER only.
  • -
-
    -
  • extsig:[i] [flag] sets/gets the mode of the external signal i. Options: off, gate_in_active_high, gate_in_active_low, trigger_in_rising_edge, trigger_in_falling_edge, ro_trigger_in_rising_edge, ro_trigger_in_falling_edge, gate_out_active_high, gate_out_active_low, trigger_out_rising_edge, trigger_out_falling_edge, ro_trigger_out_rising_edge, ro_trigger_out_falling_edge.
    - Used in MYTHEN, GOTTHARD, PROPIX only.
  • -
-
    -
  • programfpga [file] programs the FPGA with file f (with .pof extension). Used for JUNGFRAU, MOENCH only. Only put!
  • -
-
    -
  • resetfpga [f] resets FPGA, where f can be any value. Used for JUNGFRAU only. Only put!
  • -
-
    -
  • powerchip [i] Powers on/off the chip. 1 powers on, 0 powers off. Can also get the power status. Used for JUNGFRAU only.
  • -
-
    -
  • led [i] sets/gets the led status. 1 on, 0 off. Used for MOENCH only ??
  • -
-
    -
  • moduleversion:[i] Gets the firmware version of module i. Used for MYTHEN only. Only get!
  • -
-
    -
  • detectornumber Gets the serial number or MAC of detector. Only get!
  • -
-
    -
  • modulenumber:[i] Gets the serial number of module i. Used for MYTHEN only. Only get!
  • -
-
    -
  • detectorversion Gets the firmware version of detector. Only get!
  • -
-
    -
  • softwareversion Gets the software version of detector server. Only get!
  • -
-
    -
  • thisversion Gets the software version of this client software. Only get!
  • -
-
    -
  • receiverversion Gets the software version of receiver. Only get!
  • -
-
    -
  • timing [mode] sets/gets synchronization mode of the detector. Mode: auto, trigger, ro_trigger, gating, triggered_gating
  • -
-
    -
  • exptime [i] sets/gets exposure time in s
  • -
-
    -
  • subexptime [i] sets/gets sub exposure time in s. Used in EIGER only in 32 bit mode.
  • -
-
    -
  • period [i] sets/gets frame period in s.
  • -
-
    -
  • delay [i] sets/gets delay in s. Used in MYTHEN, GOTTHARD only
  • -
-
    -
  • gates [i] sets/gets number of gates. Used in MYTHEN, GOTTHARD, EIGER only
  • -
-
    -
  • gates [i] sets/gets number of frames. If timing is not auto, then it is the number of frames per cycle/trigger.
  • -
-
    -
  • cycles [i] sets/gets number of triggers. Timing mode should be set appropriately.
  • -
-
    -
  • probes [i] sets/gets number of probes to accumulate. When setting, max 3! cycles should be set to 1, frames to the number of pump-probe events. Used in MYTHEN only
  • -
-
    -
  • measurements [i] sets/gets number of measurements.
  • -
-
    -
  • samples [i] sets/gets number of samples expected from the jctb. Used in CHIP TEST BOARD only.
  • -
-
    -
  • exptimel [i] gets exposure time left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • periodl [i] gets frame period left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • delayl [i] gets delay left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • gatesl [i] gets number of gates left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • framesl [i] gets number of frames left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • cyclesl [i] gets number of cylces left. Used in MYTHEN, GOTTHARD only.
  • -
-
    -
  • probesl [i] gets number of probes left. Used in MYTHEN, GOTTHARD only.
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/data.html b/slsDetectorSoftware/slsDetectorClientDocs/html/data.html deleted file mode 100644 index ce4399606..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/data.html +++ /dev/null @@ -1,106 +0,0 @@ - - - - - -Data processing commands - - - - - - - - - -
- - -

Data processing commands

Commands to setup the data processing (mainly MYTHEN related)

-
    -
  • flatfield [fn] put sets flatfield file to fn (relative to ffdir). returns the flatfield file name relative to ffdir (string). If
  • -
-
    -
  • ffdir [d] Sets/gets the directory in which the flat field file is located.
  • -
-
    -
  • ratecorr [ns] Returns the dead time used for rate correections in ns (int). put sets the deadtime correction constant in ns, -1 will set it to default tau of settings (0 unset).
  • -
-
    -
  • badchannels [fn] put sets the badchannels file to fn . returns the bad channels file name. If
  • -
-
    -
  • angconv [fn] put sets the angular conversion file to fn . returns the angular conversion file name. If
  • -
-
    -
  • globaloff [f] Sets/gets the beamline angular global offset (float).
  • -
-
    -
  • fineoff [f] Sets/gets the angular fine offset of the measurement (float).
  • -
-
    -
  • binsize [f] Sets/gets the bin size used for the angular conversion (float).
  • -
-
    -
  • angdir [i] Sets/gets the angular direction. 1 means increasing channels number as increasing angle, -1 increasing channel number decreasing angle.
  • -
-
    -
  • moveflag [i] Sets/gets the flag for physically moving the detector during the acquisition of several positions. 1 sets (moves), 0 unsets.
  • -
-
    -
  • samplex [f] Sets/gets the sample displacement in th direction parallel to the beam in um. Unused!
  • -
-
    -
  • sampley [f] Sets/gets the sample displacement in th direction orthogonal to the beam in um. Unused!
  • -
-
    -
  • threaded [i] Sets/gets the data processing threaded flag. 1 is threaded, 0 unthreaded.
  • -
-
    -
  • darkimage fn Loads the dark image to the detector from file fn (pedestal image). Cannot get.
  • -
-
    -
  • gainimage fn Loads the gain image to the detector from file fn (gain map for translation into number of photons of an analog detector). Cannot get.
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.css b/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.css deleted file mode 100644 index 9ca3cafbc..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.css +++ /dev/null @@ -1,498 +0,0 @@ -/* The standard CSS for doxygen */ - -body, table, div, p, dl { - font-family: Lucida Grande, Verdana, Geneva, Arial, sans-serif; - font-size: 12px; -} - -/* @group Heading Levels */ - -h1 { - text-align: center; - font-size: 150%; -} - -h2 { - font-size: 120%; -} - -h3 { - font-size: 100%; -} - -dt { - font-weight: bold; -} - -div.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; -} - -p.startli, p.startdd { - margin-top: 2px; -} - -p.endli { - margin-bottom: 0px; -} - -p.enddd { - margin-bottom: 4px; -} - -/* @end */ - -caption { - font-weight: bold; -} - -span.legend { - font-size: 70%; - text-align: center; -} - -div.qindex, div.navtab{ - background-color: #e8eef2; - border: 1px solid #84b0c7; - text-align: center; - margin: 2px; - padding: 2px; -} - -div.qindex, div.navpath { - width: 100%; - line-height: 140%; -} - -div.navtab { - margin-right: 15px; -} - -/* @group Link Styling */ - -a { - color: #153788; - font-weight: normal; - text-decoration: none; -} - -.contents a:visited { - color: #1b77c5; -} - -a:hover { - text-decoration: underline; -} - -a.qindex { - font-weight: bold; -} - -a.qindexHL { - font-weight: bold; - background-color: #6666cc; - color: #ffffff; - border: 1px double #9295C2; -} - -.contents a.qindexHL:visited { - color: #ffffff; -} - -a.el { - font-weight: bold; -} - -a.elRef { -} - -a.code { -} - -a.codeRef { -} - -/* @end */ - -dl.el { - margin-left: -1cm; -} - -.fragment { - font-family: monospace, fixed; - font-size: 105%; -} - -pre.fragment { - border: 1px solid #CCCCCC; - background-color: #f5f5f5; - padding: 4px 6px; - margin: 4px 8px 4px 2px; -} - -div.ah { - background-color: black; - font-weight: bold; - color: #ffffff; - margin-bottom: 3px; - margin-top: 3px -} - -div.groupHeader { - margin-left: 16px; - margin-top: 12px; - margin-bottom: 6px; - font-weight: bold; -} - -div.groupText { - margin-left: 16px; - font-style: italic; -} - -body { - background: white; - color: black; - margin-right: 20px; - margin-left: 20px; -} - -td.indexkey { - background-color: #e8eef2; - font-weight: bold; - border: 1px solid #CCCCCC; - margin: 2px 0px 2px 0; - padding: 2px 10px; -} - -td.indexvalue { - background-color: #e8eef2; - border: 1px solid #CCCCCC; - padding: 2px 10px; - margin: 2px 0px; -} - -tr.memlist { - background-color: #f0f0f0; -} - -p.formulaDsp { - text-align: center; -} - -img.formulaDsp { - -} - -img.formulaInl { - vertical-align: middle; -} - -div.center { - text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; -} - -div.center img { - border: 0px; -} - -img.footer { - border: 0px; - vertical-align: middle; -} - -/* @group Code Colorization */ - -span.keyword { - color: #008000 -} - -span.keywordtype { - color: #604020 -} - -span.keywordflow { - color: #e08000 -} - -span.comment { - color: #800000 -} - -span.preprocessor { - color: #806020 -} - -span.stringliteral { - color: #002080 -} - -span.charliteral { - color: #008080 -} - -span.vhdldigit { - color: #ff00ff -} - -span.vhdlchar { - color: #000000 -} - -span.vhdlkeyword { - color: #700070 -} - -span.vhdllogic { - color: #ff0000 -} - -/* @end */ - -.search { - color: #003399; - font-weight: bold; -} - -form.search { - margin-bottom: 0px; - margin-top: 0px; -} - -input.search { - font-size: 75%; - color: #000080; - font-weight: normal; - background-color: #e8eef2; -} - -td.tiny { - font-size: 75%; -} - -.dirtab { - padding: 4px; - border-collapse: collapse; - border: 1px solid #84b0c7; -} - -th.dirtab { - background: #e8eef2; - font-weight: bold; -} - -hr { - height: 0; - border: none; - border-top: 1px solid #666; -} - -/* @group Member Descriptions */ - -.mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { - background-color: #FAFAFA; - border: none; - margin: 4px; - padding: 1px 0 0 8px; -} - -.mdescLeft, .mdescRight { - padding: 0px 8px 4px 8px; - color: #555; -} - -.memItemLeft, .memItemRight, .memTemplParams { - border-top: 1px solid #ccc; -} - -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; -} - -.memTemplParams { - color: #606060; - white-space: nowrap; -} - -/* @end */ - -/* @group Member Details */ - -/* Styles for detailed member documentation */ - -.memtemplate { - font-size: 80%; - color: #606060; - font-weight: normal; - margin-left: 3px; -} - -.memnav { - background-color: #e8eef2; - border: 1px solid #84b0c7; - text-align: center; - margin: 2px; - margin-right: 15px; - padding: 2px; -} - -.memitem { - padding: 0; - margin-bottom: 10px; -} - -.memname { - white-space: nowrap; - font-weight: bold; -} - -.memproto, .memdoc { - border: 1px solid #84b0c7; -} - -.memproto { - padding: 0; - background-color: #d5e1e8; - font-weight: bold; - -webkit-border-top-left-radius: 8px; - -webkit-border-top-right-radius: 8px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -moz-border-radius-topleft: 8px; - -moz-border-radius-topright: 8px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - -} - -.memdoc { - padding: 2px 5px; - background-color: #eef3f5; - border-top-width: 0; - -webkit-border-bottom-left-radius: 8px; - -webkit-border-bottom-right-radius: 8px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -moz-border-radius-bottomleft: 8px; - -moz-border-radius-bottomright: 8px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; -} - -.paramkey { - text-align: right; -} - -.paramtype { - white-space: nowrap; -} - -.paramname { - color: #602020; - white-space: nowrap; -} -.paramname em { - font-style: normal; -} - -/* @end */ - -/* @group Directory (tree) */ - -/* for the tree view */ - -.ftvtree { - font-family: sans-serif; - margin: 0.5em; -} - -/* these are for tree view when used as main index */ - -.directory { - font-size: 9pt; - font-weight: bold; -} - -.directory h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -/* -The following two styles can be used to replace the root node title -with an image of your choice. Simply uncomment the next two styles, -specify the name of your image and be sure to set 'height' to the -proper pixel height of your image. -*/ - -/* -.directory h3.swap { - height: 61px; - background-repeat: no-repeat; - background-image: url("yourimage.gif"); -} -.directory h3.swap span { - display: none; -} -*/ - -.directory > h3 { - margin-top: 0; -} - -.directory p { - margin: 0px; - white-space: nowrap; -} - -.directory div { - display: none; - margin: 0px; -} - -.directory img { - vertical-align: -30%; -} - -/* these are for tree view when not used as main index */ - -.directory-alt { - font-size: 100%; - font-weight: bold; -} - -.directory-alt h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -.directory-alt > h3 { - margin-top: 0; -} - -.directory-alt p { - margin: 0px; - white-space: nowrap; -} - -.directory-alt div { - display: none; - margin: 0px; -} - -.directory-alt img { - vertical-align: -30%; -} - -/* @end */ - -address { - font-style: normal; - color: #333; -} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.png b/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.png deleted file mode 100644 index f0a274bba..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/doxygen.png and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/index.html b/slsDetectorSoftware/slsDetectorClientDocs/html/index.html deleted file mode 100644 index 121676d5d..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/index.html +++ /dev/null @@ -1,88 +0,0 @@ - - - - - -Introduction - - - - - - - - - -
-

Introduction

This program is intended to control the SLS detectors via command line interface. This is the only way to access all possible functionality of the detectors, however it is often recommendable to avoid changing the most advanced settings, rather leaving the task to configuration files, as when using the GUI or the API provided.

-

The command line interface consists in four main functions:

-
    -
  • sls_detector_acquire to acquire data from the detector
  • -
  • sls_detector_put to set detector parameters
  • -
  • sls_detector_get to retrieve detector parameters
  • -
  • sls_detector_help to get help concerning the text commands Additionally the program slsReceiver should be started on the machine expected to receive the data from the detector.
  • -
-

If you need control a single detector, the use of the command line interface does not need any additional arguments.

-

For commands addressing a single controller of your detector, the command cmd should be called with the index i of the controller:

-

sls_detector_clnt i:cmd

-

where sls_detector_clnt is the text client (put, get, acquire, help).

-

In case more than one detector is configured on the control PC, the command cmd should be called with their respective index j:

-

sls_detector_clnt j-cmd

-

where sls_detector_clnt is the text client (put, get, acquire, help).

-

To address a specific controller i of detector j use:

-

sls_detector_clnt j-i:cmd

-

For additional questions concerning the indexing of the detector, please refer to the SLS Detectors FAQ documentation.

-

The commands are sudivided into different pages depending on their functionalities:

-
    -
  • Acquition commands Acquisition: commands to start/stop the acquisition and retrieve data
  • -
  • Configuration commands Configuration: commands to configure the detector
  • -
  • Data postprocessing: commands to process the data - mainly for MYTHEN except for rate corrections.
  • -
  • Settings: commands to define detector settings/threshold.
  • -
  • Output: commands to define output file destination and format
  • -
  • Actions: commands to define scripts to be executed during the acquisition flow
  • -
  • Network: commands to setup the network between client, detector and receiver
  • -
  • Receiver: commands to configure the receiver
  • -
  • Developer Developer: commands to be used only for software debugging. Avoid using them!
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/installdox b/slsDetectorSoftware/slsDetectorClientDocs/html/installdox deleted file mode 100755 index 9b89fe025..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/installdox +++ /dev/null @@ -1,117 +0,0 @@ -#!/usr/bin/perl - -%subst = ( ); -$quiet = 0; - -if (open(F,"search.cfg")) -{ - $_= ; s/[ \t\n]*$//g ; $subst{"_doc"} = $_; - $_= ; s/[ \t\n]*$//g ; $subst{"_cgi"} = $_; -} - -while ( @ARGV ) { - $_ = shift @ARGV; - if ( s/^-// ) { - if ( /^l(.*)/ ) { - $v = ($1 eq "") ? shift @ARGV : $1; - ($v =~ /\/$/) || ($v .= "/"); - $_ = $v; - if ( /(.+)\@(.+)/ ) { - if ( exists $subst{$1} ) { - $subst{$1} = $2; - } else { - print STDERR "Unknown tag file $1 given with option -l\n"; - &usage(); - } - } else { - print STDERR "Argument $_ is invalid for option -l\n"; - &usage(); - } - } - elsif ( /^q/ ) { - $quiet = 1; - } - elsif ( /^\?|^h/ ) { - &usage(); - } - else { - print STDERR "Illegal option -$_\n"; - &usage(); - } - } - else { - push (@files, $_ ); - } -} - -foreach $sub (keys %subst) -{ - if ( $subst{$sub} eq "" ) - { - print STDERR "No substitute given for tag file `$sub'\n"; - &usage(); - } - elsif ( ! $quiet && $sub ne "_doc" && $sub ne "_cgi" ) - { - print "Substituting $subst{$sub} for each occurence of tag file $sub\n"; - } -} - -if ( ! @files ) { - if (opendir(D,".")) { - foreach $file ( readdir(D) ) { - $match = ".html"; - next if ( $file =~ /^\.\.?$/ ); - ($file =~ /$match/) && (push @files, $file); - ($file =~ "tree.js") && (push @files, $file); - } - closedir(D); - } -} - -if ( ! @files ) { - print STDERR "Warning: No input files given and none found!\n"; -} - -foreach $f (@files) -{ - if ( ! $quiet ) { - print "Editing: $f...\n"; - } - $oldf = $f; - $f .= ".bak"; - unless (rename $oldf,$f) { - print STDERR "Error: cannot rename file $oldf\n"; - exit 1; - } - if (open(F,"<$f")) { - unless (open(G,">$oldf")) { - print STDERR "Error: opening file $oldf for writing\n"; - exit 1; - } - if ($oldf ne "tree.js") { - while () { - s/doxygen\=\"([^ \"\:\t\>\<]*)\:([^ \"\t\>\<]*)\" (href|src)=\"\2/doxygen\=\"$1:$subst{$1}\" \3=\"$subst{$1}/g; - print G "$_"; - } - } - else { - while () { - s/\"([^ \"\:\t\>\<]*)\:([^ \"\t\>\<]*)\", \"\2/\"$1:$subst{$1}\" ,\"$subst{$1}/g; - print G "$_"; - } - } - } - else { - print STDERR "Warning file $f does not exist\n"; - } - unlink $f; -} - -sub usage { - print STDERR "Usage: installdox [options] [html-file [html-file ...]]\n"; - print STDERR "Options:\n"; - print STDERR " -l tagfile\@linkName tag file + URL or directory \n"; - print STDERR " -q Quiet mode\n\n"; - exit 1; -} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/network.html b/slsDetectorSoftware/slsDetectorClientDocs/html/network.html deleted file mode 100644 index d562e9976..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/network.html +++ /dev/null @@ -1,112 +0,0 @@ - - - - - -Network - - - - - - - - - -
- - -

Network

Commands to setup the network between client, detector and receiver

-
    -
  • rx_hostname [s] sets/gets the receiver hostname or IP address, configures detector mac with all network parameters and updates receiver with acquisition parameters. Normally used for single detectors (Can be multi-detector). none disables. If used, use as last network command in configuring detector MAC.
  • -
-
    -
  • rx_udpip [ip] sets/gets the ip address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector). Used if different from eth0.
  • -
-
    -
  • rx_udpmac [mac] sets/gets the mac address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-detector).
  • -
-
    -
  • rx_udpport [port] sets/gets the port of the receiver UDP interface where the data from the detector will be streamed to. Use single-detector command.
  • -
-
    -
  • rx_udpport2 [port] sets/gets the second port of the receiver UDP interface where the data from the second half of the detector will be streamed to. Use single-detector command. Used for EIGER only.
  • -
-
    -
  • detectormac [mac] sets/gets the mac address of the detector UDP interface from where the detector will stream data. Use single-detector command. Normally unused.
  • -
-
    -
  • detectorip [ip] sets/gets the ip address of the detector UDP interface from where the detector will stream data. Use single-detector command. Keep in same subnet as rx_udpip (if rx_udpip specified).
  • -
-
    -
  • txndelay_left [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's left UDP port. Use single-detector command. Used for EIGER only.
  • -
-
    -
  • txndelay_right [delay] sets/gets the transmission delay of first packet in an image being streamed out from the detector's right UDP port. Use single-detector command. Used for EIGER only.
  • -
-
    -
  • txndelay_frame [delay] sets/gets the transmission frame period of entire frame being streamed out from the detector for both ports. Use single-detector command. Used for EIGER only.
  • -
-
    -
  • flowcontrol_10g [delay] Enables/disables 10 GbE flow control. 1 enables, 0 disables. Used for EIGER only.
  • -
-
    -
  • zmqport [port] sets/gets the 0MQ (TCP) port of the receiver from where data is streamed to the client. Use single-detector command to set individually or multi-detector command to calculate based on port for the rest.
  • -
-
    -
  • configuremac [i] configures the MAC of the detector with these parameters: detectorip, detectormac, rx_udpip, rx_udpmac, rx_udpport, rx_udpport2 (if applicable). Only put!
  • -
-
    -
  • rx_tcpport [port] sets/gets the port of the client-receiver TCP interface. Use single-detector command. Is different for each detector if same rx_hostname used. Must be first command to communicate with receiver.
  • -
-
    -
  • port [port] sets/gets the port of the client-detector control server TCP interface. Use single-detector command. Default value is 1952 for all detectors. Normally not changed.
  • -
-
    -
  • stopport [port] sets/gets the port of the client-detector stop server TCP interface. Use single-detector command. Default value is 1953 for all detectors. Normally not changed.
  • -
-
    -
  • lastclient Gets the last client communicating with the detector. Cannot put!
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/output.html b/slsDetectorSoftware/slsDetectorClientDocs/html/output.html deleted file mode 100644 index ca4889fa8..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/output.html +++ /dev/null @@ -1,82 +0,0 @@ - - - - - -Output settings - - - - - - - - - -
- - -

Output settings

Commands to setup the file destination and format

-
    -
  • outdir [dir] Sets/gets the file output directory (string)
  • -
-
    -
  • fname [fn] Sets/gets the root of the output file name (string)
  • -
-
    -
  • index [i] Sets/gets the current file index (int)
  • -
-
    -
  • enablefwrite [i] Enables/disables file writing. 1 enables, 0 disables.
  • -
-
    -
  • overwrite [i] enables(1) /disables(0) file overwriting
  • -
-
    -
  • currentfname gets the filename for the data without index and extension
  • -
-
    -
  • fileformat gets the file format for data (no put?) What are the possible return values?
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/pages.html b/slsDetectorSoftware/slsDetectorClientDocs/html/pages.html deleted file mode 100644 index 85eec37c6..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/pages.html +++ /dev/null @@ -1,80 +0,0 @@ - - - - - -Page Index - - - - - - - - - -
-

Related Pages

Here is a list of all related documentation pages: -
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/receiver.html b/slsDetectorSoftware/slsDetectorClientDocs/html/receiver.html deleted file mode 100644 index e250a4b24..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/receiver.html +++ /dev/null @@ -1,61 +0,0 @@ - - - - - -Receiver commands - - - - - - - - - -
- - -

Receiver commands

Commands to configure the receiver

-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/search/close.png b/slsDetectorSoftware/slsDetectorClientDocs/html/search/close.png deleted file mode 100644 index 9342d3dfe..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/search/close.png and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/search/nomatches.html b/slsDetectorSoftware/slsDetectorClientDocs/html/search/nomatches.html deleted file mode 100644 index b1ded27e9..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/search/nomatches.html +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - -
-
No Matches
-
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.css b/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.css deleted file mode 100644 index d263b9724..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.css +++ /dev/null @@ -1,198 +0,0 @@ -/*---------------- Search Box */ - -#MSearchBox { - padding: 0px; - margin: 0px; - border: none; - border: 1px solid #84B0C7; - white-space: nowrap; - -moz-border-radius: 8px; - -webkit-border-top-left-radius: 8px; - -webkit-border-top-right-radius: 8px; - -webkit-border-bottom-left-radius: 8px; - -webkit-border-bottom-right-radius: 8px; -} -#MSearchField { - font: 9pt Arial, Verdana, sans-serif; - color: #999999; - background-color: #FFFFFF; - font-style: normal; - cursor: text; - padding: 1px 1px; - margin: 0px 6px 0px 0px; - border: none; - outline: none; - vertical-align: middle; -} -.MSearchBoxActive #MSearchField { - color: #000000; -} -#MSearchSelect { - float : none; - display : inline; - background : none; - font: 9pt Verdana, sans-serif; - border: none; - margin: 0px 0px 0px 6px; - vertical-align: middle; - padding: 0px 0px; -} - -#MSearchClose { - float : none; - display : none; - background : none; - border: none; - margin: 0px 4px 0px 0px; - padding: 0px 0px; - outline: none; -} - -#MSearchCloseImg { - vertical-align: middle; -} - -.MSearchBoxLeft { - display: block; - text-align: left; - float: left; - margin-left: 6px; -} -.MSearchBoxRight { - display: block; - float: right; - text-align: right; - margin-right: 6px; -} -.MSearchBoxSpacer { - font-size: 0px; - clear: both; -} -.MSearchBoxRow { - font-size: 0px; - clear: both; -} - -/*---------------- Search filter selection */ - -#MSearchSelectWindow { - display: none; - position: absolute; - left: 0; top: 0; - border: 1px solid #A0A0A0; - background-color: #FAFAFA; - z-index: 1; - padding-top: 4px; - padding-bottom: 4px; - -moz-border-radius: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - -webkit-border-bottom-left-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - } -.SelectItem { - font: 8pt Arial, Verdana, sans-serif; - padding-left: 2px; - padding-right: 12px; - border: 0px; -} -span.SelectionMark { - margin-right: 4px; - font-family: monospace; - outline-style: none; - text-decoration: none; -} -a.SelectItem { - display: block; - outline-style: none; - color: #000000; - text-decoration: none; - padding-left: 6px; - padding-right: 12px; -} -a.SelectItem:focus, -a.SelectItem:active { - color: #000000; - outline-style: none; - text-decoration: none; -} -a.SelectItem:hover { - color: #FFFFFF; - background-color: #2A50E4; - outline-style: none; - text-decoration: none; - cursor: pointer; - display: block; -} - -/*---------------- Search results window */ - -iframe#MSearchResults { - width: 60ex; - height: 15em; - } -#MSearchResultsWindow { - display: none; - position: absolute; - left: 0; top: 0; - border: 1px solid #000000; - background-color: #EEF3F5; - } - -/* ----------------------------------- */ - - -#SRIndex { - clear:both; - padding-bottom: 15px; -} - -.SREntry { - font-size: 10pt; - padding-left: 1ex; -} -.SRPage .SREntry { - font-size: 8pt; - padding: 1px 5px; -} -body.SRPage { - margin: 5px 2px; -} - -.SRChildren { - padding-left: 3ex; padding-bottom: .5em -} -.SRPage .SRChildren { - display: none; -} -.SRSymbol { - font-weight: bold; color: #153788; - font-family: Arial, Verdana, sans-serif; - text-decoration: none; - outline: none; -} - -a.SRScope { - display: block; - color: #153788; - font-family: Arial, Verdana, sans-serif; - text-decoration: none; - outline: none; -} - -a.SRSymbol:focus, a.SRSymbol:active, -a.SRScope:focus, a.SRScope:active { - text-decoration: underline; -} - -.SRPage .SRStatus { - padding: 2px 5px; - font-size: 8pt; - font-style: italic; -} - -.SRResult { - display: none; -} - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.js b/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.js deleted file mode 100644 index 474cc1a80..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.js +++ /dev/null @@ -1,724 +0,0 @@ -// Search script generated by doxygen -// Copyright (C) 2009 by Dimitri van Heesch. - -// The code in this file is loosly based on main.js, part of Natural Docs, -// which is Copyright (C) 2003-2008 Greg Valure -// Natural Docs is licensed under the GPL. - -var indexSectionsWithContent = -{ -}; - -var indexSectionNames = -{ -}; - -function convertToId(search) -{ - var result = ''; - for (i=0;i do a search - { - this.Search(); - } - } - - this.OnSearchSelectKey = function(evt) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==40 && this.searchIndex0) // Up - { - this.searchIndex--; - this.OnSelectItem(this.searchIndex); - } - else if (e.keyCode==13 || e.keyCode==27) - { - this.OnSelectItem(this.searchIndex); - this.CloseSelectionWindow(); - this.DOMSearchField().focus(); - } - return false; - } - - // --------- Actions - - // Closes the results window. - this.CloseResultsWindow = function() - { - this.DOMPopupSearchResultsWindow().style.display = 'none'; - this.DOMSearchClose().style.display = 'none'; - this.Activate(false); - } - - this.CloseSelectionWindow = function() - { - this.DOMSearchSelectWindow().style.display = 'none'; - } - - // Performs a search. - this.Search = function() - { - this.keyTimeout = 0; - - // strip leading whitespace - var searchValue = this.DOMSearchField().value.replace(/^ +/, ""); - - var code = searchValue.toLowerCase().charCodeAt(0); - var hexCode; - if (code<16) - { - hexCode="0"+code.toString(16); - } - else - { - hexCode=code.toString(16); - } - - var resultsPage; - var resultsPageWithSearch; - var hasResultsPage; - - if (indexSectionsWithContent[this.searchIndex].charAt(code-32) == '1') - { - resultsPage = this.resultsPath + '/' + indexSectionNames[this.searchIndex] + '_' + hexCode + '.html'; - resultsPageWithSearch = resultsPage+'?'+escape(searchValue); - hasResultsPage = true; - } - else // nothing available for this search term - { - resultsPage = this.resultsPath + '/nomatches.html'; - resultsPageWithSearch = resultsPage; - hasResultsPage = false; - } - - window.frames.MSearchResults.location.href = resultsPageWithSearch; - var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow(); - - if (domPopupSearchResultsWindow.style.display!='block') - { - var domSearchBox = this.DOMSearchBox(); - this.DOMSearchClose().style.display = 'inline'; - if (this.insideFrame) - { - var domPopupSearchResults = this.DOMPopupSearchResults(); - domPopupSearchResultsWindow.style.position = 'relative'; - domPopupSearchResultsWindow.style.display = 'block'; - var width = document.body.clientWidth - 8; // the -8 is for IE :-( - domPopupSearchResultsWindow.style.width = width + 'px'; - domPopupSearchResults.style.width = width + 'px'; - } - else - { - var domPopupSearchResults = this.DOMPopupSearchResults(); - var left = getXPos(domSearchBox) + domSearchBox.offsetWidth; - var top = getYPos(domSearchBox) + domSearchBox.offsetHeight + 1; - domPopupSearchResultsWindow.style.display = 'block'; - left -= domPopupSearchResults.offsetWidth; - domPopupSearchResultsWindow.style.top = top + 'px'; - domPopupSearchResultsWindow.style.left = left + 'px'; - } - } - - this.lastSearchValue = searchValue; - this.lastResultsPage = resultsPage; - } - - // -------- Activation Functions - - // Activates or deactivates the search panel, resetting things to - // their default values if necessary. - this.Activate = function(isActive) - { - if (isActive || // open it - this.DOMPopupSearchResultsWindow().style.display == 'block' - ) - { - this.DOMSearchBox().className = 'MSearchBoxActive'; - - var searchField = this.DOMSearchField(); - - if (searchField.value == this.searchLabel) // clear "Search" term upon entry - { - searchField.value = ''; - this.searchActive = true; - } - } - else if (!isActive) // directly remove the panel - { - this.DOMSearchBox().className = 'MSearchBoxInactive'; - this.DOMSearchField().value = this.searchLabel; - this.searchActive = false; - this.lastSearchValue = '' - this.lastResultsPage = ''; - } - } -} - -// ----------------------------------------------------------------------- - -// The class that handles everything on the search results page. -function SearchResults(name) -{ - // The number of matches from the last run of . - this.lastMatchCount = 0; - this.lastKey = 0; - this.repeatOn = false; - - // Toggles the visibility of the passed element ID. - this.FindChildElement = function(id) - { - var parentElement = document.getElementById(id); - var element = parentElement.firstChild; - - while (element && element!=parentElement) - { - if (element.nodeName == 'DIV' && element.className == 'SRChildren') - { - return element; - } - - if (element.nodeName == 'DIV' && element.hasChildNodes()) - { - element = element.firstChild; - } - else if (element.nextSibling) - { - element = element.nextSibling; - } - else - { - do - { - element = element.parentNode; - } - while (element && element!=parentElement && !element.nextSibling); - - if (element && element!=parentElement) - { - element = element.nextSibling; - } - } - } - } - - this.Toggle = function(id) - { - var element = this.FindChildElement(id); - if (element) - { - if (element.style.display == 'block') - { - element.style.display = 'none'; - } - else - { - element.style.display = 'block'; - } - } - } - - // Searches for the passed string. If there is no parameter, - // it takes it from the URL query. - // - // Always returns true, since other documents may try to call it - // and that may or may not be possible. - this.Search = function(search) - { - if (!search) // get search word from URL - { - search = window.location.search; - search = search.substring(1); // Remove the leading '?' - search = unescape(search); - } - - search = search.replace(/^ +/, ""); // strip leading spaces - search = search.replace(/ +$/, ""); // strip trailing spaces - search = search.toLowerCase(); - search = convertToId(search); - - var resultRows = document.getElementsByTagName("div"); - var matches = 0; - - var i = 0; - while (i < resultRows.length) - { - var row = resultRows.item(i); - if (row.className == "SRResult") - { - var rowMatchName = row.id.toLowerCase(); - rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_' - - if (search.length<=rowMatchName.length && - rowMatchName.substr(0, search.length)==search) - { - row.style.display = 'block'; - matches++; - } - else - { - row.style.display = 'none'; - } - } - i++; - } - document.getElementById("Searching").style.display='none'; - if (matches == 0) // no results - { - document.getElementById("NoMatches").style.display='block'; - } - else // at least one result - { - document.getElementById("NoMatches").style.display='none'; - } - this.lastMatchCount = matches; - return true; - } - - // return the first item with index index or higher that is visible - this.NavNext = function(index) - { - var focusItem; - while (1) - { - var focusName = 'Item'+index; - focusItem = document.getElementById(focusName); - if (focusItem && focusItem.parentNode.parentNode.style.display=='block') - { - break; - } - else if (!focusItem) // last element - { - break; - } - focusItem=null; - index++; - } - return focusItem; - } - - this.NavPrev = function(index) - { - var focusItem; - while (1) - { - var focusName = 'Item'+index; - focusItem = document.getElementById(focusName); - if (focusItem && focusItem.parentNode.parentNode.style.display=='block') - { - break; - } - else if (!focusItem) // last element - { - break; - } - focusItem=null; - index--; - } - return focusItem; - } - - this.ProcessKeys = function(e) - { - if (e.type == "keydown") - { - this.repeatOn = false; - this.lastKey = e.keyCode; - } - else if (e.type == "keypress") - { - if (!this.repeatOn) - { - if (this.lastKey) this.repeatOn = true; - return false; // ignore first keypress after keydown - } - } - else if (e.type == "keyup") - { - this.lastKey = 0; - this.repeatOn = false; - } - return this.lastKey!=0; - } - - this.Nav = function(evt,itemIndex) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==13) return true; - if (!this.ProcessKeys(e)) return false; - - if (this.lastKey==38) // Up - { - var newIndex = itemIndex-1; - var focusItem = this.NavPrev(newIndex); - if (focusItem) - { - var child = this.FindChildElement(focusItem.parentNode.parentNode.id); - if (child && child.style.display == 'block') // children visible - { - var n=0; - var tmpElem; - while (1) // search for last child - { - tmpElem = document.getElementById('Item'+newIndex+'_c'+n); - if (tmpElem) - { - focusItem = tmpElem; - } - else // found it! - { - break; - } - n++; - } - } - } - if (focusItem) - { - focusItem.focus(); - } - else // return focus to search field - { - parent.document.getElementById("MSearchField").focus(); - } - } - else if (this.lastKey==40) // Down - { - var newIndex = itemIndex+1; - var focusItem; - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem && elem.style.display == 'block') // children visible - { - focusItem = document.getElementById('Item'+itemIndex+'_c0'); - } - if (!focusItem) focusItem = this.NavNext(newIndex); - if (focusItem) focusItem.focus(); - } - else if (this.lastKey==39) // Right - { - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem) elem.style.display = 'block'; - } - else if (this.lastKey==37) // Left - { - var item = document.getElementById('Item'+itemIndex); - var elem = this.FindChildElement(item.parentNode.parentNode.id); - if (elem) elem.style.display = 'none'; - } - else if (this.lastKey==27) // Escape - { - parent.searchBox.CloseResultsWindow(); - parent.document.getElementById("MSearchField").focus(); - } - else if (this.lastKey==13) // Enter - { - return true; - } - return false; - } - - this.NavChild = function(evt,itemIndex,childIndex) - { - var e = (evt) ? evt : window.event; // for IE - if (e.keyCode==13) return true; - if (!this.ProcessKeys(e)) return false; - - if (this.lastKey==38) // Up - { - if (childIndex>0) - { - var newIndex = childIndex-1; - document.getElementById('Item'+itemIndex+'_c'+newIndex).focus(); - } - else // already at first child, jump to parent - { - document.getElementById('Item'+itemIndex).focus(); - } - } - else if (this.lastKey==40) // Down - { - var newIndex = childIndex+1; - var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex); - if (!elem) // last child, jump to parent next parent - { - elem = this.NavNext(itemIndex+1); - } - if (elem) - { - elem.focus(); - } - } - else if (this.lastKey==27) // Escape - { - parent.searchBox.CloseResultsWindow(); - parent.document.getElementById("MSearchField").focus(); - } - else if (this.lastKey==13) // Enter - { - return true; - } - return false; - } -} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.png b/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.png deleted file mode 100644 index 9dd2396db..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/search/search.png and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/settings.html b/slsDetectorSoftware/slsDetectorClientDocs/html/settings.html deleted file mode 100644 index c3c418784..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/settings.html +++ /dev/null @@ -1,95 +0,0 @@ - - - - - -Detector settings commands - - - - - - - - - -
- - -

Detector settings commands

Commands to setup the settings of the detector

-
    -
  • settingsdir [dir] Sets/gets the directory where the settings files are located (string)
  • -
-
    -
  • trimdir [dir] obsolete settingsdir
  • -
-
    -
  • caldir [dir] Sets/gets the directory where the calibration files are located (string)
  • -
-
    -
  • trimen [n e0 e1...e(n-1)] Sets/gets the number of energies n at which the detector has default trim file and their values in eV (int)
  • -
-
    -
  • settings [s] sets/gets the settings of the detector. Options: standard, fast, highgain, dynamicgain, lowgain, mediumgain, veryhighgain, lownoise, dynamichg0, fixgain1, fixgain2, forceswitchg1, forceswitchg2.
    - In Eiger, only sets in client shared memory. Use threshold or thresholdnotb to pass to detector. Gets from detector.
  • -
-
    -
  • threshold [eV] [sett] sets/gets the detector threshold in eV. sett is optional and if provided also sets the settings. Use this for Eiger instead of settings.
  • -
-
    -
  • thresholdnotb [eV] [sett] sets/gets the detector threshold in eV without loading trimbits. sett is optional and if provided also sets the settings. Use this for Eiger instead of settings.
  • -
-
    -
  • trimbits [fname] loads/stores the trimbits to/from the detector. If no extension is specified, the serial number of each module will be attached.
  • -
-
    -
  • trim:[mode] [fname] trims the detector according to mode and saves resulting trimbits to file. Mode: noise, beam, improve, fix. Used in MYTHEN only. Only put!
  • -
-
    -
  • trimval [i] sets all trimbits to i. Used in EIGER only.
  • -
-
    -
  • pedestal [i] starts acquisition for i frames, calculates pedestal and writes back to fpga. Used in GOTTHARD only. Only put!
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_b.gif b/slsDetectorSoftware/slsDetectorClientDocs/html/tab_b.gif deleted file mode 100644 index 0d623483f..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_b.gif and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_l.gif b/slsDetectorSoftware/slsDetectorClientDocs/html/tab_l.gif deleted file mode 100644 index 9b1e6337c..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_l.gif and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_r.gif b/slsDetectorSoftware/slsDetectorClientDocs/html/tab_r.gif deleted file mode 100644 index ce9dd9f53..000000000 Binary files a/slsDetectorSoftware/slsDetectorClientDocs/html/tab_r.gif and /dev/null differ diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/tabs.css b/slsDetectorSoftware/slsDetectorClientDocs/html/tabs.css deleted file mode 100644 index a44416341..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/tabs.css +++ /dev/null @@ -1,105 +0,0 @@ -/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */ - -DIV.tabs -{ - float : left; - width : 100%; - background : url("tab_b.gif") repeat-x bottom; - margin-bottom : 4px; -} - -DIV.tabs UL -{ - margin : 0px; - padding-left : 10px; - list-style : none; -} - -DIV.tabs LI, DIV.tabs FORM -{ - display : inline; - margin : 0px; - padding : 0px; -} - -DIV.tabs FORM -{ - float : right; -} - -DIV.tabs A -{ - float : left; - background : url("tab_r.gif") no-repeat right top; - border-bottom : 1px solid #84B0C7; - font-size : 80%; - font-weight : bold; - text-decoration : none; -} - -DIV.tabs A:hover -{ - background-position: 100% -150px; -} - -DIV.tabs A:link, DIV.tabs A:visited, -DIV.tabs A:active, DIV.tabs A:hover -{ - color: #1A419D; -} - -DIV.tabs SPAN -{ - float : left; - display : block; - background : url("tab_l.gif") no-repeat left top; - padding : 5px 9px; - white-space : nowrap; -} - -DIV.tabs #MSearchBox -{ - float : right; - display : inline; - font-size : 1em; -} - -DIV.tabs TD -{ - font-size : 80%; - font-weight : bold; - text-decoration : none; -} - - - -/* Commented Backslash Hack hides rule from IE5-Mac \*/ -DIV.tabs SPAN {float : none;} -/* End IE5-Mac hack */ - -DIV.tabs A:hover SPAN -{ - background-position: 0% -150px; -} - -DIV.tabs LI.current A -{ - background-position: 100% -150px; - border-width : 0px; -} - -DIV.tabs LI.current SPAN -{ - background-position: 0% -150px; - padding-bottom : 6px; -} - -DIV.navpath -{ - background : none; - border : none; - border-bottom : 1px solid #84B0C7; - text-align : center; - margin : 2px; - padding : 2px; -} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/html/test.html b/slsDetectorSoftware/slsDetectorClientDocs/html/test.html deleted file mode 100644 index 488afcf72..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/html/test.html +++ /dev/null @@ -1,100 +0,0 @@ - - - - - -Developer - - - - - - - - - -
- - -

Developer

Commands to be used only for software debugging. Avoid using them!

-
    -
  • test returns an error
  • -
-
    -
  • help Returns a list of possible commands.
  • -
-
    -
  • exitserver Shuts down all the detector servers. Don't use it!!!!
  • -
-
    -
  • exitreceiver Shuts down all the receivers. Don't use it!!!!
  • -
-
    -
  • flippeddatay [i] enables/disables data being flipped across y axis. 1 enables, 0 disables. Not implemented.
  • -
-
    -
  • digitest [i] will perform test which will plot the unique channel identifier, instead of data. Only get!
  • -
-
    -
  • bustest performs test of the bus interface between FPGA and embedded Linux system. Can last up to a few minutes. Cannot set! Used for Mythen only. Only get!
  • -
-
    -
  • digibittest:[i] performs digital test of the module i. Returns 0 if succeeded, otherwise error mask. Only put!
  • -
-
    -
  • reg [addr] [val] ??? writes to an register addr with value in hexadecimal format.
  • -
-
    -
  • adcreg [addr] [val] ??? writes to an adc register addr with value in hexadecimal format. Only put!
  • -
-
    -
  • setbit ??? Only put!
  • -
-
    -
  • clearbit ??? Only put!
  • -
-
    -
  • getbit ??? Only get!
  • -
-
- -
-
- - -
- -
- -
Generated on 15 Aug 2017 by  - -doxygen 1.6.1
- - diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/Makefile b/slsDetectorSoftware/slsDetectorClientDocs/latex/Makefile deleted file mode 100644 index 8b7c89a1b..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/Makefile +++ /dev/null @@ -1,19 +0,0 @@ -all: clean refman.pdf - -pdf: refman.pdf - -refman.pdf: refman.tex - pdflatex refman.tex - makeindex refman.idx - pdflatex refman.tex - latex_count=5 ; \ - while egrep -s 'Rerun (LaTeX|to get cross-references right)' refman.log && [ $$latex_count -gt 0 ] ;\ - do \ - echo "Rerunning latex...." ;\ - pdflatex refman.tex ;\ - latex_count=`expr $$latex_count - 1` ;\ - done - - -clean: - rm -f *.ps *.dvi *.aux *.toc *.idx *.ind *.ilg *.log *.out refman.pdf diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/acquisition.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/acquisition.tex deleted file mode 100644 index 29603ddd1..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/acquisition.tex +++ /dev/null @@ -1,41 +0,0 @@ -Commands to control the acquisition - - -\begin{DoxyItemize} -\item {\bfseries acquire} blocking acquisition (like calling sls\_\-detector\_\-acquire). Starts receiver and detector, writes and processes the data, stops detector. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries data} gets all data from the detector (if any) processes them and writes them to file according to the preferences already setup (MYTHEN only). Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries frame} gets a single frame from the detector (if any) processes it and writes it to file according to the preferences already setup (MYTHEN only). Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries status} {\ttfamily returns} the detector status (string)-\/ can be: {\ttfamily running}, {\ttfamily error}, {\ttfamily transmitting}, {\ttfamily finished}, {\ttfamily waiting} or {\ttfamily idle}; {\ttfamily put} can be {\ttfamily start} or {\ttfamily stop} -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries busy} returns {\ttfamily 1} if the acquisition is active, {\ttfamily 0} otherwise. Works when the acquisition is started in non-\/blocking mode. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries readctr } Reads the counters from the detector memory (analog detector returning values translated into number of photons -\/ only GOTTHARD). Cannot put. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries resetctr i } Resets counter in detector, restarts acquisition if i=1(analog detector returning values translated into number of photons -\/ only GOTTHARD). Cannot put. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries resmat i } sets/resets counter bit in detector.gets the counter bit in detector ???? -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/actions.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/actions.tex deleted file mode 100644 index c21066a0d..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/actions.tex +++ /dev/null @@ -1,126 +0,0 @@ -Commands to define scripts to be executed during the acquisition flow - - -\begin{DoxyItemize} -\item {\bfseries positions \mbox{[}n \mbox{[}p0..pn-\/1\mbox{]}\mbox{]}} sets/gets number of angular position and positions to be acquired. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries startscript \mbox{[}s\mbox{]}} sets/gets the script to be executed at the beginning of the acquisition. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries startscriptpar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the startscript -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries stopscript \mbox{[}s\mbox{]}} sets/gets the script to be executed at the end of the acquisition. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries stopscriptpar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the stopscript -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scriptbefore \mbox{[}s\mbox{]}} sets/gets the script to be executed before starting the detector every time in the acquisition. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scriptbeforepar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the scriptbefore -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scriptafter \mbox{[}s\mbox{]}} sets/gets the script to be executed after the detector has finished every time in the acquisition. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scriptafterpar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the scriptafter -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries headerafter \mbox{[}s\mbox{]}} sets/gets the script to be executed for logging the detector parameters. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries headerbefore \mbox{[}s\mbox{]}} sets/gets the script to be executed for logging the detector parameters. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries headerbeforepar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the headerbefore script -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries headerafterpar \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the headerafter script -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries enacallog \mbox{[}i\mbox{]}} enables/disables logging of the parameters necessary for the energy calibration. 1 sets, 0 unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries angcallog \mbox{[}i\mbox{]}} enables/disables logging of the parameters necessary for the angular calibration. 1 sets, 0 unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan0script \mbox{[}s\mbox{]}} sets/gets the script to be executed for the scan 0 level. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan0par \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the scan0script -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan0prec \mbox{[}i\mbox{]}} sets/gets number of digits to be used for the scan0 variable in the file name. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan0steps \mbox{[}i \mbox{[}s0..sn-\/1\mbox{]}\mbox{]}} sets/gets number of steps (int) of the scan0 level and their values (float). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan0range \mbox{[}smin smax sstep\mbox{]}} sets scan0 min, max and step, returns the number of steps and their values as scan0steps. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan1script \mbox{[}s\mbox{]}} sets/gets the script to be executed for the scan1 level. {\ttfamily none} unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan1par \mbox{[}s\mbox{]}} sets/gets a string to be passed as a parameter to the scan1script -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan1prec \mbox{[}i\mbox{]}} sets/gets number of digits to be used for the scan1 variable in the file name. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan1steps \mbox{[}i \mbox{[}s0..sn-\/1\mbox{]}\mbox{]}} sets/gets number of steps (int) of the scan1 level and their values (float). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries scan1range \mbox{[}smin smax sstep\mbox{]}} sets scan1 min, max and step, returns the number of steps and their values as scan1steps. -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/advanced.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/advanced.tex deleted file mode 100644 index 72d2fa6d2..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/advanced.tex +++ /dev/null @@ -1 +0,0 @@ -This page is for advanced users. Make sure you have first read the introduction. \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/config.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/config.tex deleted file mode 100644 index 4fae3e75f..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/config.tex +++ /dev/null @@ -1,257 +0,0 @@ -Commands to configure the detector. these commands are often left to the configuration file. - - -\begin{DoxyItemize} -\item {\bfseries datastream} enables/disables the 0MQ data stream (0MQ threads created) from receiver to client. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries free} Free shared memory on the control PC -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries add} Adds a detector at the end of the multi-\/detector structure. {\ttfamily put} argument is the hostname or IP adress. Returns the chained list of detector hostnames. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries remove i} Removes controller {\ttfamily i} from the multi-\/detector structure. Can be used for partial readout of the detector. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries type} Sets/gets detector type (string). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries hostname} {\ttfamily put} adds the hostname (ot IP adress) at the end of the multi-\/detector structure. If used for a single controlled (i:) replaces the current hostname. Returns the list of the hostnames of the multi-\/detector structure. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries id\mbox{[}:i\mbox{]}} Returns the id of the detector structure. i is the detector position in a multi detector system. If used a {\ttfamily put}, configures the id of the detector structure. i is the detector position in a multi detector system and l is the id of the detector to be added. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries master i} {\ttfamily put} sets the position of the master of the acquisition (-\/1 if none). Returns the position of the master of the detector structure (-\/1 if none). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries sync} Sets/gets the synchronization mode of the detectors in the multi-\/detector structure. Can be: {\ttfamily none}, {\ttfamily gating}, {\ttfamily trigger}, {\ttfamily complementary}. Mainly used by MYTHEN/GOTTHARD. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries online \mbox{[}i\mbox{]}} sets the detector in online (1) or offline (0) mode -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries checkonline} returns the hostnames of all detectors without connecting to them -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries activate} Activates/Deactivates the detector. Deactivated detector does not send data. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries lock \mbox{[}i\mbox{]}} Locks/Unlocks the detector to communicate with this client. 1 locks, 0 unlocks. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries nmod \mbox{[}i\mbox{]}} sets/gets the number of modules of the detector. Used for MYTHEN only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries maxmod } Gets the maximum number of modules of the detector. Used for MYTHEN only. Cannot put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries dr \mbox{[}i\mbox{]}} sets/gets the dynamic range of detector. Mythen \mbox{[}4,8,16,24\mbox{]}. Eiger \mbox{[}4,8,16,32\mbox{]}. Others cannot put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries roi \mbox{[}i\mbox{]} \mbox{[}xmin\mbox{]} \mbox{[}xmax\mbox{]} \mbox{[}ymin\mbox{]} \mbox{[}ymax\mbox{]} } sets region of interest of the detector, where i is number of rois;i=0 to clear rois. Used for GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries detsizechan \mbox{[}xmax\mbox{]} \mbox{[}ymax\mbox{]}} sets the maximum number of channels in each dimension for complete detector set; -\/1 is no limit. Use for multi-\/detector system as first command in config file. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries roimask \mbox{[}i\mbox{]}} ?? -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries flippeddatax \mbox{[}i\mbox{]}} enables/disables data being flipped across x axis. 1 enables, 0 disables. Used for EIGER only. 1 for bottom half-\/module, 0 for top-\/half module. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries flags \mbox{[}flag\mbox{]}} sets/gets the readout flags to mode. Options: none, storeinram, tot, continous, parallel, nonparallel, safe, digital, analog\_\-digital, unknown. Used for MYTHEN and EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries extsig:\mbox{[}i\mbox{]} \mbox{[}flag\mbox{]}} sets/gets the mode of the external signal i. Options: {\ttfamily off}, {\ttfamily gate\_\-in\_\-active\_\-high}, {\ttfamily gate\_\-in\_\-active\_\-low}, {\ttfamily trigger\_\-in\_\-rising\_\-edge}, {\ttfamily trigger\_\-in\_\-falling\_\-edge}, {\ttfamily ro\_\-trigger\_\-in\_\-rising\_\-edge}, {\ttfamily ro\_\-trigger\_\-in\_\-falling\_\-edge}, {\ttfamily gate\_\-out\_\-active\_\-high}, {\ttfamily gate\_\-out\_\-active\_\-low}, {\ttfamily trigger\_\-out\_\-rising\_\-edge}, {\ttfamily trigger\_\-out\_\-falling\_\-edge}, {\ttfamily ro\_\-trigger\_\-out\_\-rising\_\-edge}, {\ttfamily ro\_\-trigger\_\-out\_\-falling\_\-edge}. \par - Used in MYTHEN, GOTTHARD, PROPIX only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries programfpga \mbox{[}file\mbox{]}} programs the FPGA with file f (with .pof extension). Used for JUNGFRAU, MOENCH only. Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries resetfpga \mbox{[}f\mbox{]}} resets FPGA, where f can be any value. Used for JUNGFRAU only. Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries powerchip \mbox{[}i\mbox{]}} Powers on/off the chip. 1 powers on, 0 powers off. Can also get the power status. Used for JUNGFRAU only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries led \mbox{[}i\mbox{]}} sets/gets the led status. 1 on, 0 off. Used for MOENCH only ?? -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries moduleversion:\mbox{[}i\mbox{]}} Gets the firmware version of module i. Used for MYTHEN only. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries detectornumber} Gets the serial number or MAC of detector. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries modulenumber:\mbox{[}i\mbox{]}} Gets the serial number of module i. Used for MYTHEN only. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries detectorversion} Gets the firmware version of detector. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries softwareversion} Gets the software version of detector server. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries thisversion} Gets the software version of this client software. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries receiverversion} Gets the software version of receiver. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries timing \mbox{[}mode\mbox{]}} sets/gets synchronization mode of the detector. Mode: auto, trigger, ro\_\-trigger, gating, triggered\_\-gating -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries exptime \mbox{[}i\mbox{]}} sets/gets exposure time in s -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries subexptime \mbox{[}i\mbox{]}} sets/gets sub exposure time in s. Used in EIGER only in 32 bit mode. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries period \mbox{[}i\mbox{]}} sets/gets frame period in s. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries delay \mbox{[}i\mbox{]}} sets/gets delay in s. Used in MYTHEN, GOTTHARD only -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries gates \mbox{[}i\mbox{]}} sets/gets number of gates. Used in MYTHEN, GOTTHARD, EIGER only -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries gates \mbox{[}i\mbox{]}} sets/gets number of frames. If {\ttfamily timing} is not {\ttfamily auto}, then it is the number of frames per cycle/trigger. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries cycles \mbox{[}i\mbox{]}} sets/gets number of triggers. Timing mode should be set appropriately. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries probes \mbox{[}i\mbox{]}} sets/gets number of probes to accumulate. When setting, max 3! cycles should be set to 1, frames to the number of pump-\/probe events. Used in MYTHEN only -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries measurements \mbox{[}i\mbox{]}} sets/gets number of measurements. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries samples \mbox{[}i\mbox{]}} sets/gets number of samples expected from the jctb. Used in CHIP TEST BOARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries exptimel \mbox{[}i\mbox{]}} gets exposure time left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries periodl \mbox{[}i\mbox{]}} gets frame period left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries delayl \mbox{[}i\mbox{]}} gets delay left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries gatesl \mbox{[}i\mbox{]}} gets number of gates left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries framesl \mbox{[}i\mbox{]}} gets number of frames left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries cyclesl \mbox{[}i\mbox{]}} gets number of cylces left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries probesl \mbox{[}i\mbox{]}} gets number of probes left. Used in MYTHEN, GOTTHARD only. -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/data.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/data.tex deleted file mode 100644 index 898020fd0..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/data.tex +++ /dev/null @@ -1,76 +0,0 @@ -Commands to setup the data processing (mainly MYTHEN related) - - -\begin{DoxyItemize} -\item {\bfseries flatfield \mbox{[}fn\mbox{]}} {\ttfamily put} sets flatfield file to {\ttfamily fn} (relative to {\ttfamily ffdir}). returns the flatfield file name relative to {\ttfamily ffdir} (string). If -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries ffdir \mbox{[}d\mbox{]}} Sets/gets the directory in which the flat field file is located. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries ratecorr \mbox{[}ns\mbox{]}} Returns the dead time used for rate correections in ns (int). {\ttfamily put} sets the deadtime correction constant in ns, -\/1 will set it to default tau of settings (0 unset). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries badchannels \mbox{[}fn\mbox{]}} {\ttfamily put} sets the badchannels file to {\ttfamily fn} . returns the bad channels file name. If -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries angconv \mbox{[}fn\mbox{]}} {\ttfamily put} sets the angular conversion file to {\ttfamily fn} . returns the angular conversion file name. If -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries globaloff \mbox{[}f\mbox{]}} Sets/gets the beamline angular global offset (float). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries fineoff \mbox{[}f\mbox{]}} Sets/gets the angular fine offset of the measurement (float). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries binsize \mbox{[}f\mbox{]}} Sets/gets the bin size used for the angular conversion (float). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries angdir \mbox{[}i\mbox{]}} Sets/gets the angular direction. 1 means increasing channels number as increasing angle, -\/1 increasing channel number decreasing angle. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries moveflag \mbox{[}i\mbox{]}} Sets/gets the flag for physically moving the detector during the acquisition of several positions. 1 sets (moves), 0 unsets. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries samplex \mbox{[}f\mbox{]}} Sets/gets the sample displacement in th direction parallel to the beam in um. Unused! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries sampley \mbox{[}f\mbox{]}} Sets/gets the sample displacement in th direction orthogonal to the beam in um. Unused! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries threaded \mbox{[}i\mbox{]}} Sets/gets the data processing threaded flag. 1 is threaded, 0 unthreaded. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries darkimage fn} Loads the dark image to the detector from file fn (pedestal image). Cannot get. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries gainimage fn} Loads the gain image to the detector from file fn (gain map for translation into number of photons of an analog detector). Cannot get. -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/doxygen.sty b/slsDetectorSoftware/slsDetectorClientDocs/latex/doxygen.sty deleted file mode 100644 index b58496031..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/doxygen.sty +++ /dev/null @@ -1,348 +0,0 @@ -\NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{doxygen} - -% Packages used by this style file -\RequirePackage{alltt} -\RequirePackage{array} -\RequirePackage{calc} -\RequirePackage{color} -\RequirePackage{fancyhdr} -\RequirePackage{verbatim} - -% Setup fancy headings -\pagestyle{fancyplain} -\newcommand{\clearemptydoublepage}{% - \newpage{\pagestyle{empty}\cleardoublepage}% -} -\renewcommand{\sectionmark}[1]{% - \markright{\thesection\ #1}% -} -\lhead[\fancyplain{}{\bfseries\thepage}]{% - \fancyplain{}{\bfseries\rightmark}% -} -\rhead[\fancyplain{}{\bfseries\leftmark}]{% - \fancyplain{}{\bfseries\thepage}% -} -\rfoot[\fancyplain{}{\bfseries\scriptsize% - Generated on Tue Aug 15 18:42:37 2017 by Doxygen }]{} -\lfoot[]{\fancyplain{}{\bfseries\scriptsize% - Generated on Tue Aug 15 18:42:37 2017 by Doxygen }} -\cfoot{} - -%---------- Internal commands used in this style file ---------------- - -% Generic environment used by all paragraph-based environments defined -% below. Note that the command \title{...} needs to be defined inside -% those environments! -\newenvironment{DoxyDesc}[1]{% - \begin{list}{}% - {% - \settowidth{\labelwidth}{40pt}% - \setlength{\leftmargin}{\labelwidth}% - \setlength{\parsep}{0pt}% - \setlength{\itemsep}{-4pt}% - \renewcommand{\makelabel}{\entrylabel}% - }% - \item[#1:]% -}{% - \end{list}% -} - -%---------- Commands used by doxygen LaTeX output generator ---------- - -% Used by
 ... 
-\newenvironment{DoxyPre}{% - \small% - \begin{alltt}% -}{% - \end{alltt}% - \normalsize% -} - -% Used by @code ... @endcode -\newenvironment{DoxyCode}{% - \footnotesize% - \verbatim% -}{% - \endverbatim% - \normalsize% -} - -% Used by @example, @include, @includelineno and @dontinclude -\newenvironment{DoxyCodeInclude}{% - \DoxyCode% -}{% - \endDoxyCode% -} - -% Used by @verbatim ... @endverbatim -\newenvironment{DoxyVerb}{% - \footnotesize% - \verbatim% -}{% - \endverbatim% - \normalsize% -} - -% Used by @verbinclude -\newenvironment{DoxyVerbInclude}{% - \DoxyVerb% -}{% - \endDoxyVerb% -} - -% Used by numbered lists (using '-#' or
    ...
) -\newenvironment{DoxyEnumerate}{% - \enumerate% -}{% - \endenumerate% -} - -% Used by bullet lists (using '-', @li, @arg, or
    ...
) -\newenvironment{DoxyItemize}{% - \itemize% -}{% - \enditemize% -} - -% Used by description lists (using
...
) -\newenvironment{DoxyDescription}{% - \description% -}{% - \enddescription% -} - -% Used by @image, @dotfile, and @dot ... @enddot -% (only if caption is specified) -\newenvironment{DoxyImage}{% - \begin{figure}[H]% - \begin{center}% -}{% - \end{center}% - \end{figure}% -} - -% Used by @image, @dotfile, @dot ... @enddot, and @msc ... @endmsc -% (only if no caption is specified) -\newenvironment{DoxyImageNoCaption}{% -}{% -} - -% Used by @attention -\newenvironment{DoxyAttention}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @author and @authors -\newenvironment{DoxyAuthor}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @date -\newenvironment{DoxyDate}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @invariant -\newenvironment{DoxyInvariant}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @note -\newenvironment{DoxyNote}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @post -\newenvironment{DoxyPostcond}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @pre -\newenvironment{DoxyPrecond}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @remark -\newenvironment{DoxyRemark}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @return -\newenvironment{DoxyReturn}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @since -\newenvironment{DoxySince}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @see -\newenvironment{DoxySeeAlso}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @version -\newenvironment{DoxyVersion}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @warning -\newenvironment{DoxyWarning}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @internal -\newenvironment{DoxyInternal}[1]{% - \begin{DoxyDesc}{#1}% -}{% - \end{DoxyDesc}% -} - -% Used by @par and @paragraph -\newenvironment{DoxyParagraph}[1]{% - \begin{list}{}% - {% - \settowidth{\labelwidth}{40pt}% - \setlength{\leftmargin}{\labelwidth}% - \setlength{\parsep}{0pt}% - \setlength{\itemsep}{-4pt}% - \renewcommand{\makelabel}{\entrylabel}% - }% - \item[#1]% -}{% - \end{list}% -} - -% Used by parameter lists -\newenvironment{DoxyParams}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% -}{% - \end{description}% - \end{DoxyDesc}% -} - -% Used by return value lists -\newenvironment{DoxyRetVals}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% -}{% - \end{description}% - \end{DoxyDesc}% -} - -% Used by exception lists -\newenvironment{DoxyExceptions}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% -}{% - \end{description}% - \end{DoxyDesc}% -} - -% Used by template parameter lists -\newenvironment{DoxyTemplParams}[1]{% - \begin{DoxyDesc}{#1}% - \begin{description}% -}{% - \end{description}% - \end{DoxyDesc}% -} - -\newcommand{\doxyref}[3]{\textbf{#1} (\textnormal{#2}\,\pageref{#3})} -\newenvironment{DoxyCompactList} -{\begin{list}{}{ - \setlength{\leftmargin}{0.5cm} - \setlength{\itemsep}{0pt} - \setlength{\parsep}{0pt} - \setlength{\topsep}{0pt} - \renewcommand{\makelabel}{\hfill}}} -{\end{list}} -\newenvironment{DoxyCompactItemize} -{ - \begin{itemize} - \setlength{\itemsep}{-3pt} - \setlength{\parsep}{0pt} - \setlength{\topsep}{0pt} - \setlength{\partopsep}{0pt} -} -{\end{itemize}} -\newcommand{\PBS}[1]{\let\temp=\\#1\let\\=\temp} -\newlength{\tmplength} -\newenvironment{TabularC}[1] -{ -\setlength{\tmplength} - {\linewidth/(#1)-\tabcolsep*2-\arrayrulewidth*(#1+1)/(#1)} - \par\begin{tabular*}{\linewidth} - {*{#1}{|>{\PBS\raggedright\hspace{0pt}}p{\the\tmplength}}|} -} -{\end{tabular*}\par} -\newcommand{\entrylabel}[1]{ - {\parbox[b]{\labelwidth-4pt}{\makebox[0pt][l]{\textbf{#1}}\vspace{1.5\baselineskip}}}} -\newenvironment{Desc} -{\begin{list}{} - { - \settowidth{\labelwidth}{40pt} - \setlength{\leftmargin}{\labelwidth} - \setlength{\parsep}{0pt} - \setlength{\itemsep}{-4pt} - \renewcommand{\makelabel}{\entrylabel} - } -} -{\end{list}} -\newenvironment{Indent} - {\begin{list}{}{\setlength{\leftmargin}{0.5cm}} - \item[]\ignorespaces} - {\unskip\end{list}} -\setlength{\parindent}{0cm} -\setlength{\parskip}{0.2cm} -\addtocounter{secnumdepth}{1} -\sloppy -\usepackage[T1]{fontenc} -\makeatletter -\renewcommand{\paragraph}{\@startsection{paragraph}{4}{0ex}% - {-3.25ex plus -1ex minus -0.2ex}% - {1.5ex plus 0.2ex}% - {\normalfont\normalsize\bfseries}} -\makeatother -\stepcounter{secnumdepth} -\stepcounter{tocdepth} -\definecolor{comment}{rgb}{0.5,0.0,0.0} -\definecolor{keyword}{rgb}{0.0,0.5,0.0} -\definecolor{keywordtype}{rgb}{0.38,0.25,0.125} -\definecolor{keywordflow}{rgb}{0.88,0.5,0.0} -\definecolor{preprocessor}{rgb}{0.5,0.38,0.125} -\definecolor{stringliteral}{rgb}{0.0,0.125,0.25} -\definecolor{charliteral}{rgb}{0.0,0.5,0.5} -\definecolor{vhdldigit}{rgb}{1.0,0.0,1.0} -\definecolor{vhdlkeyword}{rgb}{0.43,0.0,0.43} -\definecolor{vhdllogic}{rgb}{1.0,0.0,0.0} -\definecolor{vhdlchar}{rgb}{0.0,0.0,0.0} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/index.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/index.tex deleted file mode 100644 index 613142828..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/index.tex +++ /dev/null @@ -1,44 +0,0 @@ -This program is intended to control the SLS detectors via command line interface. This is the only way to access all possible functionality of the detectors, however it is often recommendable to avoid changing the most advanced settings, rather leaving the task to configuration files, as when using the GUI or the API provided. - -The command line interface consists in four main functions: - - -\begin{DoxyItemize} -\item {\bfseries sls\_\-detector\_\-acquire} to acquire data from the detector -\item {\bfseries sls\_\-detector\_\-put} to set detector parameters -\item {\bfseries sls\_\-detector\_\-get} to retrieve detector parameters -\item {\bfseries sls\_\-detector\_\-help} to get help concerning the text commands Additionally the program slsReceiver should be started on the machine expected to receive the data from the detector. -\end{DoxyItemize} - -If you need control a single detector, the use of the command line interface does not need any additional arguments. - -For commands addressing a single controller of your detector, the command cmd should be called with the index i of the controller: - -{\bfseries sls\_\-detector\_\-clnt i:cmd} - -where {\bfseries sls\_\-detector\_\-clnt} is the text client (put, get, acquire, help). - -In case more than one detector is configured on the control PC, the command cmd should be called with their respective index j: - -{\bfseries sls\_\-detector\_\-clnt j-\/cmd} - -where {\bfseries sls\_\-detector\_\-clnt} is the text client (put, get, acquire, help). - -To address a specific controller i of detector j use: - -{\bfseries sls\_\-detector\_\-clnt j-\/i:cmd} - -For additional questions concerning the indexing of the detector, please refer to the SLS Detectors FAQ documentation. - -The commands are sudivided into different pages depending on their functionalities: -\begin{DoxyItemize} -\item \hyperlink{acquisition}{Acquition commands} Acquisition: commands to start/stop the acquisition and retrieve data -\item \hyperlink{config}{Configuration commands} Configuration: commands to configure the detector -\item \hyperlink{data}{Data postprocessing}: commands to process the data -\/ mainly for MYTHEN except for rate corrections. -\item \hyperlink{settings}{Settings}: commands to define detector settings/threshold. -\item \hyperlink{output}{Output}: commands to define output file destination and format -\item \hyperlink{actions}{Actions}: commands to define scripts to be executed during the acquisition flow -\item \hyperlink{network}{Network}: commands to setup the network between client, detector and receiver -\item \hyperlink{receiver}{Receiver}: commands to configure the receiver -\item \hyperlink{test}{Developer} Developer: commands to be used only for software debugging. Avoid using them! -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/network.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/network.tex deleted file mode 100644 index 26dd6c0a1..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/network.tex +++ /dev/null @@ -1,84 +0,0 @@ -Commands to setup the network between client, detector and receiver -\begin{DoxyItemize} -\item {\bfseries rx\_\-hostname \mbox{[}s\mbox{]}} sets/gets the receiver hostname or IP address, configures detector mac with all network parameters and updates receiver with acquisition parameters. Normally used for single detectors (Can be multi-\/detector). {\ttfamily none} disables. If used, use as last network command in configuring detector MAC. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries rx\_\-udpip \mbox{[}ip\mbox{]}} sets/gets the ip address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-\/detector). Used if different from eth0. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries rx\_\-udpmac \mbox{[}mac\mbox{]}} sets/gets the mac address of the receiver UDP interface where the data from the detector will be streamed to. Normally used for single detectors (Can be multi-\/detector). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries rx\_\-udpport \mbox{[}port\mbox{]}} sets/gets the port of the receiver UDP interface where the data from the detector will be streamed to. Use single-\/detector command. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries rx\_\-udpport2 \mbox{[}port\mbox{]}} sets/gets the second port of the receiver UDP interface where the data from the second half of the detector will be streamed to. Use single-\/detector command. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries detectormac \mbox{[}mac\mbox{]}} sets/gets the mac address of the detector UDP interface from where the detector will stream data. Use single-\/detector command. Normally unused. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries detectorip \mbox{[}ip\mbox{]}} sets/gets the ip address of the detector UDP interface from where the detector will stream data. Use single-\/detector command. Keep in same subnet as rx\_\-udpip (if rx\_\-udpip specified). -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries txndelay\_\-left \mbox{[}delay\mbox{]}} sets/gets the transmission delay of first packet in an image being streamed out from the detector's left UDP port. Use single-\/detector command. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries txndelay\_\-right \mbox{[}delay\mbox{]}} sets/gets the transmission delay of first packet in an image being streamed out from the detector's right UDP port. Use single-\/detector command. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries txndelay\_\-frame \mbox{[}delay\mbox{]}} sets/gets the transmission frame period of entire frame being streamed out from the detector for both ports. Use single-\/detector command. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries flowcontrol\_\-10g \mbox{[}delay\mbox{]}} Enables/disables 10 GbE flow control. 1 enables, 0 disables. Used for EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries zmqport \mbox{[}port\mbox{]}} sets/gets the 0MQ (TCP) port of the receiver from where data is streamed to the client. Use single-\/detector command to set individually or multi-\/detector command to calculate based on {\ttfamily port} for the rest. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries configuremac \mbox{[}i\mbox{]}} configures the MAC of the detector with these parameters: detectorip, detectormac, rx\_\-udpip, rx\_\-udpmac, rx\_\-udpport, rx\_\-udpport2 (if applicable). Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries rx\_\-tcpport \mbox{[}port\mbox{]}} sets/gets the port of the client-\/receiver TCP interface. Use single-\/detector command. Is different for each detector if same {\ttfamily rx\_\-hostname} used. Must be first command to communicate with receiver. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries port \mbox{[}port\mbox{]}} sets/gets the port of the client-\/detector control server TCP interface. Use single-\/detector command. Default value is 1952 for all detectors. Normally not changed. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries stopport \mbox{[}port\mbox{]}} sets/gets the port of the client-\/detector stop server TCP interface. Use single-\/detector command. Default value is 1953 for all detectors. Normally not changed. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries lastclient } Gets the last client communicating with the detector. Cannot put! -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/output.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/output.tex deleted file mode 100644 index d75abbf68..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/output.tex +++ /dev/null @@ -1,36 +0,0 @@ -Commands to setup the file destination and format - - -\begin{DoxyItemize} -\item {\bfseries outdir \mbox{[}dir\mbox{]}} Sets/gets the file output directory (string) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries fname \mbox{[}fn\mbox{]}} Sets/gets the root of the output file name (string) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries index \mbox{[}i\mbox{]}} Sets/gets the current file index (int) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries enablefwrite \mbox{[}i\mbox{]}} Enables/disables file writing. 1 enables, 0 disables. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries overwrite \mbox{[}i\mbox{]}} enables(1) /disables(0) file overwriting -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries currentfname} gets the filename for the data without index and extension -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries fileformat} gets the file format for data (no put?) What are the possible return values? -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/receiver.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/receiver.tex deleted file mode 100644 index 6767ad068..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/receiver.tex +++ /dev/null @@ -1 +0,0 @@ -Commands to configure the receiver \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/refman.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/refman.tex deleted file mode 100644 index 81bd951fa..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/refman.tex +++ /dev/null @@ -1,93 +0,0 @@ -\documentclass[a4paper]{article} -\usepackage{makeidx} -\usepackage{graphicx} -\usepackage{multicol} -\usepackage{float} -\usepackage{listings} -\usepackage{color} -\usepackage{textcomp} -\usepackage{alltt} -\usepackage{times} -\usepackage{ifpdf} -\ifpdf -\usepackage[pdftex, - pagebackref=true, - colorlinks=true, - linkcolor=blue, - unicode - ]{hyperref} -\else -\usepackage[ps2pdf, - pagebackref=true, - colorlinks=true, - linkcolor=blue, - unicode - ]{hyperref} -\usepackage{pspicture} -\fi -\usepackage[utf8]{inputenc} -\usepackage{doxygen} -\lstset{language=C++,inputencoding=utf8,basicstyle=\footnotesize,breaklines=true,breakatwhitespace=true,tabsize=8,numbers=left } -\makeindex -\setcounter{tocdepth}{3} -\renewcommand{\footrulewidth}{0.4pt} -\begin{document} -\hypersetup{pageanchor=false} -\begin{titlepage} -\vspace*{7cm} -\begin{center} -{\Large Reference Manual}\\ -\vspace*{1cm} -{\large Generated by Doxygen 1.6.1}\\ -\vspace*{0.5cm} -{\small Tue Aug 15 18:42:37 2017}\\ -\end{center} -\end{titlepage} -\pagenumbering{roman} -\tableofcontents -\pagenumbering{arabic} -\hypersetup{pageanchor=true} -\section{Introduction} -\label{index}\hypertarget{index}{}\input{index} -\section{Developer} -\label{test} -\hypertarget{test}{} -\input{test} -\section{Acquition commands} -\label{acquisition} -\hypertarget{acquisition}{} -\input{acquisition} -\section{Configuration commands} -\label{config} -\hypertarget{config}{} -\input{config} -\section{Data processing commands} -\label{data} -\hypertarget{data}{} -\input{data} -\section{Detector settings commands} -\label{settings} -\hypertarget{settings}{} -\input{settings} -\section{Output settings} -\label{output} -\hypertarget{output}{} -\input{output} -\section{Actions} -\label{actions} -\hypertarget{actions}{} -\input{actions} -\section{Network} -\label{network} -\hypertarget{network}{} -\input{network} -\section{Receiver commands} -\label{receiver} -\hypertarget{receiver}{} -\input{receiver} -\section{Advanced Usage} -\label{advanced} -\hypertarget{advanced}{} -\input{advanced} -\printindex -\end{document} diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/settings.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/settings.tex deleted file mode 100644 index 5655ee20c..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/settings.tex +++ /dev/null @@ -1,57 +0,0 @@ -Commands to setup the settings of the detector - - -\begin{DoxyItemize} -\item {\bfseries settingsdir \mbox{[}dir\mbox{]}} Sets/gets the directory where the settings files are located (string) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries trimdir \mbox{[}dir\mbox{]}} obsolete {\ttfamily settingsdir} -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries caldir \mbox{[}dir\mbox{]}} Sets/gets the directory where the calibration files are located (string) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries trimen \mbox{[}n e0 e1...e(n-\/1)\mbox{]}} Sets/gets the number of energies n at which the detector has default trim file and their values in eV (int) -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries settings \mbox{[}s\mbox{]}} sets/gets the settings of the detector. Options: {\ttfamily standard}, {\ttfamily fast}, {\ttfamily highgain}, {\ttfamily dynamicgain}, {\ttfamily lowgain}, {\ttfamily mediumgain}, {\ttfamily veryhighgain}, {\ttfamily lownoise}, {\ttfamily dynamichg0}, {\ttfamily fixgain1}, {\ttfamily fixgain2}, {\ttfamily forceswitchg1}, {\ttfamily forceswitchg2}. \par - In Eiger, only sets in client shared memory. Use {\ttfamily threshold} or {\ttfamily thresholdnotb} to pass to detector. Gets from detector. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries threshold \mbox{[}eV\mbox{]} \mbox{[}sett\mbox{]} } sets/gets the detector threshold in eV. sett is optional and if provided also sets the settings. Use this for Eiger instead of {\ttfamily settings}. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries thresholdnotb \mbox{[}eV\mbox{]} \mbox{[}sett\mbox{]} } sets/gets the detector threshold in eV without loading trimbits. sett is optional and if provided also sets the settings. Use this for Eiger instead of {\ttfamily settings}. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries trimbits \mbox{[}fname\mbox{]} } loads/stores the trimbits to/from the detector. If no extension is specified, the serial number of each module will be attached. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries trim:\mbox{[}mode\mbox{]} \mbox{[}fname\mbox{]}} trims the detector according to mode and saves resulting trimbits to file. Mode: noise, beam, improve, fix. Used in MYTHEN only. Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries trimval \mbox{[}i\mbox{]}} sets all trimbits to i. Used in EIGER only. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries pedestal \mbox{[}i\mbox{]}} starts acquisition for i frames, calculates pedestal and writes back to fpga. Used in GOTTHARD only. Only put! -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorClientDocs/latex/test.tex b/slsDetectorSoftware/slsDetectorClientDocs/latex/test.tex deleted file mode 100644 index 887052aa3..000000000 --- a/slsDetectorSoftware/slsDetectorClientDocs/latex/test.tex +++ /dev/null @@ -1,64 +0,0 @@ -Commands to be used only for software debugging. Avoid using them! -\begin{DoxyItemize} -\item {\bfseries test} returns an error -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries help} Returns a list of possible commands. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries exitserver} Shuts down all the detector servers. Don't use it!!!! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries exitreceiver} Shuts down all the receivers. Don't use it!!!! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries flippeddatay \mbox{[}i\mbox{]}} enables/disables data being flipped across y axis. 1 enables, 0 disables. Not implemented. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries digitest \mbox{[}i\mbox{]}} will perform test which will plot the unique channel identifier, instead of data. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries bustest} performs test of the bus interface between FPGA and embedded Linux system. Can last up to a few minutes. Cannot set! Used for Mythen only. Only get! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries digibittest:\mbox{[}i\mbox{]}} performs digital test of the module i. Returns 0 if succeeded, otherwise error mask. Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries reg \mbox{[}addr\mbox{]} \mbox{[}val\mbox{]}} ??? writes to an register {\ttfamily addr} with {\ttfamily value} in hexadecimal format. -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries adcreg \mbox{[}addr\mbox{]} \mbox{[}val\mbox{]}} ??? writes to an adc register {\ttfamily addr} with {\ttfamily value} in hexadecimal format. Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries setbit} ??? Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries clearbit } ??? Only put! -\end{DoxyItemize} - - -\begin{DoxyItemize} -\item {\bfseries getbit } ??? Only get! -\end{DoxyItemize} \ No newline at end of file diff --git a/slsDetectorSoftware/slsDetectorServer/slsDetectorFunctionList.h b/slsDetectorSoftware/slsDetectorServer/slsDetectorFunctionList.h index 145af32fa..648dbb448 100644 --- a/slsDetectorSoftware/slsDetectorServer/slsDetectorFunctionList.h +++ b/slsDetectorSoftware/slsDetectorServer/slsDetectorFunctionList.h @@ -202,6 +202,9 @@ int setNetworkParameter(enum NETWORKINDEX mode, int value); int prepareAcquisition(); #endif int startStateMachine(); +#ifdef VIRTUAL +void* start_timer(void* arg); +#endif int stopStateMachine(); #ifndef JUNGFRAUD int startReadOut(); diff --git a/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c b/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c index 7e7ef4e65..cd96a92b7 100755 --- a/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c +++ b/slsDetectorSoftware/slsDetectorServer/slsDetectorServer_funcs.c @@ -57,6 +57,7 @@ void init_detector(int controlserver) { #ifdef VIRTUAL printf("This is a VIRTUAL detector\n"); #endif + #ifdef SLS_DETECTOR_FUNCTION_LIST if (controlserver) initControlServer(); @@ -2626,7 +2627,7 @@ int get_time_left(int file_des) { case FRAMES_FROM_START: case FRAMES_FROM_START_PG: #endif - getTimeLeft(ind); + retval=getTimeLeft(ind); break; default: ret = FAIL; @@ -3412,9 +3413,17 @@ int configure_mac(int file_des) { uint32_t udpport2; uint32_t detipad; sscanf(arg[0], "%x", &ipad); +#ifdef VIRTUAL + sscanf(arg[1], "%lx", &imacadd); +#else sscanf(arg[1], "%llx", &imacadd); +#endif sscanf(arg[2], "%x", &udpport); +#ifdef VIRTUAL + sscanf(arg[3], "%lx", &idetectormacadd); +#else sscanf(arg[3], "%llx", &idetectormacadd); +#endif sscanf(arg[4], "%x", &detipad); sscanf(arg[5], "%x", &udpport2); @@ -4295,7 +4304,7 @@ int set_rate_correct(int file_des) { } #ifdef SLS_DETECTOR_FUNCTION_LIST else { - printf("Setting rate correction to %lld ns\n",tau_ns); + printf("Setting rate correction to %lld ns\n",(long long int)tau_ns); //set rate //wrong bit mode if((setDynamicRange(-1)!=32) && (setDynamicRange(-1)!=16) && (tau_ns!=0)){ diff --git a/slsDetectorSoftware/slsDetectorUsers.doxy b/slsDetectorSoftware/slsDetectorUsers.doxy deleted file mode 100644 index 6f3674742..000000000 --- a/slsDetectorSoftware/slsDetectorUsers.doxy +++ /dev/null @@ -1,86 +0,0 @@ -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. -# Private class members and static file members will be hidden unless -# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES - -EXTRACT_ALL = YES - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class -# will be included in the documentation. - -EXTRACT_PRIVATE = NO - - - -# If the EXTRACT_STATIC tag is set to YES all static members of a file -# will be included in the documentation. - -EXTRACT_STATIC = YES - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) -# defined locally in source files will be included in the documentation. -# If set to NO only classes defined in header files are included. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local -# methods, which are defined in the implementation section but not in -# the interface are included in the documentation. -# If set to NO (the default) only methods in the interface are included. - -EXTRACT_LOCAL_METHODS = YES - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base -# name of the file that contains the anonymous namespace. By default -# anonymous namespace are hidden. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all -# undocumented members of documented classes, files or namespaces. -# If set to NO (the default) these members will be included in the -# various overviews, but no documentation section is generated. -# This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. -# If set to NO (the default) these classes will be included in the various -# overviews. This option has no effect if EXTRACT_ALL is enabled. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all -# friend (class|struct|union) declarations. -# If set to NO (the default) these declarations will be included in the -# documentation. - -HIDE_FRIEND_COMPOUNDS = NO - -INTERNAL_DOCS = NO - -SHOW_INCLUDE_FILES = NO - -SHOW_FILES = NO - -SHOW_NAMESPACES = NO - -COMPACT_LATEX = YES - -PAPER_TYPE = a4 - -PDF_HYPERLINKS = YES - -USE_PDFLATEX = YES - -LATEX_HIDE_INDICES = YES - - -PREDEFINED = __cplusplus - -INPUT = slsDetector/slsDetectorUsers.h slsDetectorAnalysis/detectorData.h - -OUTPUT_DIRECTORY = slsDetectorUsersDocs