summaryrefslogtreecommitdiff
path: root/docs/exploring-gnuradio
diff options
context:
space:
mode:
Diffstat (limited to 'docs/exploring-gnuradio')
-rw-r--r--[-rwxr-xr-x]docs/exploring-gnuradio/dial_tone.py3
-rw-r--r--[-rwxr-xr-x]docs/exploring-gnuradio/fm_demod.py6
2 files changed, 6 insertions, 3 deletions
diff --git a/docs/exploring-gnuradio/dial_tone.py b/docs/exploring-gnuradio/dial_tone.py
index ba43c43bfc..42cbf3c9d0 100755..100644
--- a/docs/exploring-gnuradio/dial_tone.py
+++ b/docs/exploring-gnuradio/dial_tone.py
@@ -20,6 +20,7 @@
# Boston, MA 02110-1301, USA.
#
+from __future__ import unicode_literals
from gnuradio import gr
from gnuradio import audio
from gnuradio import analog
@@ -40,5 +41,5 @@ def build_graph():
if __name__ == '__main__':
tb = build_graph()
tb.start()
- raw_input('Press Enter to quit: ')
+ eval(input('Press Enter to quit: '))
tb.stop()
diff --git a/docs/exploring-gnuradio/fm_demod.py b/docs/exploring-gnuradio/fm_demod.py
index 8e8b6425f9..71d7f64c82 100755..100644
--- a/docs/exploring-gnuradio/fm_demod.py
+++ b/docs/exploring-gnuradio/fm_demod.py
@@ -20,6 +20,8 @@
# Boston, MA 02110-1301, USA.
#
+from __future__ import division
+from __future__ import unicode_literals
from gnuradio import gr
from gnuradio import blocks
from gnuradio import filter
@@ -46,7 +48,7 @@ class build_graph(gr.top_block):
# Set the demodulator using the same deviation as the receiver.
max_dev = 75e3
- fm_demod_gain = input_rate/(2*math.pi*max_dev/8.0)
+ fm_demod_gain = input_rate / (2*math.pi*max_dev/8.0)
fm_demod = analog.quadrature_demod_cf(fm_demod_gain)
# Create a filter for the resampler and filter the audio
@@ -80,7 +82,7 @@ class build_graph(gr.top_block):
def main(args):
tb = build_graph()
tb.start() # fork thread and return
- raw_input('Press Enter to quit: ')
+ eval(input('Press Enter to quit: '))
tb.stop()
if __name__ == '__main__':