diff options
author | Andrej Rode <mail@andrejro.de> | 2018-06-23 23:41:42 +0200 |
---|---|---|
committer | Andrej Rode <mail@andrejro.de> | 2018-06-24 00:03:35 +0200 |
commit | 167a6152bad060fc53dd29e0fa79ef83eff1be5b (patch) | |
tree | a01049672d9d7d1bf3d295ed96698a323941f8e8 /gr-zeromq/examples/python | |
parent | 3c8e6008b092287246234001db7cf1a4038300da (diff) | |
parent | fcd002b6ac82e1e0c1224e24506410ff0833e1aa (diff) |
Merge branch 'python3_fix' into next
Manual merge conflict resolution has been applied to following
conflicts:
* Typos:
* gnuradio-runtime/python/gnuradio/ctrlport/GrDataPlotter.py
* gr-blocks/python/blocks/qa_wavfile.py
* gr-filter/examples/gr_filtdes_api.py
* grc/blocks/parameter.xml
* gr-uhd/python/uhd/__init__.py
* ValueError -> RuntimeError:
* gr-blocks/python/blocks/qa_hier_block2.py
* relative Imports & other Py3k:
* gr-digital/python/digital/psk_constellations.py
* gr-digital/python/digital/qam_constellations.py
* gr-digital/python/digital/test_soft_decisions.py
* gr-digital/python/digital/gfsk.py
* SequenceCompleter:
* gr-utils/python/modtool/modtool_add.py
* gr-utils/python/modtool/modtool_rename.py
* gr-utils/python/modtool/modtool_rm.py
* Updated API on next:
* gr-blocks/grc/blocks_file_source.xml
* gr-blocks/python/blocks/qa_file_source_sink.py
* gr-qtgui/grc/qtgui_time_sink_x.xml
* GRC Py3k Updates:
* grc/core/Block.py
* grc/core/Constants.py
* grc/core/Platform.py
* grc/core/utils/odict.py
* grc/gui/Actions.py
* grc/gui/Block.py
* grc/gui/Executor.py
* grc/gui/Port.py
Diffstat (limited to 'gr-zeromq/examples/python')
-rw-r--r--[-rwxr-xr-x] | gr-zeromq/examples/python/client.py | 10 | ||||
-rw-r--r--[-rwxr-xr-x] | gr-zeromq/examples/python/gui.py | 3 | ||||
-rw-r--r--[-rwxr-xr-x] | gr-zeromq/examples/python/server.py | 10 |
3 files changed, 14 insertions, 9 deletions
diff --git a/gr-zeromq/examples/python/client.py b/gr-zeromq/examples/python/client.py index ca7ad1830a..39055bd3fb 100755..100644 --- a/gr-zeromq/examples/python/client.py +++ b/gr-zeromq/examples/python/client.py @@ -1,3 +1,5 @@ +from __future__ import print_function +from __future__ import unicode_literals # # Copyright 2013 Free Software Foundation, Inc. # @@ -67,14 +69,14 @@ class top_block(gr.top_block): self.rpc_manager.start_watcher() def start_fg(self): - print "Start Flowgraph" + print("Start Flowgraph") try: self.start() except RuntimeError: - print "Can't start, flowgraph already running!" + print("Can't start, flowgraph already running!") def stop_fg(self): - print "Stop Flowgraph" + print("Stop Flowgraph") self.stop() self.wait() @@ -110,7 +112,7 @@ if __name__ == "__main__": time.sleep(1) except KeyboardInterrupt: pass - print "Shutting down flowgraph." + print("Shutting down flowgraph.") tb.rpc_manager.stop_watcher() tb.stop() tb.wait() diff --git a/gr-zeromq/examples/python/gui.py b/gr-zeromq/examples/python/gui.py index c932549408..832392f0a2 100755..100644 --- a/gr-zeromq/examples/python/gui.py +++ b/gr-zeromq/examples/python/gui.py @@ -1,3 +1,4 @@ +from __future__ import unicode_literals # # Copyright 2013 Free Software Foundation, Inc. # @@ -112,7 +113,7 @@ class gui(QtGui.QMainWindow): # plot the data from the queues def plot_data(self, plot, samples): - self.x = range(0,len(samples),1) + self.x = list(range(0,len(samples),1)) self.y = samples # clear the previous points from the plot plot.clear() diff --git a/gr-zeromq/examples/python/server.py b/gr-zeromq/examples/python/server.py index 23951664c1..b2cd8e8ef2 100755..100644 --- a/gr-zeromq/examples/python/server.py +++ b/gr-zeromq/examples/python/server.py @@ -1,3 +1,5 @@ +from __future__ import print_function +from __future__ import unicode_literals # # Copyright 2013 Free Software Foundation, Inc. # @@ -78,14 +80,14 @@ class top_block(gr.top_block): self.rpc_manager.start_watcher() def start_fg(self): - print "Start Flowgraph" + print("Start Flowgraph") try: self.start() except RuntimeError: - print "Can't start, flowgraph already running!" + print("Can't start, flowgraph already running!") def stop_fg(self): - print "Stop Flowgraph" + print("Stop Flowgraph") self.stop() self.wait() @@ -119,7 +121,7 @@ if __name__ == "__main__": time.sleep(1) except KeyboardInterrupt: pass - print "Shutting down flowgraph." + print("Shutting down flowgraph.") tb.rpc_manager.stop_watcher() tb.stop() tb.wait() |