Hi everyone, I need to develop a system which streams independent samples at different moments to the differents channels (channel 0 and channel 1) of an USRP X310.
To achieve that, I use the example codes available in the documentation which look like the following : // 1. Create the stream args object and initialize the data formats to fc32 and sc16:\ uhd::stream_args_t stream_args("fc32", "sc16");\ // 2. Set the channel list, we want 2 streamers coming from channels 0 and 1, in that order\ stream_args.channels = {0, 1};\ // Now use these args to create a tx streamer (We assume that usrp is a valid uhd::usrp::multi_usrp)\ uhd::tx_streamer::sptr tx_stream = usrp->get_tx_stream(stream_args);\ // Now, any calls to rx_stream must provide a vector of 2 buffers, one per channel.\ // Ex: tx_stream->send(buffs, 1024, md); (assuming buffs is a vector of 2 buffers) Then, I have created 2 threads, each thread will call the “tx_stream->send” function at different moments to stream samples through its corresponding channel (thread0 ==> channel0 and thread1 ==> channel1). My question is : how can I call the “tx_stream->send” function in each thread to send samples through only 1 of the channels ? Is there any other better method to achieve that ? Thank you very much for your support.
_______________________________________________ USRP-users mailing list -- usrp-users@lists.ettus.com To unsubscribe send an email to usrp-users-le...@lists.ettus.com