diff --git a/slsDetectorServers/eigerDetectorServer/FebControl.c b/slsDetectorServers/eigerDetectorServer/FebControl.c index b7d6970f0..7b7fc7198 100644 --- a/slsDetectorServers/eigerDetectorServer/FebControl.c +++ b/slsDetectorServers/eigerDetectorServer/FebControl.c @@ -126,7 +126,7 @@ void Feb_Control_FebControl() { moduleSize = 0; } -int Feb_Control_Init(int master, int top, int normal, int module_num) { +int Feb_Control_Init(int master, int normal, int module_num) { Feb_Control_module_number = 0; Feb_Control_current_index = 0; Feb_control_master = master; @@ -135,28 +135,18 @@ int Feb_Control_Init(int master, int top, int normal, int module_num) { // global send Feb_Control_AddModule(0, 0xff); Feb_Control_PrintModuleList(); - Feb_Control_module_number = (module_num & 0xFF); - - int serial = !top; - LOG(logDEBUG1, ("serial: %d\n", serial)); - - Feb_Control_current_index = 1; // Add the half module - Feb_Control_AddModule(Feb_Control_module_number, serial); + Feb_Control_module_number = (module_num & 0xFF); + Feb_Control_current_index = 1; + Feb_Control_AddModule(Feb_Control_module_number, 0); Feb_Control_PrintModuleList(); unsigned int nfebs = 0; unsigned int *feb_list = malloc(moduleSize * 4 * sizeof(unsigned int)); for (unsigned int i = 1; i < moduleSize; i++) { - if (Module_TopAddressIsValid(&modules[i])) { - feb_list[nfebs++] = Module_GetTopRightAddress(&modules[i]); - feb_list[nfebs++] = Module_GetTopLeftAddress(&modules[i]); - } - if (Module_BottomAddressIsValid(&modules[i])) { - feb_list[nfebs++] = Module_GetBottomRightAddress(&modules[i]); - feb_list[nfebs++] = Module_GetBottomLeftAddress(&modules[i]); - } + feb_list[nfebs++] = Module_GetTopRightAddress(&modules[i]); + feb_list[nfebs++] = Module_GetTopLeftAddress(&modules[i]); } Feb_Interface_SendCompleteList(nfebs, feb_list); diff --git a/slsDetectorServers/eigerDetectorServer/FebControl.h b/slsDetectorServers/eigerDetectorServer/FebControl.h index 5ca18884f..bd38c4476 100644 --- a/slsDetectorServers/eigerDetectorServer/FebControl.h +++ b/slsDetectorServers/eigerDetectorServer/FebControl.h @@ -54,7 +54,7 @@ int Feb_Control_StartDAQOnlyNWaitForFinish(int sleep_time_us); int Feb_Control_ResetChipCompletely(); int Feb_Control_ResetChipPartially(); void Feb_Control_FebControl(); -int Feb_Control_Init(int master, int top, int normal, int module_num); +int Feb_Control_Init(int master, int normal, int module_num); int Feb_Control_OpenSerialCommunication(); void Feb_Control_CloseSerialCommunication(); int Feb_Control_CheckSetup(); diff --git a/slsDetectorServers/eigerDetectorServer/slsDetectorFunctionList.c b/slsDetectorServers/eigerDetectorServer/slsDetectorFunctionList.c index cccc0d6c3..b8efc4be0 100644 --- a/slsDetectorServers/eigerDetectorServer/slsDetectorFunctionList.c +++ b/slsDetectorServers/eigerDetectorServer/slsDetectorFunctionList.c @@ -333,7 +333,7 @@ void initControlServer() { Feb_Interface_FebInterface(); Feb_Control_FebControl(); // same addresses for top and bottom - Feb_Control_Init(master, 1, normal, getDetectorNumber()); + Feb_Control_Init(master, normal, getDetectorNumber()); // master of 9M, check high voltage serial communication to blackfin if (master && !normal) { if (Feb_Control_OpenSerialCommunication()) @@ -372,7 +372,7 @@ void initStopServer() { Feb_Interface_FebInterface(); Feb_Control_FebControl(); // same addresses for top and bottom - Feb_Control_Init(master, 1, normal, getDetectorNumber()); + Feb_Control_Init(master, normal, getDetectorNumber()); LOG(logDEBUG1, ("Stop server: FEB Initialization done\n")); #endif // client first connect (from shm) will activate