summaryrefslogtreecommitdiff
path: root/gnuradio-examples/python/digital/benchmark_qt_loopback.py
diff options
context:
space:
mode:
Diffstat (limited to 'gnuradio-examples/python/digital/benchmark_qt_loopback.py')
-rwxr-xr-xgnuradio-examples/python/digital/benchmark_qt_loopback.py39
1 files changed, 21 insertions, 18 deletions
diff --git a/gnuradio-examples/python/digital/benchmark_qt_loopback.py b/gnuradio-examples/python/digital/benchmark_qt_loopback.py
index e43bffa26..35cc2e376 100755
--- a/gnuradio-examples/python/digital/benchmark_qt_loopback.py
+++ b/gnuradio-examples/python/digital/benchmark_qt_loopback.py
@@ -52,7 +52,7 @@ class dialog_box(QtGui.QMainWindow):
self.set_frequency(self.fg.frequency_offset())
self.set_time_offset(self.fg.timing_offset())
- self.set_gain_mu(self.fg.rx_gain_mu())
+ self.set_gain_mu(self.fg.rx_timing_gain_alpha())
self.set_alpha(self.fg.rx_alpha())
# Add the qtsnk widgets to the hlayout box
@@ -158,7 +158,7 @@ class dialog_box(QtGui.QMainWindow):
def gainMuEditText(self):
try:
gain = self.gui.gainMuEdit.text().toDouble()[0]
- self.fg.set_rx_gain_mu(gain)
+ self.fg.set_rx_timing_gain_alpha(gain)
except RuntimeError:
pass
@@ -202,7 +202,7 @@ class my_top_block(gr.top_block):
self.rxpath = receive_path(demod_class, rx_callback, options)
# FIXME: do better exposure to lower issues for control
- self._gain_mu = self.rxpath.packet_receiver._demodulator._mm_gain_mu
+ self._timing_gain_alpha = self.rxpath.packet_receiver._demodulator._timing_alpha
self._alpha = self.rxpath.packet_receiver._demodulator._costas_alpha
if channelon:
@@ -240,16 +240,21 @@ class my_top_block(gr.top_block):
# Connect to the QT sinks
# FIXME: make better exposure to receiver from rxpath
- self.receiver = self.rxpath.packet_receiver._demodulator.receiver
+ self.freq_recov = self.rxpath.packet_receiver._demodulator.clock_recov
+ self.time_recov = self.rxpath.packet_receiver._demodulator.time_recov
+ self.freq_recov.set_alpha(0)
+ self.freq_recov.set_beta(0)
+ self.time_recov.set_alpha(2)
+ self.time_recov.set_beta(0.02)
self.connect(self.channel, self.snk_tx)
- self.connect(self.receiver, self.snk_rx)
+ self.connect(self.time_recov, self.snk_rx)
pyTxQt = self.snk_tx.pyqwidget()
pyTx = sip.wrapinstance(pyTxQt, QtGui.QWidget)
-
+
pyRxQt = self.snk_rx.pyqwidget()
pyRx = sip.wrapinstance(pyRxQt, QtGui.QWidget)
-
+
self.main_box = dialog_box(pyTx, pyRx, self)
self.main_box.show()
@@ -299,17 +304,15 @@ class my_top_block(gr.top_block):
# Receiver Parameters
- def rx_gain_mu(self):
- return self._gain_mu
+ def rx_timing_gain_alpha(self):
+ return self._timing_gain_alpha
- def rx_gain_omega(self):
- return self.gain_omega
+ def rx_timing_gain_beta(self):
+ return self._timing_gain_beta
- def set_rx_gain_mu(self, gain):
- self._gain_mu = gain
- self.gain_omega = .25 * self._gain_mu * self._gain_mu
- self.receiver.set_gain_mu(self._gain_mu)
- self.receiver.set_gain_omega(self.gain_omega)
+ def set_rx_timing_gain_alpha(self, gain):
+ self._timing_gain_alpha = gain
+ self.time_recov.set_gain(self._timing_gain_alpha)
def rx_alpha(self):
return self._alpha
@@ -320,8 +323,8 @@ class my_top_block(gr.top_block):
def set_rx_alpha(self, alpha):
self._alpha = alpha
self.beta = .25 * self._alpha * self._alpha
- self.receiver.set_alpha(self._alpha)
- self.receiver.set_beta(self.beta)
+ #self.freq_recov.set_alpha(self._alpha)
+ #self.freq_recov.set_beta(self.beta)