Documentation

Support Package Hardware Setup

Before you can work with the Communications System Toolbox™ Support Package for USRP® Radio, set up the connection between the host and the radio and make sure that they are communicating. To install software and configure the host computer, follow the steps in this section. When you have finished, use the check procedures to verify a connection.

  • The host computer can be a desktop or a laptop.

  • For Networked or X Series radios, the host computer must contain at least one dedicated gigabit Network Interface Card (NIC) for connecting to the USRP® radio. These instructions assume that you have one computer and a single NIC. If you have more than one NIC, follow the same setup and configuration workflow except where noted with the words Dedicated NIC

  • For Bus Series radios, the host computer must have one available USB port to connect to the radio.

Step 1. Install USB Driver for USRP® Bus Series Radios

Install USB Driver for Windows

Step 1. Install WinUSB Driver Information.  Click Next to install WinUSB driver information.

If you see this message from Windows®, click Install this driver software anyway. Click Next.

Step 2. Insert B200/B210 Radio into USB Port.  Insert a USB-based radio, such as a B200 or B210, into an available USB port on the host computer. When you click Next, Windows installs the device driver automatically.

When you see the messages shown in the following image in the system tray, click Next to continue. The next step is Step 4. Verify MATLAB Connection to USRP® Radio.

If you get a Windows message telling you it could not install the driver, try removing the radio and then reinserting the radio into the same or a different USB port. Windows then reinstalls the driver.

Install USB Driver for Linux

Step 1. Enable Non-Root Access to USB Devices.  On Linux® systems, install rules so that non-root users can access USB-based devices, such as B200 and B210.

The next step requires sudo privileges. If you do not have a sudo password, click Cancel and contact your network administrator to install this software.

Click Next to continue.

Step 2. Install Result.  If you see this screen, then you have successfully set the rules to allow non-root users access to the USB radios.

Click Next to continue. The next step is Step 4. Verify MATLAB Connection to USRP® Radio.

Install USB Driver for Mac

Start USB Driver Installation on Mac.  For Mac USB driver installation, compile and install a software library—libusb—that is required by the USRP® hardware driver (UHD).

This step requires that you have sudo privileges to install the driver. If you do not have a sudo password, click Cancel and contact your network administrator to install this software.

Click Next and enter your sudo password in the MATLAB® command window.

Xcode Not Found.  If you see the following message, your computer does not have the Xcode software and Command Line Tools installed. See Setup Warns "Xcode not Found" or "Xcode Command Line Tools not Found" for instructions on installing the required software.

Packages to Install (Mac).  If you see this message, one or more of the following packages is missing on the host machine.

  • GNU® Autoconf

  • GNU Automake

  • GNU Libtool

  • pkg-config

These packages are required by the installer to build the driver from the libusb library source code. The installation process installs any missing packages.

Build and Install Failed.  If you see this message, there was a problem building and installing the libusb software library.

Check the Common Problems and Fixes list for these possible reasons why the build and installation failed.

If you do not see the reason for your failure in that section, examine the build log carefully to see if you can discover the reason for the failure. For easier reading and navigation of the log, click Open in Editor to open the log in the MATLAB Editor. If you are able to identify and correct the problem, restart the installer by typing targetupdater in the MATLAB Command Window and choose "USRP(R) Radio".

If you cannot discern the error, contact Tech Support. Send the build log file to MathWorks® support for further investigation: http://www.mathworks.com/support/.

Build and Install Completed.  If you see the following message, the libusb software library was built and installed on your system successfully. You can now click Next exit the installer. Then, go to Step 4. Verify MATLAB Connection to USRP® Radio.

Step 2. Configure Host Computer for Ethernet Connection

Step 1. Check Firmware

The UHD firmware on the USRP® radio hardware must match the UHD firmware on the host computer. You may need to upgrade your radio's firmware. You can find the latest supported UHD version in the current Release Notes.

To check your radio's firmware, enter the following function at a MATLAB command prompt:

getSDRuDriverVersion

For more information about this function, see the reference page for getSDRuDriverVersion.

If you do need to upgrade the firmware, see USRP® Radio Firmware Update.

Step 2. Configure NIC

Setup Preparation.  Establish communications between the host computer and the USRP® hardware before using this SDR support package. This section describes how you configure the host computer to communicate with the USRP® device. Each operating system (OS) has instructions specific to that OS. Choose the instructions for the OS on the host computer.

Note the following:

  • You must have a dedicated gigabit NIC for the USRP® hardware.

    If you want to be connected to the network and the USRP® hardware, then your host computer requires a second NIC.

  • Connect your USRP® radio to the NIC on your host computer directly with an Ethernet cable.

  • USRP® radios have a default IP address of 192.168.10.2. This value is used for the radio IP address throughout the setup instructions, though it is possible you will want to use a different IP address for your radio.

    Note:   Some NICs might not be able to support high data throughput. You might encounter such cases if you set the decimation/interpolation rate of your USRP® device to a low value, for example, 4. Intel® chipsets provide high-quality connection in such cases.

