merge from mythen3, and jungfrau fix

This commit is contained in:
2020-01-23 16:44:01 +01:00
36 changed files with 478 additions and 399 deletions

View File

@ -204,11 +204,13 @@ inline std::string ToString(const defs::detectorModeType s) {
}
}
inline std::string ToString(const defs::burstModeType s) {
inline std::string ToString(const defs::burstMode s) {
switch (s) {
case defs::INTERNAL:
case defs::BURST_OFF:
return std::string("off");
case defs::BURST_INTERNAL:
return std::string("internal");
case defs::EXTERNAL:
case defs::BURST_EXTERNAL:
return std::string("external");
default:
return std::string("Unknown");
@ -562,12 +564,14 @@ inline defs::dacIndex StringTo(const std::string& s) {
}
template <>
inline defs::burstModeType StringTo(const std::string& s) {
inline defs::burstMode StringTo(const std::string& s) {
if (s == "off")
return defs::BURST_OFF;
if (s == "internal")
return defs::INTERNAL;
return defs::BURST_INTERNAL;
if (s == "external")
return defs::EXTERNAL;
throw sls::RuntimeError("Unknown burst mode type" + s);
return defs::BURST_EXTERNAL;
throw sls::RuntimeError("Unknown burst mode " + s);
}

View File

@ -317,7 +317,7 @@ class slsDetectorDefs {
VB_COMP_FE,
VB_COMP_ADC,
VCOM_CDS,
VREF_RESTORE,
VREF_RSTORE,
VB_OPA_1ST,
VREF_COMP_FE,
VCOM_ADC1,
@ -439,11 +439,12 @@ class slsDetectorDefs {
};
/**
* burst mode type for gotthard2
* burst mode for gotthard2
*/
enum burstModeType {
INTERNAL,
EXTERNAL,
enum burstMode {
BURST_OFF,
BURST_INTERNAL,
BURST_EXTERNAL,
};

View File

@ -188,8 +188,6 @@ enum detFuncs{
F_GET_ADC_ENABLE_MASK_10G,
F_SET_COUNTER_MASK,
F_GET_COUNTER_MASK,
F_SET_BURST_TYPE,
F_GET_BURST_TYPE,
NUM_DET_FUNCTIONS,
RECEIVER_ENUM_START = 256, /**< detector function should not exceed this (detector server should not compile anyway) */
@ -445,8 +443,6 @@ static const char* getFunctionNameFromEnum(enum detFuncs func) {
case F_GET_ADC_ENABLE_MASK_10G: return "F_GET_ADC_ENABLE_MASK_10G";
case F_SET_COUNTER_MASK: return "F_SET_COUNTER_MASK";
case F_GET_COUNTER_MASK: return "F_GET_COUNTER_MASK";
case F_SET_BURST_TYPE: return "F_SET_BURST_TYPE";
case F_GET_BURST_TYPE: return "F_GET_BURST_TYPE";
case NUM_DET_FUNCTIONS: return "NUM_DET_FUNCTIONS";
case RECEIVER_ENUM_START: return "RECEIVER_ENUM_START";

View File

@ -6,7 +6,7 @@
#define APIMOENCH 0x190820
#define APICTB 0x200122
#define APIGOTTHARD 0x200122
#define APIGOTTHARD2 0x200122
#define APIEIGER 0x200122
#define APIMYTHEN3 0x200122
#define APIGOTTHARD2 0x200123
#define APIJUNGFRAU 0x200123