Main Content

Check USRP Radio Connection

Block Connection to USRP Radio

To verify that an SDRu block is connected to a USRP™ radio, examine the block mask by following these steps.

  1. Open the model that contains an SDRu Transmitter or SDRu Receiver block.

  2. Open the block mask by double-clicking the block. If the block is connected to the USRP radio, click info to return this information from the radio.

    • Mboard

    • RXSubdev

    • TXSubdev

    • MinimumCenterFrequency

    • MaximumCenterFrequency

    • MinimumGain

    • MaximumGain

    • GainStep

    Values going to the USRP radio are often quantized by the hardware. Clicking info also returns these actual device settings.

    • CenterFrequency

    • LocalOscillatorOffset

    • Gain

    • MasterClockRate

    • InterpolationFactor

    • BasebandSampleRate

If the block is not connected to the USRP radio, click info to return this message: "No device found at the specified IP address. Connect a USRP device to your host computer at the specified IP address or continue to work in off-line mode. You may need to close and reopen the dialog to detect the device."

Note

A block can connect to only one subdevice (transmitter or receiver) at a time, on the same IP address.

System Object Connection to USRP Radio

To verify that an SDRu System object™ is connected to a USRP radio, follow these steps.

  1. Create a transmitter or receiver by using the comm.SDRuTransmitter or comm.SDRuReceiver System object, respectively. For example, this code creates a transmitter System object.

    radio = comm.SDRuTransmitter;
  2. Report the status of all USRP radios connected to the host computer by using the findsdru function. This function finds the IP address, serial number, and status of each USRP radio connected to the host.

    a = findsdru()

    The function populates fields of the returned structure based on the connection and radio type, as shown in this list.

    • Ethernet-connected radios:

          Platform: 'N200/N210/USRP2'
          IPAddress: '192.168.20.2'
          SerialNum: '873'
             Status: 'Success'
      

    • USB-connected radios:

           Platform: 'B200'
          IPAddress: ''
          SerialNum: 'ECR04ZDBT'
             Status: 'Success'
      

If MATLAB® can communicate with the radio, the function returns a successful status for the USRP radio. After the radio establishes the communication with MATLAB, the radio is ready to use with Communications Toolbox™ Support Package for USRP Radio features.

If the function finds zero USRP radios, the function returns a structure containing an empty IPAddress field, an empty SerialNum field, and a status other than 'Success'. For more details on status messages other than 'Success', see the findsdru function. For possible causes of an unsuccessful connection of a USRP radio to the host computer and the corresponding solutions, see Common Problems and Fixes.

Note

A System object can connect to only one subdevice (transmitter or receiver) at a time, on the same IP address. If you change the property values of an SDRu System object and display the actual values, the object connects and disconnects to and from the subdevice after the properties are displayed. When you call the info object function, SDRu System objects connect to a subdevice and stay connected until you call the release object function.

Related Topics