mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-12 04:47:14 +02:00
solved many bugs, but cannot get data in eiger
This commit is contained in:
@ -328,16 +328,15 @@ int receiveData(int file_des, void* buf,int length, intType itype){
|
||||
int nreceiving;
|
||||
int nreceived;
|
||||
if (file_des<0) return -1;
|
||||
//#ifdef VERY_VERBOSE
|
||||
#ifdef VERY_VERBOSE
|
||||
printf("want to receive %d Bytes\n", length);
|
||||
//#endif
|
||||
#endif
|
||||
|
||||
while(length > 0) {
|
||||
nreceiving = (length>send_rec_max_size) ? send_rec_max_size:length;
|
||||
nreceived = read(file_des,(char*)buf+total_received,nreceiving);
|
||||
if(!nreceived){
|
||||
if(!total_received) {
|
||||
cprintf(BG_RED, "Error reading from socket. Possible socket crash\n");
|
||||
return -1; //to handle it
|
||||
}
|
||||
break;
|
||||
|
@ -111,6 +111,7 @@ enum detFuncs{
|
||||
F_POWER_CHIP, /**< power chip */
|
||||
F_ACTIVATE, /** < activate */
|
||||
F_PREPARE_ACQUISITION, /** < prepare acquisition */
|
||||
F_CLEANUP_ACQUISITION, /** < clean up after acquisition */
|
||||
/* Always append functions hereafter!!! */
|
||||
|
||||
/* Always append functions before!!! */
|
||||
|
Reference in New Issue
Block a user