mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-21 19:30:03 +02:00
made advanced tab detector dependent. each set mac adress etc is done via slsdetector and not multi
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@471 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
parent
460ffe0549
commit
3075b8ae11
@ -1,6 +1,7 @@
|
||||
#ifndef SLS_DETECTOR_DEFS_H
|
||||
#define SLS_DETECTOR_DEFS_H
|
||||
|
||||
|
||||
#ifdef __CINT__
|
||||
#define MYROOT
|
||||
#define __cplusplus
|
||||
|
@ -2,10 +2,10 @@
|
||||
#define SVNURL "file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware/gotthardDetectorServer"
|
||||
//#define SVNREPPATH ""
|
||||
#define SVNREPUUID "951219d9-93cf-4727-9268-0efd64621fa3"
|
||||
//#define SVNREV 0x468
|
||||
//#define SVNREV 0x469
|
||||
//#define SVNKIND ""
|
||||
//#define SVNSCHED ""
|
||||
#define SVNAUTH "l_maliakal_d"
|
||||
#define SVNREV 0x468
|
||||
#define SVNDATE 0x20130221
|
||||
#define SVNREV 0x469
|
||||
#define SVNDATE 0x20130222
|
||||
//
|
||||
|
@ -4162,7 +4162,7 @@ int* multiSlsDetector::readFrameFromReceiver(char* fName, int &fIndex){
|
||||
int *retdet, *p=retval;
|
||||
string fullFName="";
|
||||
string ext="";
|
||||
|
||||
char * pch;
|
||||
|
||||
|
||||
for (int id=0; id<thisMultiDetector->numberOfDetectors; id++) {
|
||||
@ -4176,9 +4176,11 @@ int* multiSlsDetector::readFrameFromReceiver(char* fName, int &fIndex){
|
||||
//concatenate filenames
|
||||
if(!fullFName.length()){
|
||||
fullFName.assign(fileIO::getFileName());
|
||||
size_t dot = fullFName.rfind(".");
|
||||
if(dot != string::npos)
|
||||
ext = fullFName.substr(dot,fullFName.size()-dot);
|
||||
if (strrchr(fName,'.')!=NULL){
|
||||
ext.assign(fName);
|
||||
size_t dot = ext.rfind(".");
|
||||
ext = ext.erase(0,dot);
|
||||
}
|
||||
}
|
||||
fullFName.append(getReceiverFileNameToConcatenate(fName));
|
||||
}else {
|
||||
@ -4347,7 +4349,6 @@ int64_t multiSlsDetector::clearAllErrorMask(){
|
||||
|
||||
|
||||
|
||||
|
||||
int multiSlsDetector::calibratePedestal(int frames){
|
||||
int ret=-100, ret1;
|
||||
|
||||
|
@ -2,10 +2,10 @@
|
||||
#define SVNURL "file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware/mythenDetectorServer"
|
||||
//#define SVNREPPATH ""
|
||||
#define SVNREPUUID "951219d9-93cf-4727-9268-0efd64621fa3"
|
||||
//#define SVNREV 0x431
|
||||
//#define SVNREV 0x469
|
||||
//#define SVNKIND ""
|
||||
//#define SVNSCHED ""
|
||||
#define SVNAUTH "l_maliakal_d"
|
||||
#define SVNREV 0x431
|
||||
#define SVNDATE 0x20130116
|
||||
#define SVNREV 0x469
|
||||
#define SVNDATE 0x20130222
|
||||
//
|
||||
|
@ -6260,3 +6260,14 @@ int slsDetector::calibratePedestal(int frames){
|
||||
|
||||
|
||||
|
||||
int64_t slsDetector::clearAllErrorMask(){
|
||||
clearErrorMask();
|
||||
for(int i=0;i<parentDet->getNumberOfDetectors();i++){
|
||||
if(parentDet->getDetectorId(i) == getDetectorId())
|
||||
parentDet->setErrorMask(parentDet->getErrorMask()|(0<<i));
|
||||
}
|
||||
return getErrorMask();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -1548,6 +1548,38 @@ class slsDetector : public slsDetectorUtils, public energyConversion {
|
||||
*/
|
||||
int calibratePedestal(int frames = 0);
|
||||
|
||||
|
||||
/** Clears error mask and also the bit in parent det multi error mask
|
||||
/returns error mask
|
||||
*/
|
||||
int64_t clearAllErrorMask();
|
||||
|
||||
/** returns the detector MAC address\sa sharedSlsDetector */
|
||||
char* getDetectorMAC() {return thisDetector->detectorMAC;};
|
||||
/** returns the detector IP address\sa sharedSlsDetector */
|
||||
char* getDetectorIP() {return thisDetector->detectorIP;};
|
||||
/** returns the receiver IP address \sa sharedSlsDetector */
|
||||
char* getReceiver() {return thisDetector->receiver_hostname;};
|
||||
/** returns the receiver UDP IP address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPIP() {return thisDetector->receiverUDPIP;};
|
||||
/** returns the receiver UDP MAC address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPMAC() {return thisDetector->receiverUDPMAC;};
|
||||
/** returns the receiver UDP IP address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPPort() {char *c= new char[MAX_STR_LENGTH];sprintf(c,"%d",thisDetector->receiverUDPPort); return c;};
|
||||
|
||||
/** validates the format of detector MAC address and sets it \sa sharedSlsDetector */
|
||||
char* setDetectorMAC(string detectorMAC);
|
||||
/** validates the format of detector IP address and sets it \sa sharedSlsDetector */
|
||||
char* setDetectorIP(string detectorIP);
|
||||
/** validates and sets the receiver IP address/hostname \sa sharedSlsDetector */
|
||||
char* setReceiver(string receiver);
|
||||
/** validates the format of receiver udp ip and sets it \sa sharedSlsDetector */
|
||||
char* setReceiverUDPIP(string udpip);
|
||||
/** validates the format of receiver udp mac and sets it \sa sharedSlsDetector */
|
||||
char* setReceiverUDPMAC(string udpmac);
|
||||
/** sets the receiver udp port \sa sharedSlsDetector */
|
||||
int setReceiverUDPPort(int udpport);
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
@ -1652,36 +1684,6 @@ class slsDetector : public slsDetectorUtils, public energyConversion {
|
||||
*/
|
||||
int receiveModule(sls_detector_module*);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/** returns the detector MAC address\sa sharedSlsDetector */
|
||||
char* getDetectorMAC() {return thisDetector->detectorMAC;};
|
||||
/** returns the detector IP address\sa sharedSlsDetector */
|
||||
char* getDetectorIP() {return thisDetector->detectorIP;};
|
||||
/** returns the receiver IP address \sa sharedSlsDetector */
|
||||
char* getReceiver() {return thisDetector->receiver_hostname;};
|
||||
/** returns the receiver UDP IP address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPIP() {return thisDetector->receiverUDPIP;};
|
||||
/** returns the receiver UDP MAC address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPMAC() {return thisDetector->receiverUDPMAC;};
|
||||
/** returns the receiver UDP IP address \sa sharedSlsDetector */
|
||||
char* getReceiverUDPPort() {char *c= new char[MAX_STR_LENGTH];sprintf(c,"%d",thisDetector->receiverUDPPort); return c;};
|
||||
|
||||
/** validates the format of detector MAC address and sets it \sa sharedSlsDetector */
|
||||
char* setDetectorMAC(string detectorMAC);
|
||||
/** validates the format of detector IP address and sets it \sa sharedSlsDetector */
|
||||
char* setDetectorIP(string detectorIP);
|
||||
/** validates and sets the receiver IP address/hostname \sa sharedSlsDetector */
|
||||
char* setReceiver(string receiver);
|
||||
/** validates the format of receiver udp ip and sets it \sa sharedSlsDetector */
|
||||
char* setReceiverUDPIP(string udpip);
|
||||
/** validates the format of receiver udp mac and sets it \sa sharedSlsDetector */
|
||||
char* setReceiverUDPMAC(string udpmac);
|
||||
/** sets the receiver udp port \sa sharedSlsDetector */
|
||||
int setReceiverUDPPort(int udpport);
|
||||
|
||||
/** Gets MAC from receiver and sets up UDP Connection */
|
||||
int setUDPConnection();
|
||||
|
||||
|
@ -2,10 +2,10 @@
|
||||
#define SVNURLLIB "file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware"
|
||||
//#define SVNREPPATH ""
|
||||
#define SVNREPUUIDLIB "951219d9-93cf-4727-9268-0efd64621fa3"
|
||||
//#define SVNREV 0x468
|
||||
//#define SVNREV 0x469
|
||||
//#define SVNKIND ""
|
||||
//#define SVNSCHED ""
|
||||
#define SVNAUTHLIB "l_maliakal_d"
|
||||
#define SVNREVLIB 0x468
|
||||
#define SVNDATELIB 0x20130221
|
||||
#define SVNREVLIB 0x469
|
||||
#define SVNDATELIB 0x20130222
|
||||
//
|
||||
|
@ -288,8 +288,8 @@ class fileIOStatic {
|
||||
size_t uscore=s.find("_"); \
|
||||
s=s.substr(uscore,dot-uscore); \
|
||||
uscore=s.find("_",1); \
|
||||
if ((uscore!= string::npos) && (sscanf( s.substr(1,uscore-1).c_str(),"d%d",&i))) \
|
||||
s=s.substr(uscore,s.size()-uscore); \
|
||||
//if ((uscore!= string::npos) && (sscanf( s.substr(1,uscore-1).c_str(),"d%d",&i)))
|
||||
//s=s.substr(uscore,s.size()-uscore);
|
||||
return s; \
|
||||
};
|
||||
|
||||
|
@ -2,10 +2,10 @@
|
||||
#define SVNURL "file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware/slsReceiver"
|
||||
//#define SVNREPPATH ""
|
||||
#define SVNREPUUID "951219d9-93cf-4727-9268-0efd64621fa3"
|
||||
//#define SVNREV 0x451
|
||||
//#define SVNREV 0x469
|
||||
//#define SVNKIND ""
|
||||
//#define SVNSCHED ""
|
||||
#define SVNAUTH "l_maliakal_d"
|
||||
#define SVNREV 0x451
|
||||
#define SVNDATE 0x20130205
|
||||
#define SVNREV 0x469
|
||||
#define SVNDATE 0x20130222
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user