included exitReceiver, using different threads to listen and write packets in receiver, edited circularfifo to use pointer references, and acquire returns frames caught

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@362 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
l_maliakal_d
2012-11-30 09:28:52 +00:00
parent d8af12456d
commit 6b935f3bd2
12 changed files with 335 additions and 101 deletions

View File

@ -5805,3 +5805,30 @@ int slsDetector::updateReceiver() {
}
int slsDetector::exitReceiver(){
int retval;
int fnum=F_EXIT_SERVER;
if (setReceiverOnline(ONLINE_FLAG)==ONLINE_FLAG) {
if (dataSocket) {
dataSocket->Connect();
dataSocket->SendDataOnly(&fnum,sizeof(fnum));
dataSocket->ReceiveDataOnly(&retval,sizeof(retval));
dataSocket->Disconnect();
}
}
if (retval!=OK) {
std::cout<< std::endl;
std::cout<< "Shutting down the receiver" << std::endl;
std::cout<< std::endl;
}
return retval;
};