first mythen3 server commit

This commit is contained in:
Andrä Marie
2018-01-18 09:25:06 +01:00
parent 59c0861131
commit 92b4b3324e
21 changed files with 9381 additions and 14 deletions

View File

@@ -3717,21 +3717,21 @@ int setDac(int dacnum,int dacvalue){
csdx=2;
else
csdx=ichip+2;
//setting int reference
offw=DAC_REG;
//setting int reference
offw=DAC_REG;
valw=bus_r(offw)|0xff;
valw=bus_r(offw)|0xff; // alles auf 1 setzen (START)
bus_w(offw,(valw)); // start point
valw=((valw&(~(0x1<<csdx))));bus_w(offw,valw); //chip sel bar down
valw=(valw&(~(0x1<<cdx)));bus_w(offw,valw); //cldwn
bus_w(offw,(valw)); // start point
valw=((valw&(~(0x1<<csdx))));bus_w(offw,valw); //chip sel bar down
valw=(valw&(~(0x1<<cdx)));bus_w(offw,valw); //clk dwn
//#ifdef CTB
if (myDetectorType==JUNGFRAUCTB) {
for (i=0; i<ichip; i++) {
nextDac();
printf("next DAC\n");
nextDac();
printf("next DAC\n");
}
}
//#endif
@@ -3744,8 +3744,8 @@ int setDac(int dacnum,int dacvalue){
if (myDetectorType==JUNGFRAUCTB) {
for (i=ichip+1; i<N_DAC/8; i++) {
nextDac();
printf("next DAC\n");
nextDac();
printf("next DAC\n");
}
}
valw=bus_r(offw);

View File

@@ -1039,7 +1039,7 @@ int set_dac(int file_des) {
}
if (vLimitCompliant(v))
retval=setDac(ind,val);
retval=setDac(ind,val); // in DACu
} else {
@@ -2150,7 +2150,7 @@ int set_timer(int file_des) {
ret=FAIL;
}
n = receiveDataOnly(file_des,&tns,sizeof(tns));
n = receiveDataOnly(file_des,&tns,sizeof(tns)); // total received data
if (n < 0) {
sprintf(mess,"Error reading from socket\n");
ret=FAIL;