included shortframe in gui for time being its just adc selection

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@141 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
l_maliakal_d 2013-01-31 15:34:31 +00:00
parent 2ead554b7b
commit 6b311f931b
3 changed files with 789 additions and 661 deletions

File diff suppressed because it is too large Load Diff

View File

@ -56,6 +56,11 @@ private:
private slots:
/** Set ADC Readout
*/
void SetADCReadout(int i);
/** Enable/Disable Energy and Calibration Logs
*/
void SetLogs();
@ -102,6 +107,10 @@ private slots:
private:
/** The sls detector object */
multiSlsDetector *myDet;
/** detector type */
slsDetectorDefs::detectorType detType;
/** The Plot widget */
qDrawPlot *myPlot;

View File

@ -40,11 +40,22 @@ qTabAdvanced::~qTabAdvanced(){
void qTabAdvanced::SetupWidgetWindow(){
//executed even for non digital, so make sure its necessary
slsDetectorDefs::detectorType detType = myDet->getDetectorsType();
//readout adc
lblADC->setEnabled(false);
comboADC->setEnabled(false);
detType = myDet->getDetectorsType();
switch(detType){
case slsDetectorDefs::MYTHEN: isEnergy = true; isAngular = true; break;
case slsDetectorDefs::EIGER: isEnergy = true; isAngular = false; break;
case slsDetectorDefs::GOTTHARD: isEnergy = false; isAngular = true; break;
case slsDetectorDefs::GOTTHARD:
isEnergy = false;
isAngular = true;
lblADC->setEnabled(true);
comboADC->setEnabled(true);
break;
default: break;
}
@ -118,6 +129,21 @@ void qTabAdvanced::Initialization(){
connect(btnGroup, SIGNAL(buttonClicked(int)), this, SLOT(UpdateTrimbitPlot(int)));
}
if(detType==slsDetectorDefs::GOTTHARD)
connect(comboADC, SIGNAL(currentIndexChanged(int)), this, SLOT(SetADCReadout(int)));
}
//-------------------------------------------------------------------------------------------------------------------------------------------------
void qTabAdvanced::SetADCReadout(int i){
if(i==6) i=-1;
if(myDet->configureMAC(i)==slsDetectorDefs::FAIL)
qDefs::Message(qDefs::WARNING,"Could not configure mac","Advanced");
else
qDefs::Message(qDefs::WARNING,"ADC Readout successfully set up","Advanced");
}