summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgr-radio-astronomy/src/python/usrp_psr_receiver.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/gr-radio-astronomy/src/python/usrp_psr_receiver.py b/gr-radio-astronomy/src/python/usrp_psr_receiver.py
index 8a5593706..a14f59864 100755
--- a/gr-radio-astronomy/src/python/usrp_psr_receiver.py
+++ b/gr-radio-astronomy/src/python/usrp_psr_receiver.py
@@ -30,6 +30,7 @@
#
#
from gnuradio import gr, gru, blks, audio
+import usrp_dbid
from gnuradio import usrp, optfir
from gnuradio import eng_notation
from gnuradio.eng_option import eng_option
@@ -222,6 +223,7 @@ class app_flow_graph(stdgui.gui_flow_graph):
# determine the daughterboard subdevice we're using
self.subdev = usrp.selected_subdev(self.u, options.rx_subdev_spec)
+ self.cardtype = self.u.daughterboard_id(0)
# Compute raw input rate
input_rate = self.u.adc_freq() / self.u.decim_rate()
@@ -230,6 +232,12 @@ class app_flow_graph(stdgui.gui_flow_graph):
self.bw = input_rate
#
+ # Set baseband filter bandwidth if DBS_RX:
+ #
+ if self.cardtype == usrp_dbid.DBS_RX:
+ self.subdev.set_bw((self.u.adc_freq() / self.u.decim_rate())/2)
+
+ #
# We use this as a crude volume control for the audio output
#
self.volume = gr.multiply_const_ff(10**(-1))