Trying to use latest version of UHD

Hi Josh and List,

I am now trying to use the latest version of UHD. I am working with one
or two USRP2s (I have previously worked successfully with up to four
USPR2s).

I tried the following which I though should be the way to handle a
general number of USRP2s (no_ant).

std::string abcd_string(“ABCDEFGHIJKLMNOPQRSTUVXYZ”);
uhd::usrp::subdev_spec_t abcd(":"+abcd_string.substr(0,no_ant));
d_mdev->set_rx_subdev_spec(abcd, uhd::usrp::multi_usrp::ALL_MBOARDS);
d_mdev->set_tx_subdev_spec(abcd, uhd::usrp::multi_usrp::ALL_MBOARDS);

However, I get the error:

error: Validate rx subdev spec failed: :AB
assertion failed:
is not a valid rx dboard name.
possible values are: [0].

Then I made a different intepretation and tried:

uhd::usrp::subdev_spec_t e(“0”);

for (uint32_t i1=0;i1<no_ant;i1++) {
d_mdev->set_rx_subdev_spec(e, i1);
d_mdev->set_tx_subdev_spec(e, i1);
}

However, the results are still in error.

??

BR/
Per

I fixed a typo and pushed it to the master. When you leave the dboard
name blank, and you have a single slot, it should use the name of the
only daughterboard slot on your usrp. Except for the typo…

So, to use the AB subdev on basic RX on usrp2, the following would work:

“0:AB”
“:AB” - was previously broken by the typo
“” - empty string automatically picks the first subdevice 0:AB

-josh

If I have “no_chan” usrp2 with XCVR2450 would this work:

uhd::usrp::subdev_spec_t e("");
for (uint32_t i1=0;i1<no_chan;i1++) {
d_mdev->set_rx_subdev_spec(e, i1);
d_mdev->set_tx_subdev_spec(e, i1);
};

Or should I write:

uhd::usrp::subdev_spec_t e(“0:A”);

?

BR/
Per

On 10/26/2010 11:25 PM, Per Z. wrote:

If I have “no_chan” usrp2 with XCVR2450 would this work:

uhd::usrp::subdev_spec_t e("");
for (uint32_t i1=0;i1<no_chan;i1++) {
d_mdev->set_rx_subdev_spec(e, i1);
d_mdev->set_tx_subdev_spec(e, i1);
};

This is the default behavior; the constructor is already doing this, so
it is not necessary. Unless you have USRP1 or a basic board, setting the
subdevice specification is not necessary since there is only one
possible choice and it is automatically selected.

Or should I write:

uhd::usrp::subdev_spec_t e(“0:A”);

That would probably fail, I believe that XCVR2450 has only one
sub-device named 0. So to this effect: “0:0” “:” “0:” “:0” would all
work for XCVR2450 on the USRP2. Also “” for the reason above.

So theres to ways to think about this:

  1. I know my usrp has only one daughterboard slot and I know my
    daugterboard has only one subdevice. So I am not gonna set anything
    special, because the automatic behavior is right for me.

  2. I like to explicit about things, I have a daughter board slot “0”,
    and on my daughterboard I have a subdevice “0”. So I am going to say,
    set this subdevice specification to “0:0”.

?

http://www.ettus.com/uhd_docs/manual/html/dboards.html#basic-rx-and-and-lfrx

http://www.ettus.com/uhd_docs/doxygen/html/classuhd_1_1usrp_1_1subdev__spec__t.html

http://www.ettus.com/uhd_docs/doxygen/html/classuhd_1_1usrp_1_1single__usrp.html#aafa207334ad368fc761602e2c965bc93

Yes, i agree, needs more documentation, zzzzz…

-Josh

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs