changing zmq rxr port should restart data streaming

This commit is contained in:
Dhanya Maliakal 2017-11-21 13:39:49 +01:00
parent a79864a5ae
commit d00df32e49
2 changed files with 18 additions and 1 deletions

View File

@ -170,6 +170,12 @@ class UDPStandardImplementation: private virtual slsReceiverDefs, public UDPBase
*/
void closeFiles();
/**
* Set streaming port and restart sockets if streaming was enabled
* @param i streaming port
*/
void setStreamingPort(const uint32_t i);
private:

View File

@ -196,7 +196,7 @@ int UDPStandardImplementation::setFrameToGuiFrequency(const uint32_t freq) {
}
int UDPStandardImplementation::setDataStreamEnable(const bool enable) {\
int UDPStandardImplementation::setDataStreamEnable(const bool enable) {
if (dataStreamEnable != enable) {
dataStreamEnable = enable;
@ -571,6 +571,17 @@ void UDPStandardImplementation::closeFiles() {
}
void UDPStandardImplementation::setStreamingPort(const uint32_t i) {
streamingPort = i;
FILE_LOG(logINFO) << "Streaming Port: " << streamingPort;
if (dataStreamEnable) {
setDataStreamEnable(false);
setDataStreamEnable(true);
}
}
void UDPStandardImplementation::SetLocalNetworkParameters() {
//to increase socket receiver buffer size and max length of input queue by changing kernel settings