19 #include "primarydriverwiththread.h"
20 #include "xnodeconnector.h"
30 #include "xwavengraph.h"
35 XDSO(
const char *name,
bool runtime,
36 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
52 const shared_ptr<XUIntNode> &
average()
const {
return m_average;}
54 const shared_ptr<XBoolNode> &
singleSequence()
const {
return m_singleSequence;}
55 const shared_ptr<XComboNode> &trigSource()
const {
return m_trigSource;}
56 const shared_ptr<XDoubleNode> &trigPos()
const {
return m_trigPos;}
57 const shared_ptr<XDoubleNode> &trigLevel()
const {
return m_trigLevel;}
58 const shared_ptr<XBoolNode> &trigFalling()
const {
return m_trigFalling;}
59 const shared_ptr<XDoubleNode> &timeWidth()
const {
return m_timeWidth;}
60 const shared_ptr<XComboNode> &vFullScale1()
const {
return m_vFullScale1;}
61 const shared_ptr<XComboNode> &vFullScale2()
const {
return m_vFullScale2;}
62 const shared_ptr<XComboNode> &vFullScale3()
const {
return m_vFullScale3;}
63 const shared_ptr<XComboNode> &vFullScale4()
const {
return m_vFullScale4;}
64 const shared_ptr<XDoubleNode> &vOffset1()
const {
return m_vOffset1;}
65 const shared_ptr<XDoubleNode> &vOffset2()
const {
return m_vOffset2;}
66 const shared_ptr<XDoubleNode> &vOffset3()
const {
return m_vOffset3;}
67 const shared_ptr<XDoubleNode> &vOffset4()
const {
return m_vOffset4;}
68 const shared_ptr<XUIntNode> &recordLength()
const {
return m_recordLength;}
69 const shared_ptr<XTouchableNode> &forceTrigger()
const {
return m_forceTrigger;}
70 const shared_ptr<XTouchableNode> &restart()
const {
return m_restart;}
72 const shared_ptr<XComboNode> &trace1()
const {
return m_trace1;}
73 const shared_ptr<XComboNode> &trace2()
const {
return m_trace2;}
74 const shared_ptr<XComboNode> &trace3()
const {
return m_trace3;}
75 const shared_ptr<XComboNode> &trace4()
const {
return m_trace4;}
77 const shared_ptr<XComboNode> &fetchMode()
const {
return m_fetchMode;}
79 const shared_ptr<XBoolNode> &firEnabled()
const {
return m_firEnabled;}
80 const shared_ptr<XDoubleNode> &
firBandWidth()
const {
return m_firBandWidth;}
81 const shared_ptr<XDoubleNode> &
firCenterFreq()
const {
return m_firCenterFreq;}
82 const shared_ptr<XDoubleNode> &firSharpness()
const {
return m_firSharpness;}
84 enum DRFMODE {DRFMODE_OFF = 0, DRFMODE_GIVEN_FREQ = 1, DRFMODE_FREQ_BY_SG = 2, DRFMODE_COHERENT_SG = 3};
85 const shared_ptr<XComboNode> &dRFMode()
const {
return m_dRFMode;}
86 const shared_ptr<XItemNode<XDriverList, XSG> > &dRFSG()
const {
return m_dRFSG;}
87 const shared_ptr<XDoubleNode> &dRFFreq()
const {
return m_dRFFreq;}
90 Payload() : m_rawDisplayOnly(
false), m_numChannelsDisp(0) {}
91 double trigPos()
const {
return m_trigPos;}
92 unsigned int numChannels()
const {
return m_numChannels;}
93 double timeInterval()
const {
return m_timeInterval;}
94 unsigned int length()
const;
95 const double *wave(
unsigned int ch)
const;
97 void setParameters(
unsigned int channels,
double startpos,
double interval,
unsigned int length);
99 unsigned int lengthDisp()
const;
100 double *waveDisp(
unsigned int ch);
101 const double *waveDisp(
unsigned int ch)
const;
103 unsigned int numChannelsDisp()
const {
return m_numChannelsDisp;}
104 double timeIntervalDisp()
const {
return m_timeIntervalDisp;}
108 unsigned int m_numChannels;
109 double m_timeInterval;
115 unsigned int m_numChannelsDisp;
116 double m_timeIntervalDisp;
119 shared_ptr<FIR> m_fir;
146 virtual double getTimeInterval() = 0;
152 virtual int acqCount(
bool *seq_busy) = 0;
155 virtual void getWave(shared_ptr<RawData> &writer, std::deque<XString> &channels) = 0;
160 virtual bool isDRFCoherentSGSupported()
const {
return false;}
165 const shared_ptr<XStatusPrinter> &statusPrinter()
const {
return m_statusPrinter;}
167 shared_ptr<XListener> m_lsnOnTrigSourceChanged;
169 enum {FETCHMODE_NEVER = 0, FETCHMODE_AVG = 1, FETCHMODE_SEQ = 2};
171 const shared_ptr<XWaveNGraph> &waveForm()
const {
return m_waveForm;}
173 const shared_ptr<XUIntNode> m_average;
176 const shared_ptr<XComboNode> m_trigSource;
177 const shared_ptr<XBoolNode> m_trigFalling;
178 const shared_ptr<XDoubleNode> m_trigPos;
179 const shared_ptr<XDoubleNode> m_trigLevel;
180 const shared_ptr<XDoubleNode> m_timeWidth;
181 const shared_ptr<XComboNode> m_vFullScale1;
182 const shared_ptr<XComboNode> m_vFullScale2;
183 const shared_ptr<XComboNode> m_vFullScale3;
184 const shared_ptr<XComboNode> m_vFullScale4;
185 const shared_ptr<XDoubleNode> m_vOffset1;
186 const shared_ptr<XDoubleNode> m_vOffset2;
187 const shared_ptr<XDoubleNode> m_vOffset3;
188 const shared_ptr<XDoubleNode> m_vOffset4;
189 const shared_ptr<XUIntNode> m_recordLength;
190 const shared_ptr<XTouchableNode> m_forceTrigger;
191 const shared_ptr<XTouchableNode> m_restart;
192 const shared_ptr<XComboNode> m_trace1;
193 const shared_ptr<XComboNode> m_trace2;
194 const shared_ptr<XComboNode> m_trace3;
195 const shared_ptr<XComboNode> m_trace4;
196 const shared_ptr<XComboNode> m_fetchMode;
197 const shared_ptr<XBoolNode> m_firEnabled;
200 const shared_ptr<XDoubleNode> m_firSharpness;
202 const shared_ptr<XComboNode> m_dRFMode;
203 const shared_ptr<XItemNode<XDriverList, XSG> > m_dRFSG;
204 const shared_ptr<XDoubleNode> m_dRFFreq;
207 const shared_ptr<XWaveNGraph> m_waveForm;
214 shared_ptr<XListener> m_lsnOnSingleChanged;
215 shared_ptr<XListener> m_lsnOnAverageChanged;
216 shared_ptr<XListener> m_lsnOnTrigPosChanged;
217 shared_ptr<XListener> m_lsnOnTrigLevelChanged;
218 shared_ptr<XListener> m_lsnOnTrigFallingChanged;
219 shared_ptr<XListener> m_lsnOnTimeWidthChanged;
220 shared_ptr<XListener> m_lsnOnTrace1Changed;
221 shared_ptr<XListener> m_lsnOnTrace2Changed;
222 shared_ptr<XListener> m_lsnOnTrace3Changed;
223 shared_ptr<XListener> m_lsnOnTrace4Changed;
224 shared_ptr<XListener> m_lsnOnVFullScale1Changed;
225 shared_ptr<XListener> m_lsnOnVFullScale2Changed;
226 shared_ptr<XListener> m_lsnOnVFullScale3Changed;
227 shared_ptr<XListener> m_lsnOnVFullScale4Changed;
228 shared_ptr<XListener> m_lsnOnVOffset1Changed;
229 shared_ptr<XListener> m_lsnOnVOffset2Changed;
230 shared_ptr<XListener> m_lsnOnVOffset3Changed;
231 shared_ptr<XListener> m_lsnOnVOffset4Changed;
232 shared_ptr<XListener> m_lsnOnRecordLengthChanged;
233 shared_ptr<XListener> m_lsnOnForceTriggerTouched;
234 shared_ptr<XListener> m_lsnOnRestartTouched;
235 shared_ptr<XListener> m_lsnOnCondChanged;
236 shared_ptr<XListener> m_lsnOnDRFCondChanged;
241 std::deque<xqcon_ptr> m_conUIs;
243 const shared_ptr<XStatusPrinter> m_statusPrinter;
247 static const char *s_trace_names[];
248 static const unsigned int s_trace_colors[];