after merging with developer

This commit is contained in:
2018-11-02 10:48:06 +01:00
134 changed files with 4245 additions and 4058 deletions

File diff suppressed because it is too large Load Diff

View File

@ -491,7 +491,7 @@ public:
* @param pos position in the multi list
* @returns slsDetector object
*/
slsDetector *operator()(int pos);
slsDetector *operator()(int pos) const;
/**
* Free shared memory from the command line
@ -945,6 +945,12 @@ public:
*/
int stopAcquisition();
/**
* Give an internal software trigger to the detector (Eiger only)
* @return OK or FAIL
*/
int sendSoftwareTrigger();
/**
* Start readout (without exposure or interrupting exposure) (Mythen)
* @returns OK or FAIL
@ -1042,9 +1048,10 @@ public:
* Set/get timer value left in acquisition (not all implemented for all detectors)
* @param index timer index
* @param t time in ns or number of...(e.g. frames, gates, probes)
* @param imod module number
* @returns timer set value in ns or number of...(e.g. frames, gates, probes)
*/
int64_t getTimeLeft(timerIndex index);
int64_t getTimeLeft(timerIndex index, int imod = -1);
/**
* Set speed
@ -1235,11 +1242,18 @@ public:
int writeAdcRegister(int addr, int val);
/**
* Activates the detector (Eiger only)
* Activates/Deactivates the detector (Eiger only)
* @param enable active (1) or inactive (0), -1 gets
* @returns 0 (inactive) or 1 (active)
* @returns 0 (inactive) or 1 (active)for activate mode
*/
int activate(int const enable=GET_ONLINE_FLAG);
int activate(int const enable=-1);
/**
* Set deactivated Receiver padding mode (Eiger only)
* @param padding padding option for deactivated receiver. Can be 1 (padding), 0 (no padding), -1 (gets)
* @returns 1 (padding), 0 (no padding), -1 (inconsistent values) for padding option
*/
int setDeactivatedRxrPaddingMode(int padding=-1);
/**
* Returns the enable if data will be flipped across x or y axis (Eiger)

View File

@ -4,7 +4,7 @@
#include "multiSlsDetector.h"
#include "multiSlsDetectorCommand.h"
#include "sls_detector_exceptions.h"
#include "sls_receiver_exceptions.h"
#include <stdlib.h>
@ -19,7 +19,7 @@ class multiSlsDetectorClient {
public:
multiSlsDetectorClient(int argc, char *argv[], int action, multiSlsDetector *myDetector=NULL) { \
string answer; \
std::string answer; \
multiSlsDetectorCommand *myCmd; \
int id = -1, pos = -1, iv = 0; \
bool verify = true, update = true; \
@ -90,7 +90,7 @@ public:
strcpy(cmd, argv[0]); \
} \
// special commands
string scmd = cmd; \
std::string scmd = cmd; \
// free without calling multiSlsDetector constructor
if (scmd == "free") { \
if (pos != -1) \
@ -113,9 +113,10 @@ public:
// create multiSlsDetector class if required
if (myDetector==NULL) { \
try { \
myDetector = new multiSlsDetector(id, verify, update); \
} catch (const SharedMemoryException & e) { \
cout << e.GetMessage() << endl; \
multiSlsDetector* m = new multiSlsDetector(id, verify, update); \
myDetector = m; \
} catch (const SlsDetectorPackageExceptions & e) { \
/*cout << e.GetMessage() << endl;*/ \
return; \
} catch (...) { \
cout << " caught exception" << endl; \
@ -128,8 +129,8 @@ public:
myCmd=new multiSlsDetectorCommand(myDetector); \
try { \
answer=myCmd->executeLine(argc, argv, action, pos); \
} catch (const SharedMemoryException & e) { \
cout << e.GetMessage() << endl; \
} catch (const SlsDetectorPackageExceptions & e) { \
/*cout << e.GetMessage() << endl; */ \
delete myCmd; \
if (del) delete myDetector; \
return; \

View File

@ -28,8 +28,8 @@ class multiSlsDetectorCommand : public slsDetectorCommand {
/* \returns answer string */
/* *\/ */
string executeLine(int narg, char *args[], int action, int id=-1) { \
string s; \
std::string executeLine(int narg, char *args[], int action, int id=-1) { \
std::string s; \
if (id>=0) {
slsDetector *d=myDet->getSlsDetector(id); \
if (d) { \
@ -39,7 +39,7 @@ class multiSlsDetectorCommand : public slsDetectorCommand {
myDet->setErrorMask((myDet->getErrorMask())|(1<<id)); \
delete cmd;
} else
s=string("detector does no exist"); \
s=std::string("detector does no exist"); \
} else \
s=slsDetectorCommand::executeLine(narg,args,action); \
return s;
@ -48,13 +48,13 @@ class multiSlsDetectorCommand : public slsDetectorCommand {
/**
* calls executeLine with PUT_ACTION
*/
string putCommand(int narg, char *args[], int pos=-1){\
std::string putCommand(int narg, char *args[], int pos=-1){\
return executeLine(narg, args,slsDetectorDefs::PUT_ACTION,pos);\
};
/**
* calls executeLine with GET_ACTION
*/
string getCommand(int narg, char *args[], int pos=-1){\
std::string getCommand(int narg, char *args[], int pos=-1){\
return executeLine(narg, args,slsDetectorDefs::GET_ACTION,pos);\
};