0

为什么在执行 uhd_fft GNU Radio 脚本时收到以下错误消息:

/opt/gnuradio-3.7.1git/bin$ uhd_fft 
linux; GNU C++ version 4.6.3; Boost_104601; UHD_003.005.003-123-g1c391767

Traceback (most recent call last):
  File "/opt/gnuradio-3.7.1git/bin/uhd_fft", line 341, in <module>
    main ()
  File "/opt/gnuradio-3.7.1git/bin/uhd_fft", line 337, in main
    app = stdgui2.stdapp(app_top_block, "UHD FFT", nstatus=1)
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/wxgui/stdgui2.py", line 38, in __init__
    wx.App.__init__ (self, redirect=False)
  File "/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 7981, in __init__
    self._BootstrapApp()
  File "/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_core.py", line 7555, in _BootstrapApp
    return _core_.PyApp__BootstrapApp(*args, **kwargs)
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/wxgui/stdgui2.py", line 42, in OnInit
    self._max_noutput_items)
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/wxgui/stdgui2.py", line 64, in __init__
    self.panel = stdpanel (self, self, top_block_maker, max_nouts)
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/wxgui/stdgui2.py", line 86, in __init__
    self.top_block = top_block_maker (frame, self, vbox, sys.argv)
  File "/opt/gnuradio-3.7.1git/bin/uhd_fft", line 91, in __init__
    otw_format=options.wire_format, args=options.stream_args))
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/uhd/__init__.py", line 121, in constructor_interceptor
    return old_constructor(*args)
  File "/opt/gnuradio-3.7.1git/lib/python2.7/dist-packages/gnuradio/uhd/uhd_swig.py", line 1700, in make
    return _uhd_swig.usrp_source_make(*args)
RuntimeError: LookupError: KeyError: No devices found for ----->
Empty Device Address

我正在使用BladeRF 硬件并遵循这些说明

我已经阅读了此处列出的建议,但 UHD_FFT 似乎仍然无法找到 BladeRF,即使

ls -lrt /dev | grep blade
crw-------  1 root root    180,   0 Aug 11 14:04 bladerf0

为什么即使 linux 知道它的存在,UHD_FFT 也找不到我的设备?

4

1 回答 1

0

看起来您的 BladeRF 只能由 root 用户访问。要解决此问题,请制作一个 udev 规则文件(我知道您之前遵循的文章是否让您做了类似的事情,但请耐心等待)。这将允许您的常规用户帐户访问它。您可以通过键入以下内容在 shell 中启动:

$ sudo nano /etc/udev/rules.d/15-bladerf

这应该会创建一个新文件并打开 nano 编辑器。在这里,您将放置以下内容:

SUBSYSTEM=="usb", SYSFS{idVendor}=="1d50", SYSFS{idProduct}=="6066", MODE="0666"

然后,通过执行以下命令重置 udev 规则服务:

$ sudo /etc/init.d/udev restart

注意:此命令适用于任何基于 Debian 的操作系统(Debian、Ubuntu、Linux Mint...)

信用: udev 规则在这里找到http://pastebin.com/Mgb90L1x

于 2013-08-19T05:05:54.947 回答