Windows® 7 Setup.  Configure the NIC for your USRP® hardware by performing the following Windows task workflow.

  1. Select Control Panel from the Windows icon in the lower left corner of your monitor.

    In the upper right-hand corner, make sure View by is set to Category.

  2. Select Network and Internet.

  3. Select Network and Sharing Center.

  4. Select Change adapter settings on the left sidebar.

  5. Right-click the local area network connection that is connected to the USRP® device to get the popup menu. Select Properties.

      Dedicated NIC   If an unused NIC is available, the local area connection is displayed as "Unidentified network".

  6. On the Networking tab of the dialog box, clear options Clients for Microsoft Networks and File and Printer Sharing for Microsoft Networks. These services might cause intermittent connection problems with the USRP® radio sometimes.

  7. Double-click Internet Protocol Version 4 (TCP/IPv4).

  8. On the General tab, select Use the following IP Address.

  9. Set host IP Address to 192.168.10.X, where X is any number from 1 to 255 except 2.

    If your USRP® radio is on another subnet (the first three octets of the IP address field are not 192.168.10), then the IP address that you enter here must have the same subnet number. See Check Subnet Values on Host and Radio.

  10. Leave the subnet mask set to default (255.255.255.0).

  11. Click OK.

  12. Host configuration is complete. Continue to Step 3.Verify Hardware Connection.

Linux® Setup.  Configure the NIC for your USRP® hardware by performing the following Linux workflow:

  1. Set the correct host IP address (USRP® radios have a default IP address of 192.168.10.2). Leave the subnet mask set to default (255.255.255.0).

    If the USRP® radio IP address is the default value of 192.168.10.2, run the following shell command to set these values:

    %sudo ifconfig ethX 192.168.10.Y netmask 255.255.255.0

    Where ethX is the name of the host Ethernet port (usually eth0, eth1, etc.) and Y is any integer from 0 through 255 except 2. You might be required to enter a password to use the sudo command.

    If your USRP® radio is on another subnet (the first three octets of the IP address field are not 192.168.10), then the IP address that you enter here might have the same subnet number. See Check Subnet Values on Host and Radio.

  2. To check that the changes took effect, enter the following command in the shell:

    %ifconfig ethX

    Where ethX is the name of the host Ethernet port (usually eth0, eth1, etc.).

  3. Host configuration is complete. Continue to Step 3.Verify Hardware Connection.

Mac OS Setup.  Configure the NIC for your USRP® hardware by performing the following Mac OS workflow:

  1. Select System Preferences from the Apple icon in the upper left corner of your monitor.

  2. Select Network.

  3. From the left column, select the network connection that is connected to the USRP® device.

  4. Select the Ethernet connection from the leftmost side menu.

      Dedicated NIC   From the leftmost side menu, select the Ethernet port you connected your USRP® radio to, and go to step 6.

  5. From the Location drop-down menu, select Edit locations. Add a location by clicking the + sign. Name the new location USRP and click Done.

  6. Select Manually for Configure IPv4 option.

  7. Set IP Address to 192.168.10.X, where X is any number from 1 to 255 except 2.

    If your USRP® radio is on another subnet (the first three octets of the IP address field are not 192.168.10), then the IP address that you enter here should have the same subnet number. See Check Subnet Values on Host and Radio.

  8. Set the Subnet Mask to 255.255.255.0.

  9. You can ignore Router. Click Apply. You should see a window similar to the following image.

  10. Host configuration is complete. Continue to Step 3.Verify Hardware Connection.

Step 3.Verify Hardware Connection

Hardware Connection Checks

This section contains procedures for making sure each part of the host and hardware connection is configured and communicating successfully.

Check Ethernet Configuration

This section instructs you on how to make sure that all Ethernet cable and port connections and settings are optimal for host-hardware communication.

  1. Check that the USRP® radio is turned on.

  2. Check that the Ethernet cable is plugged into the host computer and the Ethernet LED is on.

  3. Check that the Ethernet cable is plugged into the USRP® radio and the Ethernet LEDs is on.

  4. If you have multiple Ethernet ports on your host computer, check that the USRP® radio is connected to the desired Ethernet port.

  5. Check that the TCP/IPv4 properties of the host Ethernet connection are as shown in Step 2. Configure Host Computer for Ethernet Connection.

  6. Check that the subnet value of the host and the USRP® radio are the same.

    Specifically, the first three octets of the IP address, for example, 192.168.10, of the host match the first three octects of the USRP® radio. See Check Subnet Values on Host and Radio.

If you are confident that each of these steps has been completed successfully, then the Ethernet configuration is most likely configured correctly, and you can continue on to the other connection checks.

Check OS-Radio Connection

Check Windows—Radio Connection.  Check if the host computer can communicate with the USRP® radio through the Ethernet port using the ping command.

  1. Open a command window using one of these methods:

    • Click the Start button. Select All Programs > Accessories > Command prompt.

    • Click the Start button. Type cmd in the Search programs and files edit field.

  2. Try to contact the USRP® radio using the ping command with IP address of the radio.

    C:\>ping 192.168.10.2

    If your USRP® radio has different IP address, use that IP address.

  3. If you get a response similar to the one shown in following image, then your connection is successful and you can go to the next step,Check Subnet Values on Host and Radio.

    If you get the message "Request timed out", see Check Ethernet Configuration.

Check Linux—Radio Connection.  Check the connection with the ping command the IP address of the USRP® radio.

  1. Open a shell and type the following command:

    %ping 192.168.10.2

    If your USRP® radio is on different subnet, use that IP address.

  2. If you get a response similar to the one shown in following image, then your connection is successful and you can go to the next step, Check Subnet Values on Host and Radio.

    If you get the message "Request timed out", see Check Ethernet Configuration.

Check MAC OS – Radio Connection.  Check if the host computer can communicate with the USRP® radio through the Ethernet port using the ping command.

  1. Open a terminal window:

    • Click Finder at the lower left corner of the screen

    • Click Applications on the leftmost side menu. Find Utilities on the main window and expand it. Right-click Terminal in the expanded list and select Open.

  2. Try to contact the USRP® radio using the ping command with IP address of the radio.

    % ping 192.168.10.2

    If your USRP® radio has another IP address, use that IP address instead.

  3. If you get a response similar to the one shown in following image, then your connection is successful and you can go to the next step, Step 4. Verify MATLAB Connection to USRP® Radio.

    If you get the message "Request timed out", see Check Ethernet Configuration.

Check Subnet Values on Host and Radio

This section helps you to make sure that the host and the USRP® radio have the same subnet values, which are necessary for successful communication.

Both Windows and Linux instructions use the ping command to check for a response from the hardware at the IP address you specify. If you get a response from the device, you can consider this step successful and move on to Step 4. Verify MATLAB Connection to USRP® Radio.

    Note:   You can skip this step if you already successfully ping-ed the radio from the host computer using the procedure in Check OS-Radio Connection. A successful ping confirms the subnet values on the host and radio are the same.

Windows.   The broadcast address on the LAN you connected your radio is the address with 255 as the final number. For example, if your address is 192.168.10.1, the broadcast address for the network is 192.168.10.255. Refer to Step 2. Configure Host Computer for Ethernet Connection to find out the address of your host computer.

Use the ping command to discover all devices connected to this port:

ping 192.168.10.255

In some systems, you may need to add a -b option: ping -b 192.168.10.255. The system output you see may look similar to the following graphic:

Linux  

  1. Run ifconfig in a Linux shell. Find the IP configuration of the Ethernet port you connected your radio.

    Alternatively, run ifconfig ethx, where eth is the Ethernet port and x is a number 0,1,2, etc.

  2. Note the broadcast address for this port, which is listed as Bcast:192.168.10.255.

  3. Use the ping command to discover all devices connected to this port:

    ping -b 192.168.10.255

    The system output you see make look similar to the following graphic:

Step 4. Verify MATLAB Connection to USRP® Radio

This step helps you to verify that MATLAB can communicate with the USRP® radio using the support package. If you get a successful status, it means that MATLAB can communicate with the USRP® radio and the radio is ready to be used.

  1. Type the following at the MATLAB command line:

    radios = findsdru

The variable, radios, is a structure that contains information on the USRP® radios connected to the host computer. If the function finds one or more radios, it returns an array of structures.

  • If the function cannot find a radio, MATLAB returns an empty IPAddress or SerialNum field or a status other than Success. See the section on Common Problems and Fixes for possible causes and solutions.

  • If the function finds one or more radios, MATLAB displays a message similar to the following.

    • Ethernet-connected radio:

           Platform: 'X310'
          IPAddress: '192.168.10.2'
          SerialNum: 'F4BF0D'
             Status: 'Success'
      
          Platform: 'N200/N210/USRP2'
          IPAddress: '192.168.20.2'
          SerialNum: '873'
             Status: 'Success'
      
    • USB-connected radio:

           Platform: 'B200'
          IPAddress: ''
          SerialNum: 'ECR04ZDBT'
             Status: 'Success'
      
Was this topic helpful?