Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X310 loopback frequency offset #1

Open
jmfriedt opened this issue Dec 30, 2022 · 2 comments
Open

X310 loopback frequency offset #1

jmfriedt opened this issue Dec 30, 2022 · 2 comments

Comments

@jmfriedt
Copy link
Member

jmfriedt commented Dec 30, 2022

The X310 clocked by the reference 10 MHz exhibits a -4.5 Hz frequency offset despite the transmitted signal (GPIO output) to be exactly at 70 MHz (checked against reference source). The offset must be introduced on the receiver side.

Frequency offset of the receiving DDC? Might not be unrealistic with https://github.com/EttusResearch/fpga/blob/UHD-3.15.LTS/usrp3/lib/dsp/ddc_chain.v#L33 since log2(200e6/4.5)=25.405 so a resolution of +/-4.5 Hz on a 25-bit CORDIC?

@jmfriedt
Copy link
Member Author

jmfriedt commented Jan 3, 2023

The X310 DDC has a finite frequency resolution that limits the accuracy as shown with

$ ./rx_samples_to_file --freq 70e6 --rate 5e6 --gain 20 --duration 10 usrp_samples.dat
[...]
Setting RX Freq: 70.000000000000 MHz...
Setting RX LO Offset: 0.000000000000 MHz...
Actual RX Freq: 70.000004768372 MHz...

The actual component source of the limitation remains to be identified, but at least the finite resolution is clearly documented by UHD.

@jmfriedt
Copy link
Member Author

jmfriedt commented Jan 3, 2023

25 bit accumulator on a 200 MHz NCO or 24 bit accumulator on a 100 MHz NCO [1]:
frequency tuning word is 70/200*2^25=11744051.2
rounding means the tuning word is either 11744051 or 11744052
(70-200*11744051/2^25)*1e6 = 1.19 Hz
(70-200*11744052/2^25)*1e6 = -4.76837158 Hz
is the correct answer so we understand the cause of the NCO error.

[1] https://github.com/EttusResearch/uhd/blob/master/fpga/usrp3/lib/ip/dds_sin_cos_lut_only/dds_sin_cos_lut_only.xci

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant