The issue is on your output side. It has been explained to me (I think it is
somewhere on this mailing list due to an issue I and other have had), that you
can't mix ports to be both host and rfnoc streams on the same side of the RFNoC
block. So it sounds like the input side has both inputs coming from the RFNoC
stream, that is fine. On the other side it sounds like one output stays in the
RFNoC stream, and the other goes directly the the host. I believe that that is
a no-no.
They either both need to go to the host, or both stay in RFNoC land (it doesn't
have to be the same domain as the input, just the same on that side of the
block). I would try throwing an RFNoC FIFO on your output that goes to the
host domain. See if that makes things work for you.
--------- Original Message --------- Subject: [USRP-users] "No upstream blocks"
Warning
From: "Sebastian Bräuer via USRP-users" <[email protected]>
Date: 9/7/18 5:21 am
To: "[email protected]" <[email protected]>
Hi,
I am currently working on a custom rfnoc block that needs input from the
DDC but also gets samples from the host and sends them to the radio via
the DUC. The block works perfectly in simulation and even in gnuradio
but for some reason I cant get it to work in pure UHD. In my UHD code I
always get a "No upstream blocks" warning from the DDC block and nothing
happens.
No reception and no transmission (No light on the panel) and the
registers in my block indicate that no data is flowing but UHD happily
transmits data to the FPGA.
Some info about my setup:
I am working on an X310 with the rate set to 184.32e6. My custom block
has two inputs and two outputs. Input 0 is wired to the DmaFifo and
Input 1 is connected to the DDC. Output 0 is connected to the DDC for
transmission while output 1 streams to the host.
I don't know if the warning is directly related to my problem but it is
my only guess, since it works in gnuradio. Any help would be appreciated.
The code below reproduces the warning (Unfortunately, I cant show you my
actual code):
> #include<uhd/device3.hpp>
> #include<uhd/rfnoc/radio_ctrl.hpp>
> #include<uhd/rfnoc/block_ctrl.hpp>
> #include<uhd/rfnoc/source_block_ctrl_base.hpp>
>
> int main(int argc, char *argv[]){
> uhd::device3::sptr dev;
> uhd::device_addr_t hint;
>
> hint["addr"] = "192.168.10.2";
>
> std::cout << "Opening USRP...\n";
> dev = uhd::device3::make(hint);
>
> //Block Declaration
> uhd::rfnoc::radio_ctrl::sptr radio0;
> uhd::rfnoc::block_ctrl_base::sptr lbt;
> uhd::rfnoc::source_block_ctrl_base::sptr ddc;
> uhd::rfnoc::source_block_ctrl_base::sptr duc;
> uhd::rfnoc::source_block_ctrl_base::sptr dmaFifo;
>
> uhd::rfnoc::block_id_t radio_id_0(0, "Radio", 0);
> uhd::rfnoc::block_id_t lbt_id(0, "lbt", 0);
> uhd::rfnoc::block_id_t duc_id(0, "DUC", 0);
> uhd::rfnoc::block_id_t ddc_id(0, "DDC", 0);
> uhd::rfnoc::block_id_t dmaFifo_id(0, "DmaFIFO", 0);
>
> radio0 = dev->get_block_ctrl<uhd::rfnoc::radio_ctrl>(radio_id_0);
> lbt = dev->get_block_ctrl<uhd::rfnoc::block_ctrl_base>(lbt_id);
> ddc = dev->get_block_ctrl<uhd::rfnoc::source_block_ctrl_base>(ddc_id);
> duc = dev->get_block_ctrl<uhd::rfnoc::source_block_ctrl_base>(duc_id);
> dmaFifo =
> dev->get_block_ctrl<uhd::rfnoc::source_block_ctrl_base>(dmaFifo_id);
>
> dev->clear();
>
> uhd::rfnoc::graph::sptr graph;
> graph = dev->create_graph("lbt_test");
>
> graph->connect(radio_id_0,0, ddc_id,0);
> graph->connect(duc_id,0, radio_id_0,0);
>
> graph->connect(lbt_id,0,duc_id,0);
>
> graph->connect(ddc_id,0,lbt_id,1);
> graph->connect(dmaFifo_id,0,lbt_id,0);
>
> uhd::stream_args_t tx_args("fc32","sc16");
> tx_args.args["block_id"] = dmaFifo_id;
>
> uhd::stream_args_t rx_args("fc32","sc16");
> rx_args.args["block_id"] = lbt_id;
> rx_args.args["block_port"] = "1";
>
> radio0->set_rx_streamer(true, 0);
> radio0->set_tx_streamer(true, 0);
>
> uhd::tx_streamer::sptr tx_stream = dev->get_tx_stream(tx_args);
> uhd::rx_streamer::sptr rx_stream = dev->get_rx_stream(rx_args);
>
> uhd::stream_cmd_t
> cmd(uhd::stream_cmd_t::STREAM_MODE_START_CONTINUOUS);
> rx_stream->issue_stream_cmd(cmd);
> }
_______________________________________________
USRP-users mailing list
[email protected]
http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com
_______________________________________________
USRP-users mailing list
[email protected]
http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com