mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-28 01:00:02 +02:00
client moved everythign from common files to slsSupportLin/include
This commit is contained in:
parent
70f55ff788
commit
f7a6938366
4
Makefile
4
Makefile
@ -24,9 +24,9 @@ MANAPIDIR = $(MANDIR)/manual-api
|
||||
TABSPACE := "\t"
|
||||
|
||||
|
||||
INCLUDES=-I. -I$(WD)/commonFiles -I$(LIBRARYDIR)/slsDetector -I$(LIBRARYDIR)/usersFunctions -I$(LIBRARYDIR)/multiSlsDetector -I$(LIBRARYDIR)/slsReceiverInterface -I$(LIBRARYRXRDIR)/include -I$(LIBRARYDIR)/threadFiles -I$(LIBRARYDIR)/sharedMemory -I$(ASM)
|
||||
INCLUDES=-I. -I$(WD)/slsSupportLib/include -I$(LIBRARYDIR)/slsDetector -I$(LIBRARYDIR)/usersFunctions -I$(LIBRARYDIR)/multiSlsDetector -I$(LIBRARYDIR)/slsReceiverInterface -I$(LIBRARYRXRDIR)/include -I$(LIBRARYDIR)/threadFiles -I$(LIBRARYDIR)/sharedMemory -I$(ASM)
|
||||
|
||||
INCLUDESRXR += -I. -I$(LIBRARYRXRDIR)/include -I$(WD)/commonFiles -I$(CALIBDIR) -I$(ASM)
|
||||
INCLUDESRXR += -I. -I$(LIBRARYRXRDIR)/include -I$(WD)/slsSupportLib/include -I$(CALIBDIR) -I$(ASM)
|
||||
#LIBFLAGRXR +=
|
||||
|
||||
$(info )
|
||||
|
91
README.md
91
README.md
@ -1,91 +0,0 @@
|
||||
### Documentation
|
||||
Detailed documentation can be found on the [official site.](https://www.psi.ch/detectors/users-support)
|
||||
|
||||
### Binaries
|
||||
Documentation to obtain the binaries via the conda package is available for [lib](https://github.com/slsdetectorgroup/sls_detector_lib) and [gui](https://github.com/slsdetectorgroup/sls_detector_gui)
|
||||
|
||||
### Source code
|
||||
One can also obtain the source code from this repository and compile while realizing the setup dependencies as required.
|
||||
```
|
||||
git clone https://github.com/slsdetectorgroup/slsDetectorPackage.git
|
||||
|
||||
```
|
||||
#### Setup dependencies
|
||||
* Gui Client <br>
|
||||
Requirements: Qt 4.8 and Qwt 6.0
|
||||
```
|
||||
export QTDIR=/usr/local/Trolltech/
|
||||
export QWTDIR=/usr/local/qwt-6.0.1/
|
||||
```
|
||||
If either of them does not exist, the GUI client will not be built.
|
||||
|
||||
* Advanced user Calibration wizards<br>
|
||||
Requirements: ROOT
|
||||
```
|
||||
export ROOTSYS=/usr/local/root-5.34
|
||||
```
|
||||
|
||||
#### Compilation
|
||||
|
||||
Compiling can be done in two ways.
|
||||
|
||||
**1. Compile using script cmk.sh**<br>
|
||||
|
||||
After compiling, the libraries and executables will be found in `slsDetectorPackage/build/bin` directory<br>
|
||||
|
||||
Usage: [-c] [-b] [-h] [-d HDF5 directory] [-j]<br>
|
||||
* -[no option]: only make<br>
|
||||
* -c: Clean<br>
|
||||
* -b: Builds/Rebuilds CMake files normal mode<br>
|
||||
* -h: Builds/Rebuilds Cmake files with HDF5 package<br>
|
||||
* -d: HDF5 Custom Directory<br>
|
||||
* -t: Build/Rebuilds only text client<br>
|
||||
* -r: Build/Rebuilds only receiver<br>
|
||||
* -g: Build/Rebuilds only gui<br>
|
||||
* -j: Number of threads to compile through<br>
|
||||
* -e: Debug mode
|
||||
|
||||
Basic Option:
|
||||
./cmk.sh -b
|
||||
|
||||
For only make:
|
||||
./cmk.sh
|
||||
|
||||
For make clean;make:
|
||||
./cmk.sh -c
|
||||
|
||||
For using hdf5 without custom dir /blabla:
|
||||
./cmk.sh -h -d /blabla
|
||||
|
||||
For rebuilding cmake without hdf5
|
||||
./cmk.sh -b
|
||||
|
||||
For using multiple cores to compile faster:
|
||||
./cmk.sh -j9<br>
|
||||
|
||||
|
||||
For rebuilding only certain sections<br>
|
||||
./cmk.sh -tg #only text client and gui<br>
|
||||
./cmk.sh -r #only receiver<br>
|
||||
|
||||
|
||||
**2. Compile without script**<br>
|
||||
Use cmake to create out-of-source builds, by creating a build folder parallel to source directory.
|
||||
```
|
||||
$ cd ..
|
||||
$ mkdir slsDetectorPackage-build
|
||||
$ cd slsDetectorPackage-build
|
||||
$ cmake ../slsDetectorPackage -DCMAKE_BUILD_TYPE=Debug -DUSE_HDF5=OFF
|
||||
$ make
|
||||
```
|
||||
|
||||
Use the following as an example to compile statically and using specific hdf5 folder
|
||||
```
|
||||
$ HDF5_ROOT=/opt/hdf5v1.10.0 cmake ../slsDetectorPackage -DCMAKE_BUILD_TYPE=Debug -DUSE_HDF5=ON
|
||||
```
|
||||
After compiling, the libraries and executables will be found at `bin` directory
|
||||
```
|
||||
$ ls bin/
|
||||
gui_client libSlsDetector.a libSlsDetector.so libSlsReceiver.a libSlsReceiver.so
|
||||
sls_detector_acquire sls_detector_get slsDetectorGui sls_detector_help sls_detector_put slsReceiver slsMultiReceiver
|
||||
```
|
@ -3,7 +3,7 @@ set(SOURCES
|
||||
)
|
||||
|
||||
include_directories(
|
||||
../../commonFiles/include
|
||||
../../slsSupportLib/include
|
||||
../../slsDetectorSoftware/slsDetectorAnalysis
|
||||
../../build/bin
|
||||
../../slsdetectorSoftware/slsDetector
|
||||
|
@ -1,9 +1,9 @@
|
||||
PKGDIR = ../..
|
||||
LIBDIR = $(PKGDIR)/build/bin
|
||||
INCLUDES = -I . -I$(PKGDIR)/commonFiles -I$(PKGDIR)/slsDetectorSoftware/slsDetectorAnalysis -I$(LIBDIR) -I$(PKGDIR)/slsDetectorSoftware/slsDetector
|
||||
INCLUDES = -I . -I$(PKGDIR)/slsSupportLib/include -I$(PKGDIR)/slsDetectorSoftware/slsDetectorAnalysis -I$(LIBDIR) -I$(PKGDIR)/slsDetectorSoftware/slsDetector
|
||||
SRC_DET = mainClient.cpp
|
||||
SRC_REC = mainReceiver.cpp
|
||||
ZMQLIBDIR = $(PKGDIR)/commonFiles
|
||||
ZMQLIBDIR = $(PKGDIR)/slsSupportLib/include
|
||||
LDFLAG_DET = -I. -L$(LIBDIR) -Wl,-rpath=$(LIBDIR) -lSlsDetector -L/usr/lib64/ -pthread -lrt -L$(ZMQLIBDIR) -Wl,-rpath=$(ZMQLIBDIR) -lzmq
|
||||
LDFLAG_REC = -I. -L$(LIBDIR) -Wl,-rpath=$(LIBDIR) -lSlsReceiver -L/usr/lib64/ -pthread -lrt -L$(ZMQLIBDIR) -Wl,-rpath=$(ZMQLIBDIR) -lzmq
|
||||
DESTDIR ?= ../docs
|
||||
|
@ -75,7 +75,7 @@ qt4_add_resources(RESOURCES_SRCS ${RESOURCES})
|
||||
include_directories(
|
||||
include
|
||||
slsDetectorPlotting/include
|
||||
../commonFiles
|
||||
../slsSupportLib/include
|
||||
../slsDetectorSoftware/slsReceiverInterface
|
||||
../slsDetectorSoftware/slsDetector
|
||||
../slsDetectorSoftware/slsDetectorAnalysis
|
||||
|
@ -16,7 +16,7 @@ DOCDIR ?= docs
|
||||
|
||||
LIBRARYDIR ?= ../slsDetectorSoftware
|
||||
LIBRARYRXRDIR ?= ../slsReceiverSoftware
|
||||
INCLUDES ?= ../commonFiles -I$(LIBRARYRXRDIR)/MySocketTCP -I$(LIBRARYDIR)/slsReceiverInterface -I$(LIBRARYDIR)/slsDetector -I$(LIBRARYDIR)/slsDetectorAnalysis -I$(LIBRARYDIR)/multiSlsDetector -I$(LIBRARYDIR)/usersFunctions -I$(LIBRARYRXRDIR)/includes
|
||||
INCLUDES ?= ../slsSupportLib/include -I$(LIBRARYRXRDIR)/MySocketTCP -I$(LIBRARYDIR)/slsReceiverInterface -I$(LIBRARYDIR)/slsDetector -I$(LIBRARYDIR)/slsDetectorAnalysis -I$(LIBRARYDIR)/multiSlsDetector -I$(LIBRARYDIR)/usersFunctions -I$(LIBRARYRXRDIR)/includes
|
||||
|
||||
LDFLAGDET ?= -L$(LIBDIR) -Wl,-rpath=$(LIBDIR) -lSlsDetector
|
||||
|
||||
|
@ -5,9 +5,9 @@ LDLIBS += -lm -lstdc++ -pthread
|
||||
LDIR = ../../slsDetectorSoftware
|
||||
RDIR = ../../slsReceiverSoftware
|
||||
DDIR = ../../bin
|
||||
INCLUDES = -I ../../commonFiles -I $(LDIR)/slsDetector -I ../include -I $(RDIR)/include
|
||||
INCLUDES = -I ../../slsSupportLib/include -I $(LDIR)/slsDetector -I ../include -I $(RDIR)/include
|
||||
SRC_CLNT = qClient.cpp
|
||||
DEPSINCLUDES= qClient.h $(RDIR)/include/MySocketTCP.h $(LDIR)/slsDetector/slsDetectorBase.h ../../commonFiles/sls_detector_defs.h
|
||||
DEPSINCLUDES= qClient.h $(RDIR)/include/MySocketTCP.h $(LDIR)/slsDetector/slsDetectorBase.h ../../slsSupportLib/include/sls_detector_defs.h
|
||||
|
||||
|
||||
all: client
|
||||
|
@ -145,7 +145,7 @@ HEADERS = \
|
||||
include/qTabDeveloper.h\
|
||||
include/qTabMessages.h\
|
||||
include/gitInfoGui.h\
|
||||
../commonFiles/sls_detector_defs.h\
|
||||
../slsSupportLib/include/sls_detector_defs.h\
|
||||
../slsReceiverSoftware/include/sls_receiver_defs.h\
|
||||
include/qServer.h
|
||||
|
||||
|
@ -5,14 +5,14 @@ set(SOURCES
|
||||
slsDetector/slsDetectorCommand.cpp
|
||||
slsDetector/slsDetector.cpp
|
||||
slsReceiverInterface/receiverInterface.cpp
|
||||
../commonFiles/utilities.cpp
|
||||
../slsSupportLib/include/utilities.cpp
|
||||
)
|
||||
|
||||
set(HEADERS
|
||||
)
|
||||
|
||||
include_directories(
|
||||
../commonFiles
|
||||
../slsSupportLib/include
|
||||
multiSlsDetector
|
||||
sharedMemory
|
||||
slsDetector
|
||||
@ -36,7 +36,7 @@ add_library(slsDetectorShared SHARED
|
||||
|
||||
add_library(zmq STATIC IMPORTED GLOBAL)
|
||||
|
||||
set(ZMQ_STATIC_ARCHIVE ${CMAKE_CURRENT_SOURCE_DIR}/../commonFiles/libzmq.a)
|
||||
set(ZMQ_STATIC_ARCHIVE ${CMAKE_CURRENT_SOURCE_DIR}/../slsSupportLib/include/libzmq.a)
|
||||
set_target_properties(zmq PROPERTIES
|
||||
IMPORTED_LOCATION ${ZMQ_STATIC_ARCHIVE}
|
||||
)
|
||||
@ -46,12 +46,12 @@ target_link_libraries(slsDetectorShared
|
||||
)
|
||||
|
||||
set(PUBLICHEADERS
|
||||
../commonFiles/sls_detector_defs.h
|
||||
../commonFiles/sls_detector_funcs.h
|
||||
../commonFiles/error_defs.h
|
||||
../commonFiles/versionAPI.h
|
||||
../commonFiles/sls_receiver_exceptions.h
|
||||
../commonFiles/utilties.h
|
||||
../slsSupportLib/include/sls_detector_defs.h
|
||||
../slsSupportLib/include/sls_detector_funcs.h
|
||||
../slsSupportLib/include/error_defs.h
|
||||
../slsSupportLib/include/versionAPI.h
|
||||
../slsSupportLib/include/sls_receiver_exceptions.h
|
||||
../slsSupportLib/include/utilties.h
|
||||
../slsSupportLib/include/container_utils.h
|
||||
sharedMemory/SharedMemory.h
|
||||
slsDetector/slsDetector.h
|
||||
|
@ -9,15 +9,15 @@ CFLAGS= -g -DC_ONLY -fPIC
|
||||
|
||||
DFLAGS= -g -DDACS_INT
|
||||
|
||||
INCLUDES?= -I../commonFiles -IslsDetector -ImultiSlsDetector -IslsReceiverInterface -IsharedMemory -I ../slsSupportLib/include-I$(ASM)
|
||||
INCLUDES?= -I../slsSupportLib/include -IslsDetector -ImultiSlsDetector -IslsReceiverInterface -IsharedMemory I$(ASM)
|
||||
|
||||
#EPICSFLAGS=-D EPICS -I/usr/local/epics/base/include/ -I /usr/local/epics/base/include/os/Linux/ -L /usr/local/epics/base/lib/$(EPICS_HOST_ARCH) -Wl,-R/usr/local/epics/base/lib/$(EPICS_HOST_ARCH) -lca -lCom
|
||||
|
||||
LIBZMQDIR = ../commonFiles
|
||||
LIBZMQDIR = ../slsSupportLib/include
|
||||
LIBZMQ = -L$(LIBZMQDIR) -Wl,-rpath=$(LIBZMQDIR) -lzmq
|
||||
|
||||
SRC_CLNT= slsDetector/slsDetectorCommand.cpp slsDetector/slsDetector.cpp multiSlsDetector/multiSlsDetector.cpp slsReceiverInterface/receiverInterface.cpp slsDetector/slsDetectorUsers.cpp sharedMemory/SharedMemory.cpp ../commonFiles/utilities.cpp
|
||||
DEPSINCLUDES = ../commonFiles/sls_receiver_defs.h ../commonFiles/sls_receiver_funcs.h ../commonFiles/ansi.h ../commonFiles/sls_detector_defs.h ../commonFiles/sls_detector_funcs.h ../commonFiles/error_defs.h slsDetector/slsDetectorBase.h slsDetector/detectorData.h sharedMemory/SharedMemory.h ../commonFiles/sls_receiver_exceptions.h ../commonFiles/versionAPI.h ../commonFiles/utilities.h ../slsSupportLib/include/container_utils.h
|
||||
SRC_CLNT= slsDetector/slsDetectorCommand.cpp slsDetector/slsDetector.cpp multiSlsDetector/multiSlsDetector.cpp slsReceiverInterface/receiverInterface.cpp slsDetector/slsDetectorUsers.cpp sharedMemory/SharedMemory.cpp ../slsSupportLib/include/utilities.cpp
|
||||
DEPSINCLUDES = ../slsSupportLib/include/sls_receiver_defs.h ../slsSupportLib/include/sls_receiver_funcs.h ../slsSupportLib/include/ansi.h ../slsSupportLib/include/sls_detector_defs.h ../slsSupportLib/include/sls_detector_funcs.h ../slsSupportLib/include/error_defs.h slsDetector/slsDetectorBase.h slsDetector/detectorData.h sharedMemory/SharedMemory.h ../slsSupportLib/include/sls_receiver_exceptions.h ../slsSupportLib/include/versionAPI.h ../slsSupportLib/include/utilities.h ../slsSupportLib/include/container_utils.h
|
||||
|
||||
|
||||
|
||||
|
@ -1,19 +0,0 @@
|
||||
This subversion repository contains
|
||||
|
||||
Common directories
|
||||
Please inform Anna or Dhanya if you make modifications to these directories
|
||||
- MySocketTCP : socket class
|
||||
- commonFiles : header file common to server and client
|
||||
- slsDetector : base class with all main detector functionalities (client side)
|
||||
|
||||
|
||||
Mythen specific directories
|
||||
Please inform Anna if you make modifications to these directories
|
||||
- mythenDetector : mythen specific funcs (mainly files I/O and angular conversion)
|
||||
- mythenDetectorServer : mythen server (for etrax compiler)
|
||||
- firmware lib might be added in the future
|
||||
|
||||
Other Detector specific directories
|
||||
Please inform Dhanya if you make modifications to these directories
|
||||
|
||||
make doc
|
@ -80,18 +80,18 @@ LATEX_HIDE_INDICES = YES
|
||||
|
||||
PREDEFINED = __cplusplus
|
||||
|
||||
INPUT = ../commonfiles/communication_funcs.h \
|
||||
../commonfiles/error_defs.h \
|
||||
../commonfiles/sls_detector_defs.h \
|
||||
../commonfiles/sls_detector_funcs.h \
|
||||
../commonfiles/ansi.h \
|
||||
../commonfiles/include/genericSocket.h \
|
||||
../commonfiles/include/logger.h \
|
||||
../commonfiles/include/MySocketTCP.h \
|
||||
../commonfiles/include/sls_receiver_defs.h \
|
||||
../commonfiles/include/sls_receiver_funcs.h \
|
||||
../commonfiles/include/utilities.h \
|
||||
../commonfiles/include/ZmqSocket.h \
|
||||
INPUT = ../slsSupportLib/include/communication_funcs.h \
|
||||
../slsSupportLib/include/error_defs.h \
|
||||
../slsSupportLib/include/sls_detector_defs.h \
|
||||
../slsSupportLib/include/sls_detector_funcs.h \
|
||||
../slsSupportLib/include/ansi.h \
|
||||
../slsSupportLib/include/genericSocket.h \
|
||||
../slsSupportLib/include/logger.h \
|
||||
../slsSupportLib/include/MySocketTCP.h \
|
||||
../slsSupportLib/include/sls_receiver_defs.h \
|
||||
../slsSupportLib/include/sls_receiver_funcs.h \
|
||||
../slsSupportLib/include/utilities.h \
|
||||
../slsSupportLib/include/ZmqSocket.h \
|
||||
multiSlsDetector/multiSlsDetectorClient.h \
|
||||
multiSlsDetector/multiSlsDetectorCommand.h \
|
||||
multiSlsDetector/multiSlsDetector.h \
|
||||
|
@ -1,21 +0,0 @@
|
||||
CC = g++
|
||||
#CC = bfin-uclinux-
|
||||
SRC = slsADCReader.cpp
|
||||
INCLUDES = -I ../../slsReceiverSoftware/include -I ../../commonFiles
|
||||
CFLAGS = -Wall -lm -lstdc++
|
||||
|
||||
|
||||
all: clean slsADCReader
|
||||
|
||||
|
||||
slsADCReader: $(SRC)
|
||||
echo "creating adc reader"
|
||||
$(CC) -o $@ $^ $(CFLAGS) $(INCLUDES)
|
||||
|
||||
|
||||
clean:
|
||||
echo "cleaning"
|
||||
rm -rf *.o
|
||||
|
||||
|
||||
|
Binary file not shown.
@ -1,120 +0,0 @@
|
||||
#include "MySocketTCP.h"
|
||||
|
||||
#include "sls_detector_defs.h"
|
||||
#include "sls_receiver_defs.h"
|
||||
|
||||
#include "sls_detector_funcs.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define INVALID -999
|
||||
|
||||
enum detectorFunctions{
|
||||
F_GET_ADC=13
|
||||
};
|
||||
|
||||
void help() {
|
||||
cerr << "Usage:\n"
|
||||
"slsAdcReader [hostname] [adcval]" << endl;
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
|
||||
slsDetectorDefs::dacIndex getADCEnum(char* cval){
|
||||
int idac;
|
||||
string cmd;
|
||||
cmd.assign(cval);
|
||||
|
||||
if (sscanf(cval,"adc:%d",&idac)==1) {
|
||||
return (slsDetectorDefs::dacIndex)(idac+1000);
|
||||
} else if (cmd=="temp_adc")
|
||||
return slsDetectorDefs::TEMPERATURE_ADC;
|
||||
else if (cmd=="temp_fpga")
|
||||
return slsDetectorDefs::TEMPERATURE_FPGA;
|
||||
else if (cmd=="temp_fpgaext")
|
||||
return slsDetectorDefs::TEMPERATURE_FPGAEXT;
|
||||
else if (cmd=="temp_10ge")
|
||||
return slsDetectorDefs::TEMPERATURE_10GE;
|
||||
else if (cmd=="temp_dcdc")
|
||||
return slsDetectorDefs::TEMPERATURE_DCDC;
|
||||
else if (cmd=="temp_sodl")
|
||||
return slsDetectorDefs::TEMPERATURE_SODL;
|
||||
else if (cmd=="temp_sodr")
|
||||
return slsDetectorDefs::TEMPERATURE_SODR;
|
||||
else if (cmd=="temp_fpgafl")
|
||||
return slsDetectorDefs::TEMPERATURE_FPGA2;
|
||||
else if (cmd=="temp_fpgafr")
|
||||
return slsDetectorDefs::TEMPERATURE_FPGA3;
|
||||
else if (cmd=="i_a")
|
||||
return slsDetectorDefs::I_POWER_A;
|
||||
else if (cmd=="i_b")
|
||||
return slsDetectorDefs::I_POWER_B;
|
||||
else if (cmd=="i_c")
|
||||
return slsDetectorDefs::I_POWER_C;
|
||||
else if (cmd=="i_d")
|
||||
return slsDetectorDefs::I_POWER_D;
|
||||
else if (cmd=="vm_a")
|
||||
return slsDetectorDefs::V_POWER_A;
|
||||
else if (cmd=="vm_b")
|
||||
return slsDetectorDefs::V_POWER_B;
|
||||
else if (cmd=="vm_c")
|
||||
return slsDetectorDefs::V_POWER_C;
|
||||
else if (cmd=="vm_d")
|
||||
return slsDetectorDefs::V_POWER_D;
|
||||
else if (cmd=="vm_io")
|
||||
return slsDetectorDefs::V_POWER_IO;
|
||||
else if (cmd=="i_io")
|
||||
return slsDetectorDefs::I_POWER_IO;
|
||||
else {
|
||||
cerr << "cannot decode dac " << cmd << endl;
|
||||
help();
|
||||
return slsDetectorDefs::I_POWER_IO;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
if (argc < 3)
|
||||
help();
|
||||
slsDetectorDefs::dacIndex idx=getADCEnum(argv[2]);
|
||||
|
||||
|
||||
char mess[MAX_STR_LENGTH]="";
|
||||
detectorFunctions fnum=F_GET_ADC;
|
||||
int retval=-1;
|
||||
int ret=slsReceiverDefs::FAIL;
|
||||
int arg[2]={idx,0};
|
||||
|
||||
MySocketTCP* mySocket = 0;
|
||||
|
||||
try {
|
||||
mySocket = new MySocketTCP(argv[1],1952);
|
||||
} catch (...) {
|
||||
cerr << "could not create socket with " << argv[1] << endl;
|
||||
help();
|
||||
}
|
||||
|
||||
if (mySocket->Connect()) {
|
||||
mySocket->SendDataOnly(&fnum, sizeof(fnum));
|
||||
mySocket->SendDataOnly(arg,sizeof(arg));
|
||||
mySocket->ReceiveDataOnly(&ret, sizeof(ret));
|
||||
if (ret != slsReceiverDefs::FAIL) {
|
||||
mySocket->ReceiveDataOnly(&retval, sizeof(retval));
|
||||
} else {
|
||||
mySocket->ReceiveDataOnly(mess,sizeof(mess));
|
||||
printf("Detector returned Error: %s",mess);
|
||||
}
|
||||
mySocket->Disconnect();
|
||||
} else
|
||||
cerr << "could not connect to " << argv[1] << endl;
|
||||
|
||||
if (idx <= 100) {
|
||||
printf("%.2f°C\n",(double)retval/1000.00);
|
||||
}else
|
||||
printf("%dmV\n",retval);
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
@ -3,7 +3,7 @@ set(SOURCES
|
||||
)
|
||||
|
||||
include_directories(
|
||||
../../commonfiles
|
||||
../../slsSupportLib/include
|
||||
../multiSlsDetector
|
||||
../slsDetector
|
||||
../slsReceiverInterface
|
||||
|
@ -4,7 +4,7 @@ CFLAGS= -DC_ONLY
|
||||
#FLAGS=-DVERBOSE
|
||||
#ASM=$(shell echo "/lib/modules/`uname -r`/build/include")
|
||||
|
||||
INCLUDES?= -I../../commonfiles -I../slsDetector -I../multiSlsDetector -I../slsReceiverInterface -I$(shell echo "/lib/modules/`uname -r`/build/include")
|
||||
INCLUDES?= -I../../slsSupportLib/include -I../slsDetector -I../multiSlsDetector -I../slsReceiverInterface -I$(shell echo "/lib/modules/`uname -r`/build/include")
|
||||
DESTDIR ?= ../../bin
|
||||
BIN=$(DESTDIR)
|
||||
LIBS?= -L$(DESTDIR) -lSlsDetector
|
||||
|
@ -1,6 +1,6 @@
|
||||
CFLAGS= -DC_ONLY
|
||||
FLAGS=-DVERBOSE
|
||||
INCLUDES= -I../commonFiles -I../slsDetectorSoftware/slsDetector -I ../slsDetectorSoftware/MySocketTCP -I../slsDetectorSoftware/usersFunctions -I../slsDetectorSoftware/multiSlsDetector -I../slsDetectorSoftware/slsDetectorAnalysis
|
||||
INCLUDES= -I../slsSupportLib/include -I../slsDetectorSoftware/slsDetector -I ../slsDetectorSoftware/MySocketTCP -I../slsDetectorSoftware/usersFunctions -I../slsDetectorSoftware/multiSlsDetector -I../slsDetectorSoftware/slsDetectorAnalysis
|
||||
LIBS= -L../slsDetectorSoftware/
|
||||
LDFLAG= -lSlsDetector -pthread
|
||||
|
||||
|
@ -13,7 +13,7 @@ set(SOURCES
|
||||
src/DataProcessor.cpp
|
||||
src/DataStreamer.cpp
|
||||
src/Fifo.cpp
|
||||
../commonFiles/utilities.cpp
|
||||
../slsSupportLib/include/utilities.cpp
|
||||
)
|
||||
|
||||
|
||||
@ -39,12 +39,12 @@ add_definitions(
|
||||
|
||||
include_directories(
|
||||
include
|
||||
../commonFiles
|
||||
../slsSupportLib/include
|
||||
)
|
||||
|
||||
add_library(zmq STATIC IMPORTED GLOBAL)
|
||||
|
||||
set(ZMQ_STATIC_ARCHIVE ${CMAKE_CURRENT_SOURCE_DIR}/../commonFiles/libzmq.a)
|
||||
set(ZMQ_STATIC_ARCHIVE ${CMAKE_CURRENT_SOURCE_DIR}/../slsSupportLib/include/libzmq.a)
|
||||
set_target_properties(zmq PROPERTIES
|
||||
IMPORTED_LOCATION ${ZMQ_STATIC_ARCHIVE}
|
||||
)
|
||||
@ -64,14 +64,14 @@ add_library(slsReceiverShared SHARED
|
||||
)
|
||||
|
||||
set(PUBLICHEADERS
|
||||
../commonFiles/sls_receiver_defs.h
|
||||
../commonFiles/ansi.h
|
||||
../commonFiles/sls_receiver_funcs.h
|
||||
../commonFiles/MySocketTCP.h
|
||||
../commonFiles/genericSocket.h
|
||||
../commonFiles/logger.h
|
||||
../commonFiles/sls_receiver_exceptions.h
|
||||
../commonFiles/utilities.h
|
||||
../slsSupportLib/include/sls_receiver_defs.h
|
||||
../slsSupportLib/include/ansi.h
|
||||
../slsSupportLib/include/sls_receiver_funcs.h
|
||||
../slsSupportLib/include/MySocketTCP.h
|
||||
../slsSupportLib/include/genericSocket.h
|
||||
../slsSupportLib/include/logger.h
|
||||
../slsSupportLib/include/sls_receiver_exceptions.h
|
||||
../slsSupportLib/include/utilities.h
|
||||
)
|
||||
|
||||
|
||||
|
@ -5,7 +5,7 @@ LIBDIR ?= ../bin
|
||||
DOCDIR ?= docs
|
||||
SRCDIR = src
|
||||
INCDIR = include
|
||||
COMMONDIR = ../commonFiles
|
||||
COMMONDIR = ../slsSupportLib/include
|
||||
TESTDIR = test
|
||||
BUILDDIR = build
|
||||
PROGS = $(DESTDIR)/slsReceiver
|
||||
@ -21,7 +21,7 @@ INCLUDES?= $(INCLUDESRXR) -I $(INCDIR) -I $(COMMONDIR)
|
||||
##############################################################
|
||||
# ZMQ specific: in this case, you need ZMQ libraries already included in this package
|
||||
###########################################################
|
||||
LIBZMQDIR = ../commonFiles
|
||||
LIBZMQDIR = ../slsSupportLib/include
|
||||
LIBZMQ = -L$(LIBZMQDIR) -Wl,-rpath=$(LIBZMQDIR) -lzmq
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user