Python gnuradio.gr.prefs() Examples
The following are 9
code examples of gnuradio.gr.prefs().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
gnuradio.gr
, or try the search function
.
Example #1
Source File: control_gui_override.py From gr-uaslink with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=control_gui, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() #connection_string = tb.sitl.connection_string() #print connection_string tb.connect_to_vehicle('udp:127.0.0.1:14562') tb.start() tb.show() # Connect to the Vehicle. #print("Connecting to vehicle on: %s" % (connection_string,)) #vehicle = connect(connection_string, wait_ready=True) def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #2
Source File: control_gui_override_mavutil.py From gr-uaslink with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=control_gui, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() #connection_string = tb.sitl.connection_string() #print connection_string #tb.connect_to_vehicle('udp:127.0.0.1:14552',baud_rate) tb.zmq_setup('tcp://127.0.0.1:14000') tb.start() tb.show() # Connect to the Vehicle. #print("Connecting to vehicle on: %s" % (connection_string,)) #vehicle = connect(connection_string, wait_ready=True) def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #3
Source File: control_gui_override_control.py From gr-uaslink with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=control_gui, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() #connection_string = tb.sitl.connection_string() #print connection_string #tb.connect_to_vehicle('udp:127.0.0.1:14552',baud_rate) tb.zmq_setup('tcp://127.0.0.1:14000') tb.start() tb.show() # Connect to the Vehicle. #print("Connecting to vehicle on: %s" % (connection_string,)) #vehicle = connect(connection_string, wait_ready=True) def quitting(): tb.running=False tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #4
Source File: control_gui_run.py From gr-uaslink with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=control_gui, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() tb.start() tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #5
Source File: control_gui.py From gr-uaslink with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=control_gui, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() tb.start() tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #6
Source File: rp_eclipse.py From piradar with GNU Affero General Public License v3.0 | 6 votes |
def main(top_block_cls=top_block, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string("qtgui", "style", "raster") Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() tb.start() if GUI: tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #7
Source File: os_uhf_rx.py From gr-opssat with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=os_uhf_rx, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() tb.start() tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #8
Source File: os_demod_decode.py From gr-opssat with GNU General Public License v3.0 | 6 votes |
def main(top_block_cls=os_demod_decode, options=None): from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication(sys.argv) tb = top_block_cls() tb.start() tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()
Example #9
Source File: scope.py From Thrifty with GNU General Public License v3.0 | 5 votes |
def gnuradio_main(samp_rate, gain, freq, block_size): import ctypes import sys if sys.platform.startswith('linux'): try: x11 = ctypes.cdll.LoadLibrary('libX11.so') x11.XInitThreads() except: print "Warning: failed to XInitThreads()" from distutils.version import StrictVersion if StrictVersion(Qt.qVersion()) >= StrictVersion("4.5.0"): style = gr.prefs().get_string('qtgui', 'style', 'raster') Qt.QApplication.setGraphicsSystem(style) qapp = Qt.QApplication([]) tb = scope(samp_rate, gain, freq, block_size) tb.start() tb.show() def quitting(): tb.stop() tb.wait() qapp.connect(qapp, Qt.SIGNAL("aboutToQuit()"), quitting) qapp.exec_()