usrp-users@lists.ettus.com

Discussion and technical support related to USRP, UHD, RFNoC

View all threads

IQ-sample rate for RX/TX B200

FL
Felix Langer
Wed, Feb 7, 2018 3:42 PM

Hi everyone,

Since a few days, I started using the USRP B200 for transmitting and receiving IQ-samples to and from a spectrum analyzer/signal generator. For this purpose, I am using UHD's example functions "rx_samples_to_file" and "tx_samples_from_file". To test the RX and TX characteristics of the B200, I am generating sine-waves with specific frequencies and write/read the IQ-samples of the wave to/from binary data files.

I have noticed a difference in the effect of the sampling rate that I can tune in the UHD-functions mentioned above:

If I send the IQ-samples to the signal generator with a specific sampling rate (e.g. 20MHz) and use the B200 for RX, I need to tune the sampling rate of the USRP to twice the sampling rate of the signal generator (e.g. 40MS/s) for correct downconversion of the signal. So I am assuming the sample rate for the USRP is defined as 1 sample for I and 1 sample for Q, meaning 2 samples for 1IQ-value. Is this correct? With this setting I see the peak of the FFT-plot of the received signal at the frequency of the sine-wave that I generated (as expected).

However, for the counterpart of sending the IQ-data with the USRP (TX) to a spectum analyzer, I need to tune the sampling rate of the USRP to exactly the same sampling rate as for my analyzer (e.g. 20MHz at analyzer, 20MS/s at USRP) to observe the correct FFT-plot. If I tune the USRP sampling rate to 40MS/s (like above for RX) the peaks of my FFT-plot are at twice the frequency of the sine-wave (I receive the wave with twice the frequency).

So my question: Is the sampling rate of the UHD RX and TX functions defined differently? I tried using only the signal generator and spectrum analyzer for TX/RX and it works using the same sampling rate. So there has to be a difference in the meaning of the rate option in the UHD functions for TX and RX. Or am I missing something fundamental?

Best regards,

Felix

JL
Jeff Long
Wed, Feb 7, 2018 5:52 PM

Could you post the full command line you are typing? And describe the
output of the signal generator?

The sample rates should be the same, and one sample is I+Q.

On 02/07/2018 10:42 AM, Felix Langer via USRP-users wrote:

Hi everyone,

Since a few days, I started using the USRP B200 for transmitting and
receiving IQ-samples to and from a spectrum analyzer/signal generator.
For this purpose, I am using UHD's example functions
"rx_samples_to_file" and "tx_samples_from_file". To test the RX and TX
characteristics of the B200, I am generating sine-waves with specific
frequencies and write/read the IQ-samples of the wave to/from binary
data files.

I have noticed a difference in the effect of the sampling rate that I
can tune in the UHD-functions mentioned above:

If I send the IQ-samples to the signal generator with a specific
sampling rate (e.g. 20MHz) and use the B200 for RX, I need to tune the
sampling rate of the USRP to twice the sampling rate of the signal
generator (e.g. 40MS/s) for correct downconversion of the signal. So I
am assuming the sample rate for the USRP is defined as 1 sample for I
and 1 sample for Q, meaning 2 samples for 1IQ-value. Is this correct?
With this setting I see the peak of the FFT-plot of the received signal
at the frequency of the sine-wave that I generated (as expected).

However, for the counterpart of sending the IQ-data with the USRP (TX)
to a spectum analyzer, I need to tune the sampling rate of the USRP to
exactly the same sampling rate as for my analyzer (e.g. 20MHz at
analyzer, 20MS/s at USRP) to observe the correct FFT-plot. If I tune the
USRP sampling rate to 40MS/s (like above for RX) the peaks of my
FFT-plot are at twice the frequency of the sine-wave (I receive the wave
with twice the frequency).

So my question: Is the sampling rate of the UHD RX and TX functions
defined differently? I tried using only the signal generator and
spectrum analyzer for TX/RX and it works using the same sampling rate.
So there has to be a difference in the meaning of the rate option in the
UHD functions for TX and RX. Or am I missing something fundamental?

Best regards,

Felix


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

Could you post the full command line you are typing? And describe the output of the signal generator? The sample rates should be the same, and one sample is I+Q. On 02/07/2018 10:42 AM, Felix Langer via USRP-users wrote: > Hi everyone, > > > Since a few days, I started using the USRP B200 for transmitting and > receiving IQ-samples to and from a spectrum analyzer/signal generator. > For this purpose, I am using UHD's example functions > "rx_samples_to_file" and "tx_samples_from_file". To test the RX and TX > characteristics of the B200, I am generating sine-waves with specific > frequencies and write/read the IQ-samples of the wave to/from binary > data files. > > I have noticed a difference in the effect of the sampling rate that I > can tune in the UHD-functions mentioned above: > > If I send the IQ-samples to the signal generator with a specific > sampling rate (e.g. 20MHz) and use the B200 for RX, I need to tune the > sampling rate of the USRP to twice the sampling rate of the signal > generator (e.g. 40MS/s) for correct downconversion of the signal. So I > am assuming the sample rate for the USRP is defined as 1 sample for I > and 1 sample for Q, meaning 2 samples for 1IQ-value. Is this correct? > With this setting I see the peak of the FFT-plot of the received signal > at the frequency of the sine-wave that I generated (as expected). > > However, for the counterpart of sending the IQ-data with the USRP (TX) > to a spectum analyzer, I need to tune the sampling rate of the USRP to > exactly the same sampling rate as for my analyzer (e.g. 20MHz at > analyzer, 20MS/s at USRP) to observe the correct FFT-plot. If I tune the > USRP sampling rate to 40MS/s (like above for RX) the peaks of my > FFT-plot are at twice the frequency of the sine-wave (I receive the wave > with twice the frequency). > > So my question: Is the sampling rate of the UHD RX and TX functions > defined differently? I tried using only the signal generator and > spectrum analyzer for TX/RX and it works using the same sampling rate. > So there has to be a difference in the meaning of the rate option in the > UHD functions for TX and RX. Or am I missing something fundamental? > > > Best regards, > > Felix > > > > _______________________________________________ > USRP-users mailing list > USRP-users@lists.ettus.com > http://lists.ettus.com/mailman/listinfo/usrp-users_lists.ettus.com >