mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-01-16 14:39:00 +01:00
merge fix
This commit is contained in:
@@ -1215,12 +1215,7 @@ int Module::getReceiverPort() const { return shm()->rxTCPPort; }
|
||||
|
||||
int Module::setReceiverPort(int port_number) {
|
||||
if (port_number >= 0 && port_number != shm()->rxTCPPort) {
|
||||
if (shm()->useReceiverFlag) {
|
||||
shm()->rxTCPPort =
|
||||
sendToReceiver<int>(F_SET_RECEIVER_PORT, port_number);
|
||||
} else {
|
||||
shm()->rxTCPPort = port_number;
|
||||
}
|
||||
shm()->rxTCPPort = port_number;
|
||||
}
|
||||
return shm()->rxTCPPort;
|
||||
}
|
||||
@@ -2558,21 +2553,13 @@ void Module::setADCInvert(uint32_t value) {
|
||||
int Module::getControlPort() const { return shm()->controlPort; }
|
||||
|
||||
void Module::setControlPort(int port_number) {
|
||||
if (strlen(shm()->hostname) > 0) {
|
||||
shm()->controlPort = sendToDetector<int>(F_SET_PORT, port_number);
|
||||
} else {
|
||||
shm()->controlPort = port_number;
|
||||
}
|
||||
shm()->controlPort = port_number;
|
||||
}
|
||||
|
||||
int Module::getStopPort() const { return shm()->stopPort; }
|
||||
|
||||
void Module::setStopPort(int port_number) {
|
||||
if (strlen(shm()->hostname) > 0) {
|
||||
shm()->stopPort = sendToDetectorStop<int>(F_SET_PORT, port_number);
|
||||
} else {
|
||||
shm()->stopPort = port_number;
|
||||
}
|
||||
shm()->stopPort = port_number;
|
||||
}
|
||||
|
||||
bool Module::getLockDetector() const {
|
||||
|
||||
@@ -190,7 +190,6 @@ TEST_CASE("rx_tcpport", "[.cmd][.rx]") {
|
||||
proxy.Call("rx_tcpport", {}, i, GET, oss);
|
||||
REQUIRE(oss.str() == "rx_tcpport " + std::to_string(port + i) + '\n');
|
||||
}
|
||||
REQUIRE_THROWS(proxy.Call("rx_tcpport", {"15"}, -1, PUT));
|
||||
port = 5754;
|
||||
proxy.Call("rx_tcpport", {std::to_string(port)}, -1, PUT);
|
||||
for (int i = 0; i != det.size(); ++i) {
|
||||
|
||||
Reference in New Issue
Block a user