added ZeroTotalFileSize() for Data Class, this is for new run

This commit is contained in:
splitPoleDAQ 2023-05-22 18:23:24 -04:00
parent 8a662c3407
commit 8bead5a54b
4 changed files with 15 additions and 10 deletions

View File

@ -80,7 +80,7 @@ class Data{
void CloseSaveFile();
unsigned int GetFileSize() const {return outFileSize;}
uint64_t GetTotalFileSize() const {return FinishedOutFilesSize + outFileSize;}
void ZeroTotalFileSize() { FinishedOutFilesSize = 0; }
protected:

View File

@ -406,6 +406,7 @@ void Digitizer::StopACQ(){
AcqRun = false;
data->ClearTriggerRate();
data->ClearBuffer();
data->ZeroTotalFileSize();
}
unsigned int Digitizer::CalByteForBuffer(){

View File

@ -184,14 +184,7 @@ public:
plot = new Trace();
dataSeries = new QLineSeries();
this->xMin = xMin;
this->xMax = xMax;
this->nBin = nBin;
dX = (xMax-xMin)/nBin;
for( int i = 0; i <= nBin; i++) {
dataSeries->append(xMin + i * dX, 0 );
dataSeries->append(xMin + i * dX, 0 );
}
Rebin(xMin, xMax, nBin);
maxBin = -1;
maxBinValue = 0;
@ -234,6 +227,18 @@ public:
void SetColor(Qt::GlobalColor color){ areaSeries->setBrush(color);}
void Rebin(double xMin, double xMax, int nBin){
dataSeries->clear();
this->xMin = xMin;
this->xMax = xMax;
this->nBin = nBin;
dX = (xMax-xMin)/nBin;
for( int i = 0; i <= nBin; i++) {
dataSeries->append(xMin + i * dX, 0 );
dataSeries->append(xMin + i * dX, 0 );
}
}
void Fill(double value){
double bin = (value - xMin)/dX;

View File

@ -2882,7 +2882,6 @@ void DigiSettingsPanel::SyncAllChannelsTab_PSD(){
SyncComboBox(cbVetoMode);
SyncComboBox(cbVetoStep);
}
void DigiSettingsPanel::UpdatePSDSetting(){