enabling 10Gbe for eiger, advanced settings and also mV for dacs for all detectors

This commit is contained in:
Maliakal Dhanya
2014-07-11 12:56:11 +02:00
parent 4d9bbeecc3
commit 7c58d3db46
6 changed files with 204 additions and 127 deletions

View File

@ -29,6 +29,7 @@ qTabDataOutput::qTabDataOutput(QWidget *parent,multiSlsDetector*& detector):
QWidget(parent),myDet(detector){
setupUi(this);
SetupWidgetWindow();
Refresh();
}
@ -54,6 +55,9 @@ void qTabDataOutput::SetupWidgetWindow(){
if((detType == slsDetectorDefs::MYTHEN)||(detType == slsDetectorDefs::GOTTHARD))
chkAngular->setEnabled(true);
if(detType == slsDetectorDefs::EIGER)
chkTenGiga->setEnabled(true);
/** error message **/
red = QPalette();
red.setColor(QPalette::Active,QPalette::WindowText,Qt::red);
@ -157,6 +161,8 @@ void qTabDataOutput::Initialization(){
connect(chkDiscardBad, SIGNAL(toggled(bool)), this, SLOT(DiscardBadChannels()));
//compression
connect(chkCompression, SIGNAL(toggled(bool)), this, SLOT(SetCompression(bool)));
//10GbE
connect(chkTenGiga, SIGNAL(toggled(bool)), this, SLOT(EnableTenGigabitEthernet(bool)));
}
@ -735,6 +741,27 @@ void qTabDataOutput::SetCompression(bool enable){
//-------------------------------------------------------------------------------------------------------------------------------------------------
void qTabDataOutput::EnableTenGigabitEthernet(bool enable,int get){
#ifdef VERBOSE
cout << endl << "Enabling/Disabling 10GbE" << endl;
#endif
disconnect(chkTenGiga, SIGNAL(toggled(bool)), this, SLOT(EnableTenGigabitEthernet(bool)));
int ret;
if(get)
ret = myDet->enableTenGigabitEthernet(-1);
else
ret = myDet->enableTenGigabitEthernet(enable);
if(ret > 0) chkTenGiga->setChecked(true);
else chkTenGiga->setChecked(false);
connect(chkTenGiga, SIGNAL(toggled(bool)), this, SLOT(EnableTenGigabitEthernet(bool)));
qDefs::checkErrorMessage(myDet,"qTabDataOutput::EnableTenGigabitEthernet");
}
//-------------------------------------------------------------------------------------------------------------------------------------------------
void qTabDataOutput::Refresh(){
#ifdef VERBOSE
cout << endl << "**Updating DataOutput Tab" << endl;
@ -808,6 +835,16 @@ void qTabDataOutput::Refresh(){
GetCompression();
}
//getting 10GbE
if(chkTenGiga->isEnabled()){
#ifdef VERBOSE
cout << "Getting 10GbE enable" << endl;
#endif
EnableTenGigabitEthernet(-1,1);
}
#ifdef VERBOSE
cout << "**Updated DataOutput Tab" << endl << endl;