eiger: trimbits changed such that it works for multi modules, ;general: loading multislsdetectr list with y dir first, updating the readframefromreceiver to load all the data interswapped for 16 bit; nthframe works better

This commit is contained in:
Maliakal Dhanya
2014-12-11 14:16:43 +01:00
parent 193c62dc42
commit 255f9e3fee
6 changed files with 46 additions and 28 deletions

View File

@ -1027,7 +1027,7 @@ int Feb_Control_SetTrimbits(unsigned int module_num, unsigned int *trimbits){
for(i=0;i<8;i++){ // column loop i
//printf("i:%d\t\t",i);
if(Module_TopAddressIsValid(&modules[0])){
if(Module_TopAddressIsValid(&modules[1])){
trimbits_to_load_l[offset+chip_sc] |= ( 0x7 & trimbits[row_set*16480+super_column_start_position_l+i])<<((7-i)*4);//low
trimbits_to_load_l[offset+chip_sc+32] |= ((0x38 & trimbits[row_set*16480+super_column_start_position_l+i])>>3)<<((7-i)*4);//upper
trimbits_to_load_r[offset+chip_sc] |= ( 0x7 & trimbits[row_set*16480+super_column_start_position_r+i])<<((7-i)*4);//low
@ -1043,7 +1043,7 @@ int Feb_Control_SetTrimbits(unsigned int module_num, unsigned int *trimbits){
} //end supercolumn loop sc
} //end row loop
if(Module_TopAddressIsValid(&modules[0])){
if(Module_TopAddressIsValid(&modules[1])){
if(!Feb_Interface_WriteMemoryInLoops(Module_GetTopLeftAddress(&modules[Feb_Control_current_index]),0,0,1024,trimbits_to_load_r)||
!Feb_Interface_WriteMemoryInLoops(Module_GetTopRightAddress(&modules[Feb_Control_current_index]),0,0,1024,trimbits_to_load_l)||
//if(!Feb_Interface_WriteMemory(Module_GetTopLeftAddress(&modules[0]),0,0,1023,trimbits_to_load_r)||

View File

@ -1,6 +1,6 @@
CC = powerpc-4xx-softfloat-gcc
CCX = powerpc-4xx-softfloat-g++
CFLAGS += -Wall -DDACS_INT -DEIGERD -DSLS_DETECTOR_FUNCTION_LIST -DDACS_INT -DSTOP_SERVER #-DVERBOSE #-DVIRTUAL -DPCCOMPILE
CFLAGS += -Wall -DDACS_INT -DEIGERD -DSLS_DETECTOR_FUNCTION_LIST -DDACS_INT #-DSTOP_SERVER #-DVERBOSE #-DVIRTUAL -DPCCOMPILE
LDLIBS += -lm -lstdc++
PROGS = eigerDetectorServer

View File

@ -143,10 +143,10 @@ int initDetector(){
Feb_Control_CheckSetup();
//top or bottom
bottom = Feb_Control_IsBottomModule();
// if(getDetectorNumber()==0xbeb016)
// bottom = 0;
//else bottom = 1;
//bottom = Feb_Control_IsBottomModule();
if(getDetectorNumber()==0xbeb031)
bottom = 0;
else bottom = 1;
if(bottom)
printf("BOTTOM ***************\n");