USRP Software Radio

cancel
Showing results for 
Search instead for 
Did you mean: 

Sessions, Devices, and Channels

In previous versions of the driver, if I defined more than one IP address in the "device names" field of an "open session" vi...then each USRP "device" was actually referred to as a "channel" according to the Property Nodes, or documentation of say a "Configure" vi..

 

In v1.3 of the driver, with the arrival of the new radios that are actually multi-channel within a single device, it is now less clear as to what the meaning of a "channel" is in the software.  There's now a section in the Help document called, "Scoping Rules" that refers to Devices as dev0, dev1, etc., and Channels within that device as "0, 1, etc.".  However...in most of the other documentation on the VI's and Property Nodes...the definitions seem more in line with previous versions of the driver.

 

Can someone help sort this out?  What exactly does the "Active Channel" property in the Property Node define/refer to?  And the "Enabled Channels" property?  Do these things have different meanings/behaviors depending on your hardware?

 

---
Brandon

0 Kudos
Message 1 of 2
(5,567 Views)

Good questions, and I'm glad we have a forum to clear them up.

 

There are Session, Device, and Channel attributes.  Session attributes apply to the whole session, and configure things that are not device or channel specific (e.g. Current Driver Version, Start Trigger configuration, etc.).  Device attributes configure properties that may vary across devices in the session, but apply to the whole device regardless of the number of channels (e.g. Model, Reference Frequency Source, etc.).  Channel attributes can vary from channel-to-channel, whether on the same device or on different devices (Gain, Carrier Frequency, etc.).

 

The "Active Channel" property in the property node allows you to specify the scope for all of the properties below the "Active Channel".  It is something of a misnomer because it can be used to scope an attribute to a device or session, not just channel.  This is simply an old naming convention that is used in IVI drivers in LabVIEW.  "Enabled Channels" actually specifies which channels in a multi-channel session you want to turn on for receiving/transmitting data.

 

Here are some useful things to know:

 

0) On the VIs that have the "channel list" terminal, that string means the same thing as "Active Channel" in the property node and can take the same values.

 

1) Channels are uniquely numbered in monotonically increasing order in a session.  For example,

   Single device, single channel (device names="192.168.10.2"): There is a single channel "0"

   Single device, multi-channel (device names="192.168.10.2"): There may be two channels, "0" and "1"

   Multi-device, single channel per device (device names="192.168.10.2;192.168.10.3"): The channel on the first device in the list is "0" and the channel on the second device is "1"

   Multi-device, multi-channel per device (device names="192.168.10.2;192.168.10.3"): The channels on the first device in the list are "0" and "1" and the channels on the second device are "2" and "3"

 

 

2) The "Active Channel" or "channel list" string allows you to scope attributes as specifically as you want to.  For example, say you want to specify the gain differently on each channel

 

   Multi-device, multi-channel per device session (device names="192.168.10.2;192.168.10.3")

        set Active Channel to "dev0/0"

        set Gain to 10  (sets gain on the first channel of device 192.168.10.2)

        set Active Channel to "dev1/3" 

        set Gain to 20 (sets gain on the second channel of device 192.168.10.3)

 

2b)  The driver is nice... since the channel numbers are unique, you can say either "dev0/0" or "0" and the driver will set the attribute on the appropriate channel

 

 

3) You can set multiple attributes at once by specifying a wider scope.

 

Let's say you have a multi-device, multi-channel per device session. So the channels are "dev0/0", "dev0/1", "dev1/2", "dev1/3".  If you set the Gain property with the scope

 

   "dev0/0"  : it only sets the Gain on that specific channel

   "dev0" : it sets the Gain on both channels of dev0 ("0" and "1")

   "" : it sets the Gain on all channels on all devices in the session ("0","1","2", and "3")

 

If you set the Reference Frequency Source property with the scope

 

   "dev0" : it only sets the Reference on the first device

   ""  : it sets the Reference on all devices in the session

   "dev0/0" : doesn't make sense because Reference Frequency Source is a device, not a channel, attribute

 

 

4) Similar rules apply to reading attribute values back, but you can get into trouble.  If you read an attribute with a wide scope (e.g. read Gain with a "" Active Channel) it will return a valid value ONLY if all of the channels in the session have the same value for that property.  Otherwise, you get an error.

 

5) Enabled Channels is a Session attribute, so the "Active Channel" property should be "" or just not set at all when you set that property.

 

   Let's say you have a multi-device, multi-channel per device session with channels "0", "1", "2", and "3".

   To enable only channels "0" and "2", set

      Active Channel = ""  (applies to entire session)

      Enabled Channels = "0,2"

 

 

Patrick

 

   

 

 

Message 2 of 2
(5,552 Views)