Merge branch 'apidhanya' of github.com:slsdetectorgroup/slsDetectorPackage into apidhanya

This commit is contained in:
Erik Frojdh
2019-08-08 15:51:29 +02:00
6 changed files with 301 additions and 209 deletions

View File

@@ -252,6 +252,51 @@ class Detector {
*/
void setMaxNumberOfChannels(const defs::coordinates value);
/**
* Get Detector offset from shared memory (Gotthard only)
* @param pos detector position
* @returns offset in both dimensions
*/
Result<defs::coordinates> getDetectorOffsets(Positions pos = {}) const;
/**
* Set Detector offset in shared memory for each module
* @param value offset for detector in both dimensions
* @param pos detector position
*/
void setDetectorOffsets(defs::coordinates value, Positions pos = {});
/**
* Get Quad Type (Only for Eiger Quad detector hardware)
* @param pos detector position
* @returns quad type
*/
Result<bool> getQuad(Positions pos = {}) const;
/**
* Set Quad Type (Only for Eiger Quad detector hardware)
* @param enable true if quad type set, else false
* @param pos detector position
*/
void setQuad(const bool enable, Positions pos = {});
/**
* Get number of rows to read out (Only for Eiger)
* @param pos detector position
* @returns number of lines
*/
Result<int> getReadNLines(Positions pos = {}) const;
/**
* Set number of rows to read out (Only for Eiger)
* @param value number of lines
* @param pos detector position
*/
void setReadNLines(const int value, Positions pos = {});
// Erik
Result<int> getFramesCaughtByReceiver(Positions pos = {}) const;
@@ -334,7 +379,7 @@ class Detector {
* @param start start address for level 0-2
* @param stop stop address for level 0-2
* @param n number of loops for level 0-2
* @param detPos -1 for all detectors in list or specific detector position
* @param pos detector position
*/
void setPatternLoops(int level, int start, int stop, int n,
Positions pos = {});

View File

@@ -475,34 +475,6 @@ class multiSlsDetector : public virtual slsDetectorDefs {
*/
void setMaxNumberOfChannels(const slsDetectorDefs::coordinates c); //
/**
* Get Quad Type (Only for Eiger Quad detector hardware)
* @param detPos -1 for all detectors in list or specific detector position
* @returns quad type
*/
int getQuad(int detPos = -1);
/**
* Set Quad Type (Only for Eiger Quad detector hardware)
* @param enable true if quad type set, else false
* @param detPos -1 for all detectors in list or specific detector position
*/
void setQuad(const bool enable, int detPos = -1);
/**
* Set number of rows to read out (Only for Eiger)
* @param value number of lines
* @param detPos -1 for all detectors in list or specific detector position
*/
void setReadNLines(const int value, int detPos = -1);
/**
* Get number of rows to read out (Only for Eiger)
* @param detPos -1 for all detectors in list or specific detector position
* @returns number of lines
*/
int getReadNLines(int detPos = -1);
/**
* Get Detector offset from shared memory in dimension d
* @param d dimension d
@@ -510,7 +482,7 @@ class multiSlsDetector : public virtual slsDetectorDefs {
* @returns offset in dimension d, -1 if pos is not an actual position in
* list
*/
int getDetectorOffset(dimension d, int detPos = -1);
int getDetectorOffset(dimension d, int detPos = -1); //
/**
* Set Detector offset in shared memory in dimension d
@@ -518,13 +490,35 @@ class multiSlsDetector : public virtual slsDetectorDefs {
* @param off offset for detector
* @param detPos -1 for all detectors in list or specific detector position
*/
void setDetectorOffset(dimension d, int off, int detPos = -1);
void setDetectorOffset(dimension d, int off, int detPos = -1);//
/**
* Updates the channel offsets in X and Y dimension for all the sls
* detectors It is required for decodeNMod and setting ROI
* Get Quad Type (Only for Eiger Quad detector hardware)
* @param detPos -1 for all detectors in list or specific detector position
* @returns quad type
*/
void updateOffsets();
int getQuad(int detPos = -1);//
/**
* Set Quad Type (Only for Eiger Quad detector hardware)
* @param enable true if quad type set, else false
* @param detPos -1 for all detectors in list or specific detector position
*/
void setQuad(const bool enable, int detPos = -1);//
/**
* Set number of rows to read out (Only for Eiger)
* @param value number of lines
* @param detPos -1 for all detectors in list or specific detector position
*/
void setReadNLines(const int value, int detPos = -1);//
/**
* Get number of rows to read out (Only for Eiger)
* @param detPos -1 for all detectors in list or specific detector position
* @returns number of lines
*/
int getReadNLines(int detPos = -1);//
/**
* Checks if each of the detectors are online/offline
@@ -2302,6 +2296,12 @@ class multiSlsDetector : public virtual slsDetectorDefs {
*/
int decodeNChannel(int offsetX, int offsetY, int &channelX, int &channelY);
/**
* Updates the channel offsets in X and Y dimension for all the sls
* detectors It is required for decodeNMod and setting ROI
*/
void updateOffsets();
/**
* Execute in command line and return result
* @param cmd command

View File

@@ -403,7 +403,7 @@ class slsDetector : public virtual slsDetectorDefs {
* Get Quad Type (Only for Eiger Quad detector hardware)
* @returns quad type
*/
int getQuad();
bool getQuad();
/**
* Set Quad Type (Only for Eiger Quad detector hardware)
@@ -430,12 +430,24 @@ class slsDetector : public virtual slsDetectorDefs {
*/
int getDetectorOffset(dimension d) const;
/**
* Get Detector offset from shared memory in dimension d
* @returns offset
*/
slsDetectorDefs::coordinates getDetectorOffsets() const;
/**
* Set Detector offset in shared memory in dimension d
* @param d dimension d
* @param off offset for detector
*/
void setDetectorOffset(dimension d, int off);
/**
* Set Detector offset in shared memory
* @param value offset for detector
*/
void setDetectorOffsets(slsDetectorDefs::coordinates value);
/**
* Set Detector offset in shared memory in dimension d