Re: [USRP-users] Help with uhd

2018-03-17 Thread Marcus Müller via USRP-users
Dear Shehasish,

Marcus Leech already responded to your last mail.

We can't help you without all your code, especially whatever sets up
"args2954R".

Best regards,
Marcus M

On Sat, 2018-03-17 at 06:22 +, Snehasish Kar via USRP-users wrote:
> hello 
> 
> On trying to use an multi usrp shared pointer, I get the following
> error in rfnoc enviroment:
> 
> Error: TypeError: [0/FIFO_1] Invalid output port number (ANY).
> 
> I declared the shared pointer as below
> 
> uhd::usrp::multi_usrp::sptr usrp_temp =
> uhd::usrp::multi_usrp::make(args2954R);
> uhd::device3::sptr usrp = usrp_temp->get_device3();
> 
> Any idea where I am going wrong.
> 
> BR
> Snehasish
> 
> 
> ___
> USRP-users mailing list
> USRP-users@lists.ettus.com
> http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com

___
USRP-users mailing list
USRP-users@lists.ettus.com
http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com


Re: [USRP-users] Help with uhd

2018-03-17 Thread Snehasish Kar via USRP-users
Hello Marcus

Sorry, but I didn't receive a copy of my previous mail or your response, so I 
posted again.

For your reference below is my code:

#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 
#include 

#define USRP_2954_R 0
#define USRP_2955_R 1
#define db_0 0
#define db_1 1

namespace po = boost::program_options;
double centre_freq_2954_db0 = 947.8e6;
double centre_freq_2954_db1 = 947.8e6-45e6;
static bool stop_signal_called = false;

void sig_int_handler(int){stop_signal_called = true;}

void recv_to_file(
uhd::rx_streamer::sptr rx_stream,
size_t samps_per_buff,
unsigned long long num_requested_samples,
bool continue_on_bad_packet = false
) {
unsigned long long num_total_samps = 0;

uhd::rx_metadata_t md;
std::vector > buff(samps_per_buff);
std::ofstream outfile;
#if 1
//outfile.open("/media/ramdd/rxfile.bin", std::ofstream::binary);
FILE *fp = fopen("/media/ramdd/rxfile.bin","w");
#endif
bool overflow_message = true;

//setup streaming
uhd::stream_cmd_t stream_cmd((num_requested_samples == 0)?
uhd::stream_cmd_t::STREAM_MODE_START_CONTINUOUS:
uhd::stream_cmd_t::STREAM_MODE_NUM_SAMPS_AND_DONE
);
stream_cmd.num_samps = num_requested_samples;
stream_cmd.stream_now = true;
stream_cmd.time_spec = uhd::time_spec_t();
std::cout << "Issuing start stream cmd" << std::endl;
// This actually goes to the null source; the processing block
// should propagate it.
rx_stream->issue_stream_cmd(stream_cmd);
unsigned long long last_update_samps = 0;

while(
not stop_signal_called
and (num_requested_samples != num_total_samps or num_requested_samples 
== 0)
) {
size_t num_rx_samps = rx_stream->recv(&buff.front(), buff.size(), md, 3.0);
std::cout<<"number of samples "<),num_rx_samps,fp);
#endif
#if 0
if (bw_summary) {
last_update_samps += num_rx_samps;
boost::posix_time::time_duration update_diff = now - last_update;
if (update_diff.ticks() > 
boost::posix_time::time_duration::ticks_per_second()) {
double t = (double)update_diff.ticks() / 
(double)boost::posix_time::time_duration::ticks_per_second();
double r = (double)last_update_samps / t;
std::cout << boost::format("\t%f Msps") % (r/1e6) << std::endl;
last_update_samps = 0;
last_update = now;
}
}

ticks_diff = now - start;
if (ticks_requested > 0){
if ((unsigned long long)ticks_diff.ticks() > ticks_requested)
break;
}
#endif
}

stream_cmd.stream_mode = uhd::stream_cmd_t::STREAM_MODE_STOP_CONTINUOUS;
rx_stream->issue_stream_cmd(stream_cmd);

#if 1
fclose(fp);
#endif
}
void pretty_print_flow_graph(std::vector blocks)
{
std::string sep_str = "==>";
std::cout << std::endl;
// Line 1
for (size_t n = 0; n < blocks.size(); n++) {
const std::string name = blocks[n];
std::cout << "+";
for (size_t i = 0; i < name.size() + 2; i++) {
std::cout << "-";
}
std::cout << "+";
if (n == blocks.size() - 1) {
break;
}
for (size_t i = 0; i < sep_str.size(); i++) {
std::cout << " ";
}
}
std::cout << std::endl;
// Line 2
for (size_t n = 0; n < blocks.size(); n++) {
const std::string name = blocks[n];
std::cout << "| " << name << " |";
if (n == blocks.size() - 1) {
break;
}
std::cout << sep_str;
}
std::cout << std::endl;
// Line 3
for (size_t n = 0; n < blocks.size(); n++) {
const std::string name = blocks[n];
std::cout << "+";
for (size_t i = 0; i < name.size() + 2; i++) {
std::cout << "-";
}
std::cout << "+";
if (n == blocks.size() - 1) {
break;
}
for (size_t i = 0; i < sep_str.size(); i++) {
std::cout << " ";
}
}
std::cout << std::endl << std::endl;
}

#if 1
int c onfigure(int mboard_no, int dboard_no, uhd::device3::sptr usrp){
uhd::rfnoc::radio_ctrl::sptr radio_ctrl;
uhd::rfnoc::block_ctrl_base::sptr chan128_ctrl;
std::string downsample_make;
//uhd::rfnoc::block_ctrl_base::sptr downSampler;
uhd::rfnoc::block_ctrl_base::sptr fifo;
//uhd::rfnoc::
uhd::rfnoc::downSampler_block_ctrl::sptr downSampler;
usrp->clear();
uhd::rfnoc::block_ctrl_base::sptr packetresizer_ctrl;
std::string  file, format, ant, subdev, ref, wirefmt, streamargs, block_id, 
block_args;
size_t total_num_samps, spp = 128, spb=10e3;
double sampleRate = 0x00;
std::string radio_args("Radio channel");
std::vector blocks;

uhd::device_addr_t stream_args_args;
usrp->clear();
uhd::rfnoc::graph::sptr rx_graph = usrp->create_graph("GSM_RF_

Re: [USRP-users] Product Announcement: Simplifying Deployment of Software Defined Radios with USRP N310

2018-03-17 Thread hossein talaiee via USRP-users
Hi
When schematics will be available?

On Tue, Mar 6, 2018 at 7:38 PM, Wan Liu via USRP-users <
usrp-users@lists.ettus.com> wrote:

> Ettus Research is proud to announce the USRP N310 software defined radio
> (SDR). This SDR delivers reliability and fault-tolerance for deployment in
> large-scale and distributed wireless systems. The USRP N310 simplifies
> control and management of a network of radios by introducing the unique
> capability to remotely perform tasks such as updating software, rebooting,
> factory resetting, self-testing, host PC/ARM debugging, and monitoring
> system health.
>
> The USRP N310 is one of the highest channel density devices on the SDR
> market, offering four RX and four TX channels in a half-wide RU form
> factor. The RF front end uses two AD9371 transceivers, the latest RFIC
> technology from Analog Devices. Each channel provides up to 100 MHz of
> instantaneous bandwidth, and covers an extended frequency range from 10 MHz
> to 6 GHz.
>
> The baseband processor uses the Xilinx Zynq-7100 SoC to deliver a large
> user programmable FPGA for real-time and low-latency processing and a
> dual-core ARM CPU for stand-alone operation. Users can deploy applications
> directly onto the pre-installed embedded Linux operating system or stream
> samples to a host computer using high-speed interfaces such as 1 Gigabit
> Ethernet, 10 Gigabit Ethernet, and Aurora over dual SFP+ ports.
>
> The open source USRP Hardware Driver™ (UHD) API and RF Network-on-Chip
> (RFNoC™) FPGA development framework reduce software development effort and
> integrate with a variety of industry-standard tools such as GNU Radio.
> Users can rapidly prototype and reliably deploy designs for a variety of
> SDR applications such as wireless testbed, remote radio head, spectrum
> monitoring, and more.
> For more information, visit the USRP N310
>  product page or contact
> sa...@ettus.com.
>
> Product Page:
> https://www.ettus.com/product/details/USRP-N310
>
> Regards,
>
> Wan Liu
> Product Manager, Software Defined Radio
> Ettus Research
>
>
> ___
> USRP-users mailing list
> USRP-users@lists.ettus.com
> http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com
>
>
___
USRP-users mailing list
USRP-users@lists.ettus.com
http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com