From 71489b7106e01d3e1c9f3d879c2c90ddb49d2dda Mon Sep 17 00:00:00 2001 From: Dhanya Thattil Date: Tue, 18 Jul 2023 15:51:22 +0200 Subject: [PATCH] 2. Set row col (#779) * set row and column --- python/slsdet/detector.py | 24 ++++ python/src/detector.cpp | 16 +++ .../slsDetectorFunctionList.c | 4 +- .../slsDetectorFunctionList.c | 3 +- .../include/slsDetectorServer_funcs.h | 10 +- .../src/slsDetectorServer_funcs.c | 131 +++++++++++++++++- slsDetectorSoftware/include/sls/Detector.h | 10 ++ slsDetectorSoftware/src/CmdProxy.h | 11 ++ slsDetectorSoftware/src/Detector.cpp | 16 +++ slsDetectorSoftware/src/Module.cpp | 18 +++ slsDetectorSoftware/src/Module.h | 4 + slsDetectorSoftware/tests/test-CmdProxy.cpp | 46 ++++++ slsReceiverSoftware/src/ClientInterface.cpp | 25 ++++ slsReceiverSoftware/src/ClientInterface.h | 2 + slsReceiverSoftware/src/DataProcessor.cpp | 8 +- slsReceiverSoftware/src/Implementation.cpp | 14 ++ slsReceiverSoftware/src/Implementation.h | 2 + slsReceiverSoftware/src/Listener.cpp | 4 + slsReceiverSoftware/src/Listener.h | 1 + .../include/sls/sls_detector_funcs.h | 13 ++ slsSupportLib/include/sls/versionAPI.h | 2 +- 21 files changed, 354 insertions(+), 10 deletions(-) diff --git a/python/slsdet/detector.py b/python/slsdet/detector.py index a337bdb09..2cbd5266d 100755 --- a/python/slsdet/detector.py +++ b/python/slsdet/detector.py @@ -1682,6 +1682,30 @@ class Detector(CppDetectorApi): def badchannels(self, value): ut.set_using_dict(self.setBadChannels, value) + @property + @element + def row(self): + """ + Set Detector row (udp header) to value. Gui uses it to rearrange for complete image. + """ + return self.getRow() + + @row.setter + def row(self, value): + ut.set_using_dict(self.setRow, value) + + @property + @element + def column(self): + """ + Set Detector column (udp header) to value. Gui uses it to rearrange for complete image. + """ + return self.getColumn() + + @column.setter + def column(self, value): + ut.set_using_dict(self.setColumn, value) + @property @element def lock(self): diff --git a/python/src/detector.cpp b/python/src/detector.cpp index 05f20e694..81206da20 100644 --- a/python/src/detector.cpp +++ b/python/src/detector.cpp @@ -239,6 +239,22 @@ void init_det(py::module &m) { (void (Detector::*)(const std::vector>)) & Detector::setBadChannels, py::arg()); + CppDetectorApi.def("getRow", + (Result(Detector::*)(sls::Positions) const) & + Detector::getRow, + py::arg() = Positions{}); + CppDetectorApi.def("setRow", + (void (Detector::*)(const int, sls::Positions)) & + Detector::setRow, + py::arg(), py::arg() = Positions{}); + CppDetectorApi.def("getColumn", + (Result(Detector::*)(sls::Positions) const) & + Detector::getColumn, + py::arg() = Positions{}); + CppDetectorApi.def("setColumn", + (void (Detector::*)(const int, sls::Positions)) & + Detector::setColumn, + py::arg(), py::arg() = Positions{}); CppDetectorApi.def("isVirtualDetectorServer", (Result(Detector::*)(sls::Positions) const) & Detector::isVirtualDetectorServer, diff --git a/slsDetectorServers/ctbDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/ctbDetectorServer/slsDetectorFunctionList.c index 6f62a474d..a1e9fa54c 100644 --- a/slsDetectorServers/ctbDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/ctbDetectorServer/slsDetectorFunctionList.c @@ -2605,8 +2605,8 @@ int readSample(int ns) { // if channel is in enable mask if ((1 << ich) & (transceiverMask)) { - int offset = FIFO_TIN_STATUS_FIFO_EMPTY_1_OFST + ich; - uint32_t mask = (1 << offset); + // int offset = FIFO_TIN_STATUS_FIFO_EMPTY_1_OFST + ich; + // uint32_t mask = (1 << offset); // int empty = ((bus_r(tStatusAddr) & mask) >> offset); // if fifo not empty diff --git a/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c index 4d3c5e997..02c59eacf 100644 --- a/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/moenchDetectorServer/slsDetectorFunctionList.c @@ -1485,7 +1485,8 @@ int setReadoutSpeed(int val) { return FAIL; } if (isHardwareVersion_1_0()) { - LOG(logERROR, ("Cannot set full speed. Not implemented for this pcb version (1.0)\n")); + LOG(logERROR, ("Cannot set full speed. Not implemented for this pcb " + "version (1.0)\n")); return FAIL; } diff --git a/slsDetectorServers/slsDetectorServer/include/slsDetectorServer_funcs.h b/slsDetectorServers/slsDetectorServer/include/slsDetectorServer_funcs.h index 0fc333668..fcb819060 100644 --- a/slsDetectorServers/slsDetectorServer/include/slsDetectorServer_funcs.h +++ b/slsDetectorServers/slsDetectorServer/include/slsDetectorServer_funcs.h @@ -318,4 +318,12 @@ int clear_bit(int); int get_num_transceiver_samples(int); int set_num_transceiver_samples(int); int get_transceiver_enable(int); -int set_transceiver_enable(int); \ No newline at end of file +int set_transceiver_enable(int); +int get_row(int); +int set_row(int); +int get_column(int); +int set_column(int); +int getRow(); +int setRow(int); +int getColumn(); +int setColumn(int); diff --git a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c index 2235b3cae..d461224c5 100644 --- a/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c +++ b/slsDetectorServers/slsDetectorServer/src/slsDetectorServer_funcs.c @@ -482,6 +482,11 @@ void function_table() { flist[F_SET_NUM_TRANSCEIVER_SAMPLES] = &set_num_transceiver_samples; flist[F_GET_TRANSCEIVER_ENABLE_MASK] = &get_transceiver_enable; flist[F_SET_TRANSCEIVER_ENABLE_MASK] = &set_transceiver_enable; + flist[F_GET_ROW] = &get_row; + flist[F_SET_ROW] = &set_row; + flist[F_GET_COLUMN] = &get_column; + flist[F_SET_COLUMN] = &set_column; + // check if (NUM_DET_FUNCTIONS >= RECEIVER_ENUM_START) { LOG(logERROR, ("The last detector function enum has reached its " @@ -5954,7 +5959,7 @@ int get_clock_phase(int file_des) { if (receiveData(file_des, args, sizeof(args), INT32) < 0) return printSocketReadError(); LOG(logDEBUG1, ("Getting clock (%d) phase %s \n", args[0], - (args[1] == 0 ? "" : "in degrees"))); + (args[1] == 0 ? "" : "in degrees"))); #if !defined(CHIPTESTBOARDD) && !defined(JUNGFRAUD) && !defined(MOENCHD) && \ !defined(GOTTHARD2D) && !defined(MYTHEN3D) @@ -10581,4 +10586,128 @@ int get_transceiver_enable(int file_des) { LOG(logDEBUG1, ("Transceiver Enable Mask retval: %u\n", retval)); #endif return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); +} + +int get_row(int file_des) { + ret = OK; + memset(mess, 0, sizeof(mess)); + int retval = -1; + + LOG(logDEBUG1, ("Getting row\n")); + // get only + retval = getRow(); + LOG(logDEBUG1, ("row retval: %u\n", retval)); + + return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); +} + +int set_row(int file_des) { + ret = OK; + memset(mess, 0, sizeof(mess)); + int arg = 0; + + if (receiveData(file_des, &arg, sizeof(arg), INT32) < 0) + return printSocketReadError(); + LOG(logINFO, ("Setting row: %u\n", arg)); + + // only set + if (Server_VerifyLock() == OK) { + if (arg < 0) { + ret = FAIL; + sprintf( + mess, + "Could not set row. Invalid value %d. Must be greater than 0\n", + arg); + LOG(logERROR, (mess)); + } else { + ret = setRow(arg); + if (ret == FAIL) { + sprintf(mess, "Could not set row\n"); + LOG(logERROR, (mess)); + } else { + int retval = getRow(); + LOG(logDEBUG1, ("gain retval: %u\n", retval)); + validate(&ret, mess, arg, retval, "set row", DEC); + } + } + } + + return Server_SendResult(file_des, INT32, NULL, 0); +} + +int get_column(int file_des) { + ret = OK; + memset(mess, 0, sizeof(mess)); + int retval = -1; + + LOG(logDEBUG1, ("Getting column\n")); + // get only + retval = getColumn(); + LOG(logDEBUG1, ("column retval: %u\n", retval)); + + return Server_SendResult(file_des, INT32, &retval, sizeof(retval)); +} + +int set_column(int file_des) { + ret = OK; + memset(mess, 0, sizeof(mess)); + int arg = 0; + + if (receiveData(file_des, &arg, sizeof(arg), INT32) < 0) + return printSocketReadError(); + LOG(logINFO, ("Setting column: %u\n", arg)); + + // only set + if (Server_VerifyLock() == OK) { + if (arg < 0) { + ret = FAIL; + sprintf(mess, + "Could not set column. Invalid value %d. Must be greater " + "than 0\n", + arg); + LOG(logERROR, (mess)); + } else { + ret = setColumn(arg); + if (ret == FAIL) { + sprintf(mess, "Could not set column\n"); + LOG(logERROR, (mess)); + } else { + int retval = getColumn(); + LOG(logDEBUG1, ("gain retval: %u\n", retval)); + validate(&ret, mess, arg, retval, "set column", DEC); + } + } + } + + return Server_SendResult(file_des, INT32, NULL, 0); +} + +int getRow() { +#if defined(JUNGFRAUD) || defined(MOENCHD) + // inner (top) position (0, 1) might be incremented if 2 interfaces + return getDetectorPosition()[Y + 2]; +#endif + return getDetectorPosition()[Y]; +} + +int setRow(int value) { + int pos[2] = {0, 0}; + memcpy(pos, getDetectorPosition(), sizeof(pos)); + pos[Y] = value; + return setDetectorPosition(pos); +} + +int getColumn() { +#if defined(JUNGFRAUD) || defined(MOENCHD) + // inner (top) position (0, 1) might be incremented if 2 interfaces + return getDetectorPosition()[X + 2]; +#endif + return getDetectorPosition()[X]; +} + +int setColumn(int value) { + int pos[2] = {0, 0}; + memcpy(pos, getDetectorPosition(), sizeof(pos)); + pos[X] = value; + return setDetectorPosition(pos); } \ No newline at end of file diff --git a/slsDetectorSoftware/include/sls/Detector.h b/slsDetectorSoftware/include/sls/Detector.h index 78ecd6413..4dce32fb1 100644 --- a/slsDetectorSoftware/include/sls/Detector.h +++ b/slsDetectorSoftware/include/sls/Detector.h @@ -238,6 +238,16 @@ class Detector { * channel list. */ void setBadChannels(const std::vector> list); + Result getRow(Positions pos = {}) const; + + /** Set it in udp header. Gui uses it to rearrange for complete image */ + void setRow(const int value, Positions pos = {}); + + Result getColumn(Positions pos = {}) const; + + /** Set it in udp header. Gui uses it to rearrange for complete image */ + void setColumn(const int value, Positions pos = {}); + Result isVirtualDetectorServer(Positions pos = {}) const; ///@} diff --git a/slsDetectorSoftware/src/CmdProxy.h b/slsDetectorSoftware/src/CmdProxy.h index 12d871964..75df55ae6 100644 --- a/slsDetectorSoftware/src/CmdProxy.h +++ b/slsDetectorSoftware/src/CmdProxy.h @@ -992,6 +992,8 @@ class CmdProxy { {"master", &CmdProxy::master}, {"sync", &CmdProxy::sync}, {"badchannels", &CmdProxy::BadChannels}, + {"row", &CmdProxy::row}, + {"column", &CmdProxy::column}, /* acquisition parameters */ {"acquire", &CmdProxy::Acquire}, @@ -1542,6 +1544,15 @@ class CmdProxy { "[0, 1]\n\t[Jungfrau][Moench] Enables or disables " "synchronization between modules."); + INTEGER_COMMAND_VEC_ID(row, getRow, setRow, StringTo, + "[value]\n\tSet Detector row (udp header) to value. " + "\n\tGui uses it to rearrange for complete image"); + + INTEGER_COMMAND_VEC_ID( + column, getColumn, setColumn, StringTo, + "[value]\n\tSet Detector column (udp header) to value. \n\tGui uses it " + "to rearrange for complete image"); + /* acquisition parameters */ INTEGER_COMMAND_SET_NOID_GET_ID( diff --git a/slsDetectorSoftware/src/Detector.cpp b/slsDetectorSoftware/src/Detector.cpp index b094cd298..1c70a7326 100644 --- a/slsDetectorSoftware/src/Detector.cpp +++ b/slsDetectorSoftware/src/Detector.cpp @@ -379,6 +379,22 @@ void Detector::setBadChannels(const std::vector list, Positions pos) { pimpl->setBadChannels(list, pos); } +Result Detector::getRow(Positions pos) const { + return pimpl->Parallel(&Module::getRow, pos); +} + +void Detector::setRow(const int value, Positions pos) { + pimpl->Parallel(&Module::setRow, pos, value); +} + +Result Detector::getColumn(Positions pos) const { + return pimpl->Parallel(&Module::getColumn, pos); +} + +void Detector::setColumn(const int value, Positions pos) { + pimpl->Parallel(&Module::setColumn, pos, value); +} + Result Detector::isVirtualDetectorServer(Positions pos) const { return pimpl->Parallel(&Module::isVirtualDetectorServer, pos); } diff --git a/slsDetectorSoftware/src/Module.cpp b/slsDetectorSoftware/src/Module.cpp index 04d057d85..b7a42459d 100644 --- a/slsDetectorSoftware/src/Module.cpp +++ b/slsDetectorSoftware/src/Module.cpp @@ -589,6 +589,24 @@ void Module::setBadChannels(std::vector list) { } } +int Module::getRow() const { return sendToDetector(F_GET_ROW); } + +void Module::setRow(int value) { + sendToDetector(F_SET_ROW, value, nullptr); + if (shm()->useReceiverFlag) { + sendToReceiver(F_RECEIVER_SET_ROW, value, nullptr); + } +} + +int Module::getColumn() const { return sendToDetector(F_GET_COLUMN); } + +void Module::setColumn(int value) { + sendToDetector(F_SET_COLUMN, value, nullptr); + if (shm()->useReceiverFlag) { + sendToReceiver(F_RECEIVER_SET_COLUMN, value, nullptr); + } +} + bool Module::isVirtualDetectorServer() const { return sendToDetector(F_IS_VIRTUAL); } diff --git a/slsDetectorSoftware/src/Module.h b/slsDetectorSoftware/src/Module.h index 530a71137..6a15b91b1 100644 --- a/slsDetectorSoftware/src/Module.h +++ b/slsDetectorSoftware/src/Module.h @@ -134,6 +134,10 @@ class Module : public virtual slsDetectorDefs { void setSynchronization(const bool value); std::vector getBadChannels() const; void setBadChannels(std::vector list); + int getRow() const; + void setRow(const int value); + int getColumn() const; + void setColumn(const int value); bool isVirtualDetectorServer() const; diff --git a/slsDetectorSoftware/tests/test-CmdProxy.cpp b/slsDetectorSoftware/tests/test-CmdProxy.cpp index 1ef0546fb..afbea7f0a 100644 --- a/slsDetectorSoftware/tests/test-CmdProxy.cpp +++ b/slsDetectorSoftware/tests/test-CmdProxy.cpp @@ -715,6 +715,52 @@ TEST_CASE("badchannels", "[.cmd]") { } } +TEST_CASE("row", "[.cmd]") { + Detector det; + CmdProxy proxy(&det); + auto prev_val = det.getRow()[0]; + { + std::ostringstream oss; + proxy.Call("row", {"1"}, 0, PUT, oss); + REQUIRE(oss.str() == "row 1\n"); + } + { + std::ostringstream oss; + proxy.Call("row", {}, 0, GET, oss); + REQUIRE(oss.str() == "row 1\n"); + } + { + std::ostringstream oss; + proxy.Call("row", {"0"}, 0, PUT, oss); + REQUIRE(oss.str() == "row 0\n"); + } + REQUIRE_THROWS(proxy.Call("row", {"-5"}, -1, PUT)); + det.setRow(prev_val, {0}); +} + +TEST_CASE("column", "[.cmd]") { + Detector det; + CmdProxy proxy(&det); + auto prev_val = det.getColumn()[0]; + { + std::ostringstream oss; + proxy.Call("column", {"1"}, 0, PUT, oss); + REQUIRE(oss.str() == "column 1\n"); + } + { + std::ostringstream oss; + proxy.Call("column", {}, 0, GET, oss); + REQUIRE(oss.str() == "column 1\n"); + } + { + std::ostringstream oss; + proxy.Call("column", {"0"}, 0, PUT, oss); + REQUIRE(oss.str() == "column 0\n"); + } + REQUIRE_THROWS(proxy.Call("column", {"-5"}, -1, PUT)); + det.setColumn(prev_val, {0}); +} + /* acquisition parameters */ // acquire: not testing diff --git a/slsReceiverSoftware/src/ClientInterface.cpp b/slsReceiverSoftware/src/ClientInterface.cpp index 745297017..9f328ff68 100644 --- a/slsReceiverSoftware/src/ClientInterface.cpp +++ b/slsReceiverSoftware/src/ClientInterface.cpp @@ -222,6 +222,9 @@ int ClientInterface::functionTable(){ flist[F_RECEIVER_SET_RECEIVER_ROI_METADATA] = &ClientInterface::set_receiver_roi_metadata; flist[F_RECEIVER_SET_NUM_TRANSCEIVER_SAMPLES] = &ClientInterface::set_num_transceiver_samples; flist[F_RECEIVER_SET_TRANSCEIVER_MASK] = &ClientInterface::set_transceiver_mask; + flist[F_RECEIVER_SET_ROW] = &ClientInterface::set_row; + flist[F_RECEIVER_SET_COLUMN] = &ClientInterface::set_column; + for (int i = NUM_DET_FUNCTIONS + 1; i < NUM_REC_FUNCTIONS ; i++) { LOG(logDEBUG1) << "function fnum: " << i << " (" << @@ -1799,4 +1802,26 @@ int ClientInterface::set_transceiver_mask(Interface &socket) { return socket.sendResult(retval); } +int ClientInterface::set_row(Interface &socket) { + auto value = socket.Receive(); + if (value < 0) { + throw RuntimeError("Invalid row " + std::to_string(value)); + } + verifyIdle(socket); + LOG(logDEBUG1) << "Setting num rows to " << value; + impl()->setRow(value); + return socket.Send(OK); +} + +int ClientInterface::set_column(Interface &socket) { + auto value = socket.Receive(); + if (value < 0) { + throw RuntimeError("Invalid column " + std::to_string(value)); + } + verifyIdle(socket); + LOG(logDEBUG1) << "Setting column to " << value; + impl()->setColumn(value); + return socket.Send(OK); +} + } // namespace sls diff --git a/slsReceiverSoftware/src/ClientInterface.h b/slsReceiverSoftware/src/ClientInterface.h index 328cc1cd5..e9b496617 100644 --- a/slsReceiverSoftware/src/ClientInterface.h +++ b/slsReceiverSoftware/src/ClientInterface.h @@ -172,6 +172,8 @@ class ClientInterface : private virtual slsDetectorDefs { int set_receiver_roi_metadata(ServerInterface &socket); int set_num_transceiver_samples(ServerInterface &socket); int set_transceiver_mask(ServerInterface &socket); + int set_row(ServerInterface &socket); + int set_column(ServerInterface &socket); Implementation *impl() { if (receiver != nullptr) { diff --git a/slsReceiverSoftware/src/DataProcessor.cpp b/slsReceiverSoftware/src/DataProcessor.cpp index 33b7bf743..71acdb03f 100644 --- a/slsReceiverSoftware/src/DataProcessor.cpp +++ b/slsReceiverSoftware/src/DataProcessor.cpp @@ -550,10 +550,10 @@ void DataProcessor::RearrangeDbitData(size_t &size, char *data) { size = totalNumBytes * sizeof(uint8_t) + nAnalogDataBytes + ctbDbitOffset + nTransceiverDataBytes; LOG(logDEBUG1) << "totalNumBytes: " << totalNumBytes - << " nAnalogDataBytes:" << nAnalogDataBytes - << " ctbDbitOffset:" << ctbDbitOffset - << " nTransceiverDataBytes:" << nTransceiverDataBytes - << " size:" << size; + << " nAnalogDataBytes:" << nAnalogDataBytes + << " ctbDbitOffset:" << ctbDbitOffset + << " nTransceiverDataBytes:" << nTransceiverDataBytes + << " size:" << size; } void DataProcessor::CropImage(size_t &size, char *data) { diff --git a/slsReceiverSoftware/src/Implementation.cpp b/slsReceiverSoftware/src/Implementation.cpp index 5ce6bc2c4..197236e50 100644 --- a/slsReceiverSoftware/src/Implementation.cpp +++ b/slsReceiverSoftware/src/Implementation.cpp @@ -284,6 +284,20 @@ void Implementation::setModulePositionId(const int id) { } } +void Implementation::setRow(const int value) { + for (unsigned int i = 0; i < listener.size(); ++i) { + int col = listener[i]->GetHardCodedPosition().second; + listener[i]->SetHardCodedPosition(value, col); + } +} + +void Implementation::setColumn(const int value) { + for (unsigned int i = 0; i < listener.size(); ++i) { + int row = listener[i]->GetHardCodedPosition().first; + listener[i]->SetHardCodedPosition(row, value); + } +} + std::string Implementation::getDetectorHostname() const { return detHostname; } void Implementation::setDetectorHostname(const std::string &c) { diff --git a/slsReceiverSoftware/src/Implementation.h b/slsReceiverSoftware/src/Implementation.h index a43e68155..0aa5cc6fa 100644 --- a/slsReceiverSoftware/src/Implementation.h +++ b/slsReceiverSoftware/src/Implementation.h @@ -41,6 +41,8 @@ class Implementation : private virtual slsDetectorDefs { void setDetectorSize(const xy size); int getModulePositionId() const; void setModulePositionId(const int id); + void setRow(const int value); + void setColumn(const int value); std::string getDetectorHostname() const; void setDetectorHostname(const std::string &c); bool getSilentMode() const; diff --git a/slsReceiverSoftware/src/Listener.cpp b/slsReceiverSoftware/src/Listener.cpp index 14b387d36..ef2aa3736 100644 --- a/slsReceiverSoftware/src/Listener.cpp +++ b/slsReceiverSoftware/src/Listener.cpp @@ -251,6 +251,10 @@ void Listener::SetHardCodedPosition(uint16_t r, uint16_t c) { << "] (row: " << row << ", col: " << column << ")"; } +std::pair Listener::GetHardCodedPosition() { + return std::make_pair(row, column); +} + void Listener::ThreadExecution() { char *buffer; fifo->GetNewAddress(buffer); diff --git a/slsReceiverSoftware/src/Listener.h b/slsReceiverSoftware/src/Listener.h index 5b50e53f6..fd1f8e00a 100644 --- a/slsReceiverSoftware/src/Listener.h +++ b/slsReceiverSoftware/src/Listener.h @@ -61,6 +61,7 @@ class Listener : private virtual slsDetectorDefs, public ThreadObject { * packets/deactivated) c when used is in 2d */ void SetHardCodedPosition(uint16_t r, uint16_t c); + std::pair GetHardCodedPosition(); private: void RecordFirstIndex(uint64_t fnum); diff --git a/slsSupportLib/include/sls/sls_detector_funcs.h b/slsSupportLib/include/sls/sls_detector_funcs.h index 3020a6ba5..d9005d08e 100755 --- a/slsSupportLib/include/sls/sls_detector_funcs.h +++ b/slsSupportLib/include/sls/sls_detector_funcs.h @@ -286,6 +286,10 @@ enum detFuncs { F_SET_NUM_TRANSCEIVER_SAMPLES, F_GET_TRANSCEIVER_ENABLE_MASK, F_SET_TRANSCEIVER_ENABLE_MASK, + F_GET_ROW, + F_SET_ROW, + F_GET_COLUMN, + F_SET_COLUMN, NUM_DET_FUNCTIONS, RECEIVER_ENUM_START = 512, /**< detector function should not exceed this @@ -395,6 +399,8 @@ enum detFuncs { F_RECEIVER_SET_RECEIVER_ROI_METADATA, F_RECEIVER_SET_NUM_TRANSCEIVER_SAMPLES, F_RECEIVER_SET_TRANSCEIVER_MASK, + F_RECEIVER_SET_ROW, + F_RECEIVER_SET_COLUMN, NUM_REC_FUNCTIONS }; @@ -677,6 +683,10 @@ const char* getFunctionNameFromEnum(enum detFuncs func) { case F_SET_NUM_TRANSCEIVER_SAMPLES: return "F_SET_NUM_TRANSCEIVER_SAMPLES"; case F_GET_TRANSCEIVER_ENABLE_MASK: return "F_GET_TRANSCEIVER_ENABLE_MASK"; case F_SET_TRANSCEIVER_ENABLE_MASK: return "F_SET_TRANSCEIVER_ENABLE_MASK"; + case F_GET_ROW: return "F_GET_ROW"; + case F_SET_ROW: return "F_SET_ROW"; + case F_GET_COLUMN: return "F_GET_COLUMN"; + case F_SET_COLUMN: return "F_SET_COLUMN"; case NUM_DET_FUNCTIONS: return "NUM_DET_FUNCTIONS"; case RECEIVER_ENUM_START: return "RECEIVER_ENUM_START"; @@ -786,6 +796,9 @@ const char* getFunctionNameFromEnum(enum detFuncs func) { case F_RECEIVER_SET_RECEIVER_ROI_METADATA: return "F_RECEIVER_SET_RECEIVER_ROI_METADATA"; case F_RECEIVER_SET_NUM_TRANSCEIVER_SAMPLES: return "F_RECEIVER_SET_NUM_TRANSCEIVER_SAMPLES"; case F_RECEIVER_SET_TRANSCEIVER_MASK: return "F_RECEIVER_SET_TRANSCEIVER_MASK"; + case F_RECEIVER_SET_ROW: return "F_RECEIVER_SET_ROW"; + case F_RECEIVER_SET_COLUMN: return "F_RECEIVER_SET_COLUMN"; + case NUM_REC_FUNCTIONS: return "NUM_REC_FUNCTIONS"; default: return "Unknown Function"; diff --git a/slsSupportLib/include/sls/versionAPI.h b/slsSupportLib/include/sls/versionAPI.h index 02b21b16d..a05353cc4 100644 --- a/slsSupportLib/include/sls/versionAPI.h +++ b/slsSupportLib/include/sls/versionAPI.h @@ -10,4 +10,4 @@ #define APIJUNGFRAU "developer 0x230615" #define APICTB "developer 0x230629" #define APIMYTHEN3 "developer 0x230621" -#define APIMOENCH "developer 0x230707" +#define APIMOENCH "developer 0x230707"