mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-08 19:10:42 +02:00
fixed jungfrau image after programfpga, fixed resetfpga
This commit is contained in:
parent
49378e6d09
commit
c635b19941
Binary file not shown.
BIN
slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.7
Executable file
BIN
slsDetectorSoftware/jungfrauDetectorServer/bin/jungfrauDetectorServerv3.0.0.7
Executable file
Binary file not shown.
@ -1,9 +1,9 @@
|
|||||||
Path: slsDetectorsPackage/slsDetectorSoftware/jungfrauDetectorServer
|
Path: slsDetectorsPackage/slsDetectorSoftware/jungfrauDetectorServer
|
||||||
URL: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git
|
URL: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git
|
||||||
Repository Root: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git
|
Repository Root: origin git@git.psi.ch:sls_detectors_software/sls_detector_software.git
|
||||||
Repsitory UUID: c58dfe801770ceb63a9baab0be5b4cd16794b57e
|
Repsitory UUID: 037182a000f003ee636f25cd50a622c608c9e646
|
||||||
Revision: 89
|
Revision: 90
|
||||||
Branch: 3.0-rc
|
Branch: developer
|
||||||
Last Changed Author: Dhanya_Maliakal
|
Last Changed Author: Dhanya_Maliakal
|
||||||
Last Changed Rev: 1495
|
Last Changed Rev: 1562
|
||||||
Last Changed Date: 2017-08-15 14:14:32.000000002 +0200 ./RegisterDefs.h
|
Last Changed Date: 2017-09-14 11:50:30.000000002 +0200 ./Makefile
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
//#define SVNPATH ""
|
//#define SVNPATH ""
|
||||||
#define SVNURL "git@git.psi.ch:sls_detectors_software/sls_detector_software.git"
|
#define SVNURL "git@git.psi.ch:sls_detectors_software/sls_detector_software.git"
|
||||||
//#define SVNREPPATH ""
|
//#define SVNREPPATH ""
|
||||||
#define SVNREPUUID "c58dfe801770ceb63a9baab0be5b4cd16794b57e"
|
#define SVNREPUUID "037182a000f003ee636f25cd50a622c608c9e646"
|
||||||
//#define SVNREV 0x1495
|
//#define SVNREV 0x1562
|
||||||
//#define SVNKIND ""
|
//#define SVNKIND ""
|
||||||
//#define SVNSCHED ""
|
//#define SVNSCHED ""
|
||||||
#define SVNAUTH "Dhanya_Maliakal"
|
#define SVNAUTH "Dhanya_Maliakal"
|
||||||
#define SVNREV 0x1495
|
#define SVNREV 0x1562
|
||||||
#define SVNDATE 0x20170815
|
#define SVNDATE 0x20170914
|
||||||
//
|
//
|
||||||
|
@ -254,7 +254,7 @@ u_int32_t getDetectorIP(){
|
|||||||
/* initialization */
|
/* initialization */
|
||||||
|
|
||||||
void initControlServer(){
|
void initControlServer(){
|
||||||
|
clkPhase[0] = 0; clkPhase[1] = 0;
|
||||||
setupDetector();
|
setupDetector();
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
@ -7249,6 +7249,15 @@ int slsDetector::programFPGA(string fname){
|
|||||||
if (ret==FORCE_UPDATE)
|
if (ret==FORCE_UPDATE)
|
||||||
updateDetector();
|
updateDetector();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//remapping stop server
|
||||||
|
fnum=F_RESET_FPGA;
|
||||||
|
int stopret;
|
||||||
|
if (connectStop() == OK){
|
||||||
|
stopSocket->SendDataOnly(&fnum,sizeof(fnum));
|
||||||
|
stopSocket->ReceiveDataOnly(&stopret,sizeof(stopret));
|
||||||
|
disconnectControl();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//free resources
|
//free resources
|
||||||
@ -7272,17 +7281,15 @@ int slsDetector::resetFPGA(){
|
|||||||
std::cout<< "Sending reset to FPGA " << endl;
|
std::cout<< "Sending reset to FPGA " << endl;
|
||||||
#endif
|
#endif
|
||||||
if (thisDetector->onlineFlag==ONLINE_FLAG) {
|
if (thisDetector->onlineFlag==ONLINE_FLAG) {
|
||||||
|
// control server
|
||||||
if (connectControl() == OK){
|
if (connectControl() == OK){
|
||||||
controlSocket->SendDataOnly(&fnum,sizeof(fnum));
|
controlSocket->SendDataOnly(&fnum,sizeof(fnum));
|
||||||
|
|
||||||
//check opening error
|
|
||||||
controlSocket->ReceiveDataOnly(&ret,sizeof(ret));
|
controlSocket->ReceiveDataOnly(&ret,sizeof(ret));
|
||||||
if (ret==FAIL) {
|
if (ret==FAIL) {
|
||||||
controlSocket->ReceiveDataOnly(mess,sizeof(mess));
|
controlSocket->ReceiveDataOnly(mess,sizeof(mess));
|
||||||
std::cout<< "Detector returned error: " << mess << std::endl;
|
std::cout<< "Detector returned error: " << mess << std::endl;
|
||||||
setErrorMask((getErrorMask())|(RESET_ERROR));
|
setErrorMask((getErrorMask())|(RESET_ERROR));
|
||||||
}
|
}
|
||||||
|
|
||||||
disconnectControl();
|
disconnectControl();
|
||||||
if (ret==FORCE_UPDATE)
|
if (ret==FORCE_UPDATE)
|
||||||
updateDetector();
|
updateDetector();
|
||||||
|
@ -37,6 +37,7 @@ int sockfd; // (updated in slsDetectorServer) as extern
|
|||||||
int (*flist[NUM_DET_FUNCTIONS])(int);
|
int (*flist[NUM_DET_FUNCTIONS])(int);
|
||||||
char mess[MAX_STR_LENGTH];
|
char mess[MAX_STR_LENGTH];
|
||||||
int dataBytes = 10;
|
int dataBytes = 10;
|
||||||
|
int isControlServer = 0;
|
||||||
|
|
||||||
|
|
||||||
/* initialization functions */
|
/* initialization functions */
|
||||||
@ -59,8 +60,10 @@ void init_detector(int controlserver) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef SLS_DETECTOR_FUNCTION_LIST
|
#ifdef SLS_DETECTOR_FUNCTION_LIST
|
||||||
if (controlserver)
|
if (controlserver) {
|
||||||
|
isControlServer = 1;
|
||||||
initControlServer();
|
initControlServer();
|
||||||
|
}
|
||||||
else initStopServer();
|
else initStopServer();
|
||||||
#endif
|
#endif
|
||||||
strcpy(mess,"dummy message");
|
strcpy(mess,"dummy message");
|
||||||
@ -4601,6 +4604,9 @@ int program_fpga(int file_des) {
|
|||||||
#ifdef VERY_VERBOSE
|
#ifdef VERY_VERBOSE
|
||||||
printf("Done with program receiving command\n");
|
printf("Done with program receiving command\n");
|
||||||
#endif
|
#endif
|
||||||
|
if (isControlServer)
|
||||||
|
basictests();
|
||||||
|
init_detector(isControlServer);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
if (ret==OK)
|
if (ret==OK)
|
||||||
@ -4646,7 +4652,9 @@ int reset_fpga(int file_des) {
|
|||||||
}
|
}
|
||||||
#ifdef SLS_DETECTOR_FUNCTION_LIST
|
#ifdef SLS_DETECTOR_FUNCTION_LIST
|
||||||
else {
|
else {
|
||||||
initControlServer();
|
if (isControlServer)
|
||||||
|
basictests();
|
||||||
|
init_detector(isControlServer);
|
||||||
ret = FORCE_UPDATE;
|
ret = FORCE_UPDATE;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user