16 #ifndef networkanalyzerH
17 #define networkanalyzerH
19 #include "primarydriverwiththread.h"
20 #include "xnodeconnector.h"
25 class Ui_FrmNetworkAnalyzer;
36 Transaction &tr_meas,
const shared_ptr<XMeasure> &meas);
43 double startFreq()
const {
return m_startFreq;}
45 unsigned int length()
const {
return m_trace.size();}
46 const std::complex<double> *trace()
const {
return &m_trace.at(0);}
48 std::vector<std::complex<double> > &trace_() {
return m_trace;}
50 double m_freqInterval;
53 std::vector<std::complex<double> > m_trace;
54 std::deque<std::pair<double, double> > m_markers;
66 const shared_ptr<XScalarEntry> &
marker1X()
const {
return m_marker1X;}
67 const shared_ptr<XScalarEntry> &marker1Y()
const {
return m_marker1Y;}
68 const shared_ptr<XScalarEntry> &marker2X()
const {
return m_marker2X;}
69 const shared_ptr<XScalarEntry> &marker2Y()
const {
return m_marker2Y;}
70 const shared_ptr<XDoubleNode> &startFreq()
const {
return m_startFreq;}
71 const shared_ptr<XDoubleNode> &stopFreq()
const {
return m_stopFreq;}
72 const shared_ptr<XComboNode> &points()
const {
return m_points;}
73 const shared_ptr<XUIntNode> &average()
const {
return m_average;}
74 const shared_ptr<XTouchableNode> &calOpen()
const {
return m_calOpen;}
75 const shared_ptr<XTouchableNode> &calShort()
const {
return m_calShort;}
76 const shared_ptr<XTouchableNode> &calTerm()
const {
return m_calTerm;}
77 const shared_ptr<XTouchableNode> &calThru()
const {
return m_calThru;}
87 virtual void getMarkerPos(
unsigned int num,
double &x,
double &y) = 0;
88 virtual void oneSweep() = 0;
89 virtual void startContSweep() = 0;
90 virtual void acquireTrace(shared_ptr<RawData> &,
unsigned int ch) = 0;
94 const shared_ptr<XWaveNGraph> &waveForm()
const {
return m_waveForm;}
95 const shared_ptr<XScalarEntry> m_marker1X;
96 const shared_ptr<XScalarEntry> m_marker1Y;
97 const shared_ptr<XScalarEntry> m_marker2X;
98 const shared_ptr<XScalarEntry> m_marker2Y;
99 const shared_ptr<XDoubleNode> m_startFreq;
100 const shared_ptr<XDoubleNode> m_stopFreq;
101 const shared_ptr<XComboNode> m_points;
102 const shared_ptr<XUIntNode> m_average;
103 const shared_ptr<XTouchableNode> m_calOpen, m_calShort, m_calTerm, m_calThru;
106 const shared_ptr<XWaveNGraph> m_waveForm;
108 shared_ptr<XListener> m_lsnOnStartFreqChanged;
109 shared_ptr<XListener> m_lsnOnStopFreqChanged;
110 shared_ptr<XListener> m_lsnOnPointsChanged;
111 shared_ptr<XListener> m_lsnOnAverageChanged;
112 shared_ptr<XListener> m_lsnCalOpen, m_lsnCalShort, m_lsnCalTerm, m_lsnCalThru;
114 std::deque<xqcon_ptr> m_conUIs;
116 shared_ptr<XGraph> m_graph;
117 shared_ptr<XXYPlot> m_markerPlot;