merge conflict from 3.0.1

This commit is contained in:
Dhanya Maliakal
2017-11-17 11:35:15 +01:00
7 changed files with 22 additions and 27 deletions

View File

@ -53,8 +53,9 @@ int BinaryFile::CreateFile(uint64_t fnum) {
if (BinaryFileStatic::CreateDataFile(filefd, *overWriteEnable, currentFileName, FILE_BUFFER_SIZE) == FAIL)
return FAIL;
if(!silentMode)
if(!silentMode) {
FILE_LOG(logINFO) << "[" << *udpPortNumber << "]: Binary File created: " << currentFileName;
}
return OK;
}
@ -90,8 +91,9 @@ int BinaryFile::CreateMasterFile(bool en, uint32_t size,
if (master && (*detIndex==0)) {
masterFileName = BinaryFileStatic::CreateMasterFileName(filePath, fileNamePrefix, *fileIndex);
if(!silentMode)
if(!silentMode) {
FILE_LOG(logINFO) << "Master File: " << masterFileName;
}
return BinaryFileStatic::CreateMasterDataFile(masterfd, masterFileName, *overWriteEnable,
*dynamicRange, en, size, nx, ny, *numImages,
at, st, ap, BINARY_WRITER_VERSION);

View File

@ -585,11 +585,7 @@ int UDPBaseImplementation::setActivate(int enable){
}
void UDPBaseImplementation::setStreamingPort(const uint32_t i) {
if (streamingPort == 0)
streamingPort = DEFAULT_ZMQ_PORTNO + (detID * ((myDetectorType == EIGER) ? 2 : 1) ); // multiplied by 2 as eiger has 2 ports
else
streamingPort = i;
streamingPort = i;
FILE_LOG(logINFO) << "Streaming Port: " << streamingPort;
}

View File

@ -221,9 +221,6 @@ int UDPStandardImplementation::setDataStreamEnable(const bool enable) {\
for ( int i = 0; i < numThreads; ++i ) {
dataStreamer.push_back(new DataStreamer(fifo[i], &dynamicRange, &shortFrameEnable, &fileIndex));
dataStreamer[i]->SetGeneralData(generalData);
// check again
if (streamingPort == 0)
streamingPort = DEFAULT_ZMQ_PORTNO + (detID * ((myDetectorType == EIGER) ? 2 : 1) ); // multiplied by 2 as eiger has 2 ports
if (dataStreamer[i]->CreateZmqSockets(&numThreads, streamingPort, streamingSrcIP) == FAIL) {
error = true;
break;

View File

@ -685,6 +685,11 @@ int slsReceiverTCPIPInterface::send_update() {
#endif
mySock->SendDataOnly(&ind,sizeof(ind));
// data streaming enable
#ifdef SLS_RECEIVER_UDP_FUNCTIONS
ind=(int)receiverBase->getDataStreamEnable();
#endif
// streaming source ip
#ifdef SLS_RECEIVER_UDP_FUNCTIONS
path = receiverBase->getStreamingSourceIP();
@ -2304,11 +2309,6 @@ int slsReceiverTCPIPInterface::set_streaming_port() {
}
//get
retval=receiverBase->getStreamingPort();
if(port > 0 && retval != port) { //if port = 0, its actual value calculated
ret = FAIL;
strcpy(mess, "Could not set streaming port\n");
FILE_LOG(logERROR) << "Warning: " << mess;
}
}
#endif
#ifdef VERYVERBOSE