Fix crash with missing gr.udp_source() in gnuradio-companion 3.7.7.1. Changed to blocks.udp_source().

This commit is contained in:
Ian Crawford 2015-05-26 13:01:58 -07:00
parent 93078a8cae
commit 3d1b95832a

View File

@ -219,7 +219,7 @@ class modes_radio (gr.top_block, pubsub):
ip, port = re.search("(.*)\:(\d{1,5})", options.source).groups() ip, port = re.search("(.*)\:(\d{1,5})", options.source).groups()
except: except:
raise Exception("Please input UDP source e.g. 192.168.10.1:12345") raise Exception("Please input UDP source e.g. 192.168.10.1:12345")
self._u = gr.udp_source(gr.sizeof_gr_complex, ip, int(port)) self._u = blocks.udp_source(gr.sizeof_gr_complex, ip, int(port))
print "Using UDP source %s:%s" % (ip, port) print "Using UDP source %s:%s" % (ip, port)
else: else:
self._u = blocks.file_source(gr.sizeof_gr_complex, options.source) self._u = blocks.file_source(gr.sizeof_gr_complex, options.source)