When I try to use my USRP in GNU Radio, I get the message "No devices found for ----->"
When I try to run a GNU Radio program using USRP, I get a backtrace of the error, which (in Python) usually ends:
self.u = uhd.usrp_source(device_addr=args, stream_args=uhd.stream_args('fc32')) File "/home/marcus/.usrlocal/lib64/python2.7/site-packages/gnuradio/uhd/__init__.py", line 122, in constructor_interceptor return old_constructor(*args) File "/home/marcus/.usrlocal/lib64/python2.7/site-packages/gnuradio/uhd/uhd_swig.py", line 2351, in make return _uhd_swig.usrp_source_make(*args) RuntimeError: LookupError: KeyError: No devices found for -----> USRP is running.
First you must first check the original UHD function first with the uhd_find_devices tool:
uhd_find_devices If it does not find your device, although it is loaded, my experience is that you have a high probability of simply not talking to the device:
- If you are not using the UHD version from Ettus own repositories , especially on non-brand-new Ubuntus, your UHD may simply be older than the device and cannot talk to it. The first line of output
uhd_find_deviceswill contain version information. At the time of writing (October 2014), the latest version is 3.9. If possible, always use the latest version.- B200 / B210 needs at least 3.6.0, but functionality has improved significantly since 3.8.4.
- X300 / X310 needs at least 3.7.0
- B200mini needs 3.9
- USRP1 / 2 / B100 / N200 / N210 should be supported directly, but you will find the oldest versions in the wild. There are not many for all daughter boards that you can use with them - as already mentioned, try using the latest version.
- If you are using a connected USB device (USRP B200, B210, B200mini, B100, USRP1), most likely you are either
- on Linux: the udev rules necessary to allow "normal" users to contact USRP are not set check if
/etc/udev/rules.d/contains something likeuhd-usrp.rules. - on Windows: you may not have Windows USB drivers installed.
- if you yourself created UHD (also if you installed GNU Radio via
build-gnuradio.shorpybombs), there may have been no USB libraries. Make sure your UHD cmake logs contain “USB Enable”. - USB3: Some USB3 host controllers are not up to standard and cannot be reached. If your USRP is detected when connecting to the USB2 port (usually not blue), everything should be in order.
- on Linux: the udev rules necessary to allow "normal" users to contact USRP are not set check if
- If you are on a network device (USRP X300 / X310 with 1Gbit / 10Gbit Ethernet, USRP N200 / N210, USRP2)
- make sure your network interface
- 1Gbit-capable (or 10GE, if applicable); Fast Ethernet network interfaces (10/100 Mbit) do not work with USRP.
- Not an Intel 82579LM network controller (the only ICE controller on a PCI network controller that sometimes drops packets without specifying an operating system
- not a USB3-to-Gigabit adapter (they usually do interesting packet reordering, which makes them unsuitable for high-speed real-time samples)
- make sure your computer is on the same IP network. By default, USRPs have addresses in the range
192.168.10.XXX(XXX=2in the factory settings). Make sure your computer has an IP address from the same range, but not the same address. - make sure the basic communication operation (
ping <ip address of USRP>). If not, retest your own IP address and try to make sure that USRP is configured to the correct address.- To find out the current IP address of your USRP, it is often easier to correctly install
wireshark(this is a software for analyzing network packets), connect a dedicated network interface to (off USRP), start capturing to this interface and power to USRP. - If the address is incorrect, you can reprogram the IP address of USRP X300 / X310 :
cd <install-path>/lib/uhd/utils ; ./usrp_burn_mb_eeprom --args=addr=<current IP address> --values="ip-addr0=<new ip address>"cd <install-path>/lib/uhd/utils ; ./usrp_burn_mb_eeprom --args=addr=<current IP address> --values="ip-addr0=<new ip address>" - If the address is incorrect, you can reprogram the IP address of USRP N200 / N210 / USRP2 :
cd <install-path>/lib/uhd/utils ; ./usrp_burn_mb_eeprom --args=<optional device args> --values="ip-addr=192.168.10.3"cd <install-path>/lib/uhd/utils ; ./usrp_burn_mb_eeprom --args=<optional device args> --values="ip-addr=192.168.10.3"
- To find out the current IP address of your USRP, it is often easier to correctly install
- make sure your firewall is configured to allow traffic coming from port USRP 49152. On linux, the following
iptablescommand usually does the trick¹:sudo iptables -A INPUT -p udp --sport 49152 -j ACCEPT. Please note that this is punching a hole in your firewall. Your institution's security policies may apply.
- make sure your network interface
- If you are trying to use the USRP E100, E110, E310 or E312 connected to your PC:
- E-Series devices are stand-alone embedded SDRs for Linux; they do not attach to the PC as peripherals. You will have to compile your software (if applicable) using a cross-compiler and run the software on the E-Series device itself, and not on your PC.
As a quick check of the correct settings of your PC, USRP and cables and the IP configuration of the device, download the current GNU Radio Live DVD (which, by the way, also contains many interesting examples), download it and try uhd_find_devices there.
¹ your mileage may vary, since each distribution has its own idea on how to manage a firewall
² Please use torrent files if possible - Amazon AWS traffic is not free for GNU Radio supporters. The torrent file also uses the AWS server as a source, but is trying to get part of the image from other users.