mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-13 05:17:13 +02:00
using only the slsDetector class
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@391 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
@ -1,6 +1,7 @@
|
|||||||
CFLAGS= -DC_ONLY
|
CFLAGS= -DC_ONLY
|
||||||
#FLAGS=-DVERBOSE
|
#FLAGS=-DVERBOSE
|
||||||
INCLUDES= -I../slsDetectorSoftware/commonFiles -I../slsDetectorSoftware/slsDetector -I ../slsDetectorSoftware/MySocketTCP -I../slsDetectorSoftware/mythenDetector -I../slsDetectorSoftware/gotthardDetector -I../slsDetectorSoftware/usersFunctions
|
INCLUDES= -I../slsDetectorSoftware/commonFiles -I../slsDetectorSoftware/slsDetector -I ../slsDetectorSoftware/MySocketTCP -I../slsDetectorSoftware/usersFunctions
|
||||||
|
#-I../slsDetectorSoftware/mythenDetector -I../slsDetectorSoftware/gotthardDetector
|
||||||
#LIBS=-L../TMythenDetector/bin/ -L$(QTDIR)/lib
|
#LIBS=-L../TMythenDetector/bin/ -L$(QTDIR)/lib
|
||||||
LIBS= -L$(QTDIR)/lib -L../slsDetectorSoftware/
|
LIBS= -L$(QTDIR)/lib -L../slsDetectorSoftware/
|
||||||
LDFLAG=-lSlsDetector -lpthread
|
LDFLAG=-lSlsDetector -lpthread
|
||||||
|
@ -1,13 +1,7 @@
|
|||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
#ifdef MYTHEN_DET
|
#include "slsDetector.h"
|
||||||
#include "mythenDetector.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef GOTTHARD_DET
|
|
||||||
#include "gotthardDetector.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
@ -17,54 +11,54 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
int id=0;
|
int id=0;
|
||||||
char *c;
|
char *c;
|
||||||
string answer;
|
string answer;
|
||||||
int action;
|
int action;
|
||||||
#ifdef MYTHEN_DET
|
slsDetector *myDetector;
|
||||||
mythenDetector *myDetector;
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef READOUT
|
#ifdef READOUT
|
||||||
action=mythenDetector::READOUT_ACTION;
|
action=slsDetector::READOUT_ACTION;
|
||||||
#elif PUT
|
#elif PUT
|
||||||
action=mythenDetector::PUT_ACTION;
|
action=slsDetector::PUT_ACTION;
|
||||||
#elif GET
|
#elif GET
|
||||||
action=mythenDetector::GET_ACTION;
|
action=slsDetector::GET_ACTION;
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef GOTTHARD_DET
|
|
||||||
gotthardDetector *myDetector;
|
|
||||||
#ifdef READOUT
|
|
||||||
action=gotthardDetector::READOUT_ACTION;
|
|
||||||
#elif PUT
|
|
||||||
action=gotthardDetector::PUT_ACTION;
|
|
||||||
#elif GET
|
|
||||||
action=gotthardDetector::GET_ACTION;
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
detectorType t;
|
||||||
|
|
||||||
|
#ifdef MYTHEN_DET
|
||||||
|
#ifndef PICASSOD
|
||||||
|
t=MYTHEN;
|
||||||
|
#else
|
||||||
|
t=PICASSO;
|
||||||
|
#endif;
|
||||||
|
#elif GOTTHARD_DET
|
||||||
|
t=GOTTHARD;
|
||||||
|
#else
|
||||||
|
t=GENERIC;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (argc>1 && sscanf(argv[1],"%d",&id)){
|
if (argc>1 && sscanf(argv[1],"%d",&id)){
|
||||||
|
|
||||||
#ifdef MYTHEN_DET
|
|
||||||
#ifndef PICASSOD
|
myDetector=new slsDetector(t,id);
|
||||||
myDetector=new mythenDetector(id);
|
|
||||||
#else
|
|
||||||
myDetector=new mythenDetector(id,PICASSO);
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#ifdef GOTTHARD_DET
|
|
||||||
myDetector=new gotthardDetector(id);
|
|
||||||
#endif
|
|
||||||
} else {
|
} else {
|
||||||
cout << "Wrong usage - should be: "<< argv[0] << " id";
|
cout << "Wrong usage - should be: "<< argv[0] << " id";
|
||||||
cout << "(:channel arg)" << endl;
|
cout << "(:channel arg)" << endl;
|
||||||
#ifdef MYTHEN_DET
|
|
||||||
cout << mythenDetector::helpLine(action);
|
cout << slsDetector::helpLine(action);
|
||||||
#endif
|
|
||||||
#ifdef GOTTHARD_DET
|
|
||||||
cout << gotthardDetector::helpLine(action);
|
|
||||||
#endif
|
|
||||||
cout << endl;
|
cout << endl;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
@ -75,12 +69,9 @@ int main(int argc, char *argv[])
|
|||||||
if (argc<3) {
|
if (argc<3) {
|
||||||
cout << "Wrong usage - should be: "<< argv[0] << " id";
|
cout << "Wrong usage - should be: "<< argv[0] << " id";
|
||||||
cout << ":channel arg" << endl;
|
cout << ":channel arg" << endl;
|
||||||
#ifdef MYTHEN_DET
|
|
||||||
cout << mythenDetector::helpLine(action);
|
cout << slsDetector::helpLine(action);
|
||||||
#endif
|
|
||||||
#ifdef GOTTHARD_DET
|
|
||||||
cout << gotthardDetector::helpLine(action);
|
|
||||||
#endif
|
|
||||||
cout << endl;
|
cout << endl;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user