I am trying to write a GUI to do the transmissions made with the benchmark_tx.py example. For some reason, after sending the 3rd packet, my GUI would freeze and require force quit. I took code segments from GUI examples and benchmark_tx.py and I am not understanding why the GUI is freezing (and what causes it)
After importing the necessary libraries, I have a
#gui class class benchmark_gui (stdgui2.std_top_block):
st1 = wx.StaticText(self.panel, -1, "Input settings and hit enter", style=wx.ALIGN_CENTRE)
vbox.Add(st1, 1, wx.EXPAND | wx.TOP | wx.BOTTOM, 15)
#status reporting function def _set_status_msg(self, msg, which=0): self.frame.GetStatusBar().SetStatusText(msg, which)
and I simply copied the class from benchmark_tx.py like so:
#class for transmission class my_top_block(gr.top_block): def __init__(self, modulator, options): gr.top_block.__init__(self)
self.txpath = transmit_path(modulator, options) self.connect(self.txpath)
Basically, the code flows (from what I am understanding) as: the benchmark_gui is called, and then the user then input the settings, and upon hitting Enter, the code goes into _form_set function which takes the settings and then prepare the USRP to transmit at those settings, creates a my_top_block object, and then generate and send packets. I thought that by copying the settings i didnt touch from benchmark_tx, I should be able to run my GUI. But after the 3rd packet, the GUI freezes.