With an USRP X300 and 2 daugthers boards LFTX (one fixed on A and the second on B), I need 2 outputs signals synchronized.
I programme in C++ language on Linux, UHD version 4.8.0.0
Result:
With an oscilloscope, the 2 outputs signals are monitored:
- Channel 0 => Ok, I see a sinusoidal signal, so it's seem ok
- Channel 1 => Ko, there is no sinusoidal signal, but I don't understand why !
Please, help me to resolve this problem ?
I programme in C++ language on Linux, UHD version 4.8.0.0
Result:
With an oscilloscope, the 2 outputs signals are monitored:
- Channel 0 => Ok, I see a sinusoidal signal, so it's seem ok
- Channel 1 => Ko, there is no sinusoidal signal, but I don't understand why !
Please, help me to resolve this problem ?
// USRP creation std::map<std::string,std::string> device{{"addr0","192.168.10.4}, {"master_clock_rate","184.32e6"}, {"clock_source","internal"}}; uhd::device_addr_t arg_device(device); usrp = uhd::usrp::multi_usrp::make(arg_device); // Front End of daughterboards std::string subdev("A:0 B:0"); usrp->set_tx_subdev_spec(subdev); // Configuration of channels usrp->set_tx_rate(rate, 0); usrp->set_tx_rate(rate, 1); uhd::tune_request_t tune_request(freq); usrp->set_tx_freq(tune_request, 0); usrp->set_tx_freq(tune_request, 1); usrp->set_tx_gain(1); usrp->set_tx_bandwith(bw, 0); usrp->set_tx_bandwith(bw, 1); usrp->set_tx_antenna("A", 0); usrp->set_tx_antenna("A", 1); // Init usrp->set_time_source("internal"); usrp->set_time_now(uhd::time_spec_t(0.0)); // Get streamer uhd::stream_args_t args("fc32", "sc16"); args.channel = {0, 1}; tx_stream = usrp->get_tx_stream(args); // Init PPS usrp->set_time_unknown_pps(uhd::time_spec_t(0.0)); // Metadata md.start_of_burst = true; md.end_of_burst = false; md.has_time_spec = true; md.time_spec = usrp->get_time_now() + uhd::time_spec_t(0.3)); // Data std::vector<std::complex<float>> buff0(nbEch); std::vector<std::complex<float>> buff1(nbEch); std::vector<std::complex<float>*> buffs; buffs.push_back(&buff0.front()); buffs.push_back(&buff1.front()); // Data for (size_t n=0; n < nbEch; n++) { buff0[n] = cos(2 * M_PI * 28000 * n); buff1[n] = 3 * cos((2 * M_PI * 28000 * n) + M_PI / 2); } // Send num_samps_sent = tx_stream->send(buffs, nbEch, md); |