edited getChanregs to include argument to get trimbits from sharedmemory or detector

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorSoftware@253 951219d9-93cf-4727-9268-0efd64621fa3
This commit is contained in:
l_maliakal_d
2012-09-12 08:50:25 +00:00
parent 008d930594
commit 4c8bc09143
4 changed files with 13 additions and 7 deletions

View File

@ -2438,7 +2438,7 @@ int slsDetector::setModule(sls_detector_module module){
};
slsDetectorDefs::sls_detector_module *slsDetector::getModule(int imod){
cout<<"getModuke:"<<imod<<endl;
#ifdef VERBOSE
std::cout << "slsDetector get module " << std::endl;
#endif
@ -2814,9 +2814,13 @@ slsDetectorDefs::detectorSettings slsDetector::setSettings( detectorSettings ise
int slsDetector::getChanRegs(double* retval){
int slsDetector::getChanRegs(double* retval,bool fromDetector){
int n=getTotalNumberOfChannels();
//else the original array has 0 initialized
if(fromDetector){
for(int im=0;im<setNumberOfModules();im++)
getModule(im);
}
//the original array has 0 initialized
if(chanregs){
for (int i=0; i<n; i++)
retval[i] = (double) chanregs[i];