aboutsummaryrefslogtreecommitdiffstats
path: root/python/trx
diff options
context:
space:
mode:
authorVadim Yanitskiy <axilirator@gmail.com>2017-10-18 18:15:52 +0700
committerPiotr Krysik <ptrkrysik@users.noreply.github.com>2017-11-05 17:33:26 +0100
commit9baaec24c6d0a1ffeb66000089d1f41a0d29bac9 (patch)
treed508277f953c343672538538e08a3ce0b5f11928 /python/trx
parent790b6f0cc10e8d4deea6611b52647ace7c3e2015 (diff)
trx/radio_if.py: get rid of useless getters / setters
We are only going to change the RF frequency and gain at runtime. Other parameters (like sample rate) should remain unchanged.
Diffstat (limited to 'python/trx')
-rw-r--r--python/trx/radio_if.py39
1 files changed, 0 insertions, 39 deletions
diff --git a/python/trx/radio_if.py b/python/trx/radio_if.py
index 0164cde..97a2160 100644
--- a/python/trx/radio_if.py
+++ b/python/trx/radio_if.py
@@ -126,51 +126,12 @@ class radio_if(gr.top_block):
self.stop()
self.wait()
- def get_args(self):
- return self.args
-
- def set_args(self, args):
- self.args = args
-
- def get_fc(self):
- return self.fc
-
def set_fc(self, fc):
self.phy.set_center_freq(fc - self.shiftoff, 0)
self.gsm_input.set_fc(fc)
self.fc_set = True
self.fc = fc
- def get_gain(self):
- return self.gain
-
def set_gain(self, gain):
self.phy.set_gain(gain, 0)
self.gain = gain
-
- def get_ppm(self):
- return self.ppm
-
- def set_ppm(self, ppm):
- self.rtlsdr_source_0.set_freq_corr(ppm, 0)
- self.ppm = ppm
-
- def get_samp_rate(self):
- return self.samp_rate
-
- def set_samp_rate(self, samp_rate):
- self.blocks_rotator.set_phase_inc(
- -2 * pi * self.shiftoff / samp_rate)
- self.gsm_input.set_samp_rate_in(samp_rate)
- self.phy.set_sample_rate(samp_rate)
- self.samp_rate = samp_rate
-
- def get_shiftoff(self):
- return self.shiftoff
-
- def set_shiftoff(self, shiftoff):
- self.blocks_rotator.set_phase_inc(
- -2 * pi * shiftoff / self.samp_rate)
- self.phy.set_bandwidth(250e3 + abs(shiftoff), 0)
- self.phy.set_center_freq(self.fc - shiftoff, 0)
- self.shiftoff = shiftoff