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

Wrong sample rate for RTL-SDR (R820T) #20

Closed
E3V3A opened this issue Jul 5, 2017 · 2 comments
Closed

Wrong sample rate for RTL-SDR (R820T) #20

E3V3A opened this issue Jul 5, 2017 · 2 comments

Comments

@E3V3A
Copy link

E3V3A commented Jul 5, 2017

Two problems here:

  1. Wrong sample rate. The RTL-SDR (820T2) max stable sample rate is: 2.4 MS/s (USB 2.0)
  2. There should be an app exit when provided with frequencies that are separated more than 2 MHz.
 # ./acarsdec -v -o 2 -p 1 -r 0 131.525 131.550 131.725 131.850 136.750 136.900

Found 1 device(s):
  0:  Realtek, RTL2838UHIDIR, SN: 00000001

Using device 0: Generic RTL2832U OEM
Found Rafael Micro R820T tuner
Tuner gain : 49.600000
Frequencies too far apart
Set center freq. to -1Hz
[R82XX] PLL not locked!
Exact sample rate is: 2500000.107620 Hz
[R82XX] PLL not locked!
Decoding 6 channels
@E3V3A
Copy link
Author

E3V3A commented Jul 23, 2017

To fix issue 1.

To get correct sample rates replace this:

#define RTLMULT 200
#define RTLINRATE (INTRATE*RTLMULT)

with:

//#define RTLMULT 200   // 2.5000 Ms/s
#define RTLMULT 192	// 2.4000 Ms/s
//#define RTLMULT 160	// 2.0000 Ms/s
//#define RTLMULT 144	// 1.8000 Ms/s
#define RTLINRATE (INTRATE*RTLMULT)

This seem especially important when running on Linux distro in a VM.
However, according to superkuh:

The highest safe sample rate is 2.56 MS/s but in some situations [usb3] up to 3.2 MS/s works
without USB dropping samples (RTL2832U drops them internally).

See this

@TLeconte TLeconte closed this as completed Aug 5, 2017
@TLeconte
Copy link
Owner

TLeconte commented Aug 5, 2017

ok will add theses comments in rtl.c and in README

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

2 participants