2022-09-23 17:43:30 -04:00
|
|
|
#ifndef CHANNEL_SETTING_PHA_H
|
|
|
|
#define CHANNEL_SETTING_PHA_H
|
2022-08-23 13:43:05 -04:00
|
|
|
|
|
|
|
#include <TQObject.h>
|
2022-09-22 16:26:33 -04:00
|
|
|
#include <RQ_OBJECT.h>
|
2022-08-23 13:43:05 -04:00
|
|
|
#include <TGNumberEntry.h>
|
2022-08-29 18:06:12 -04:00
|
|
|
#include <TGButton.h>
|
2022-08-23 13:43:05 -04:00
|
|
|
#include <TGComboBox.h>
|
|
|
|
#include <TGLabel.h>
|
|
|
|
#include "ClassDigitizer.h"
|
|
|
|
#include "macro.h"
|
|
|
|
|
|
|
|
class TGWindow;
|
|
|
|
class TGMainFrame;
|
|
|
|
|
2022-09-23 17:43:30 -04:00
|
|
|
class ChannelSettingPHA{
|
|
|
|
RQ_OBJECT("ChannelSettingPHA")
|
2022-08-23 13:43:05 -04:00
|
|
|
private:
|
|
|
|
TGMainFrame * fMain;
|
|
|
|
|
|
|
|
TGNumberEntry * boardIDEntry, * chIDEntry;
|
2022-09-22 16:26:33 -04:00
|
|
|
|
|
|
|
TGTextEntry * eTemp ;
|
|
|
|
|
2022-08-23 13:43:05 -04:00
|
|
|
TGComboBox * cbOnOff;
|
|
|
|
TGComboBox * cbPolarity;
|
2022-08-29 18:06:12 -04:00
|
|
|
TGComboBox * cbInputDynamicRange;
|
2022-09-22 16:26:33 -04:00
|
|
|
TGNumberEntry * numRecordLength;
|
|
|
|
TGNumberEntry * numPreTrigger;
|
|
|
|
TGNumberEntry * numEventAgg;
|
|
|
|
|
|
|
|
|
|
|
|
TGNumberEntry * numTriggerThreshold;
|
|
|
|
TGNumberEntry * numTriggerHoldOff;
|
|
|
|
TGNumberEntry * numDCOffset;
|
|
|
|
TGComboBox * cbTriggerSmoothing;
|
|
|
|
TGNumberEntry * numInputRiseTime;
|
|
|
|
TGNumberEntry * numRiseTimeValidWin;
|
|
|
|
TGComboBox * cbTriggerMode;
|
|
|
|
|
|
|
|
TGNumberEntry * numTrapRiseTime;
|
|
|
|
TGNumberEntry * numTrapFlatTop;
|
|
|
|
TGNumberEntry * numDecay;
|
|
|
|
TGNumberEntry * numPeaking;
|
|
|
|
TGNumberEntry * numPeakHoldOff;
|
|
|
|
TGComboBox * cbPeakMean;
|
|
|
|
TGComboBox * cbBaseLineAvg;
|
2022-08-23 13:43:05 -04:00
|
|
|
|
2022-09-22 16:26:33 -04:00
|
|
|
TGNumberEntry * numTrapScale;
|
|
|
|
TGComboBox * cbDecimation;
|
|
|
|
TGComboBox * cbDecimationGain;
|
|
|
|
TGComboBox * cbRollOver;
|
|
|
|
TGComboBox * cbPileUp;
|
|
|
|
TGComboBox * cbLocalShapedTrigger;
|
|
|
|
|
|
|
|
TGComboBox * cbLocalTriggerValid;
|
|
|
|
TGComboBox * cbVetoSource;
|
|
|
|
TGComboBox * cbTriggerCounterRate;
|
|
|
|
TGComboBox * cbBaselineCal;
|
|
|
|
TGComboBox * cbTagCorrelatedEvent;
|
|
|
|
TGComboBox * cbBaselineOptimize;
|
|
|
|
|
|
|
|
TGComboBox * cbDisableSelfTrigger;
|
|
|
|
TGComboBox * cbExtra2WordOption;
|
|
|
|
|
2022-08-23 13:43:05 -04:00
|
|
|
Digitizer ** digi;
|
2022-09-23 17:43:30 -04:00
|
|
|
int nDigi;
|
|
|
|
int NChannel; // hard coded = 16
|
2022-09-22 16:26:33 -04:00
|
|
|
bool isOpened;
|
2022-09-22 17:53:29 -04:00
|
|
|
|
2022-09-23 17:43:30 -04:00
|
|
|
int presentBoardID;
|
|
|
|
|
2022-09-22 17:53:29 -04:00
|
|
|
unsigned short ch2ns;
|
|
|
|
|
|
|
|
void ChangeAStep(TGNumberEntry * numEntry, unsigned short stepSize, uint32_t address);
|
2022-08-23 13:43:05 -04:00
|
|
|
|
|
|
|
public:
|
2022-09-23 17:43:30 -04:00
|
|
|
ChannelSettingPHA(const TGWindow *p, UInt_t w, UInt_t h, Digitizer ** digi, int nDigi, int boardID);
|
|
|
|
virtual ~ChannelSettingPHA();
|
2022-09-22 16:26:33 -04:00
|
|
|
|
|
|
|
void CloseWindow() { delete this; }
|
|
|
|
|
|
|
|
bool IsOpen() {return isOpened;}
|
|
|
|
|
2022-08-23 13:43:05 -04:00
|
|
|
void ChangeBoard();
|
2022-09-22 16:26:33 -04:00
|
|
|
void ChangeCh(); /// also get all settings
|
|
|
|
|
|
|
|
void SetAllChannels();
|
|
|
|
|
|
|
|
void SetChannelMask();
|
|
|
|
void SetDPPAlgorithm1();
|
|
|
|
void SetDPPAlgorithm2();
|
|
|
|
|
|
|
|
void SetInputDynamicRange();
|
|
|
|
void SetRecordLength();
|
|
|
|
void SetPreTrigger();
|
|
|
|
void SetEventAggregate();
|
|
|
|
|
|
|
|
void SetTriggerThreshold();
|
|
|
|
void SetTriggerHoldOff();
|
|
|
|
void SetDCOffset();
|
|
|
|
|
|
|
|
void SetTriggerSmoothing();
|
|
|
|
void SetInputRiseTime();
|
|
|
|
void SetRiseTimeValidWin();
|
|
|
|
|
|
|
|
void SetTrapRiseTime();
|
|
|
|
void SetTrapFlatTop();
|
|
|
|
void SetDecay();
|
|
|
|
void SetPeaking();
|
|
|
|
void SetPeakHoldOff();
|
|
|
|
|
2022-09-23 12:36:31 -04:00
|
|
|
void LogMsg(TString msg); // *SIGNAL*
|
2022-09-22 16:26:33 -04:00
|
|
|
|
2022-08-23 13:43:05 -04:00
|
|
|
};
|
|
|
|
#endif
|