FSUDAQ/channelSettingPHA.h

122 lines
2.9 KiB
C
Raw Normal View History

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>
#include <RQ_OBJECT.h>
2022-08-23 13:43:05 -04:00
#include <TGNumberEntry.h>
#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;
TGTextEntry * eTemp ;
TGTextEntry * txtSPIBus;
TGTextEntry * txtADCCaliStatus;
TGTextEntry * txtADCPowerStatus;
2022-08-23 13:43:05 -04:00
TGComboBox * cbOnOff;
TGComboBox * cbPolarity;
TGComboBox * cbInputDynamicRange;
TGNumberEntry * numRecordLength;
TGNumberEntry * numPreTrigger;
TGNumberEntry * numEventAgg;
TGTextEntry * eBuffer ;
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
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-09-23 17:43:30 -04:00
int NChannel; // hard coded = 16
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:
ChannelSettingPHA(const TGWindow *p, UInt_t w, UInt_t h, int boardID);
2022-09-23 17:43:30 -04:00
virtual ~ChannelSettingPHA();
void CloseWindow() { delete this; }
bool IsOpen() {return isOpened;}
2022-08-23 13:43:05 -04:00
void ChangeBoard();
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();
void ReadTrace();
2022-09-23 12:36:31 -04:00
void LogMsg(TString msg); // *SIGNAL*
void SendPlotTraceCmd(); // *SIGNAL*
2022-08-23 13:43:05 -04:00
};
#endif