How flexible is the sampling rate API value?

Add useful snippets of code or links to entire SDR projects.
AussieSusan
Posts: 5
Joined: Wed Aug 16, 2017 6:50 am

How flexible is the sampling rate API value?

Postby AussieSusan » Wed Oct 18, 2017 12:32 am

I'm writing a program that uses the RSP2 to capture weather satellite audio directly via the RSP API.
Using a 2MHz sampling frequency and a centre frequency of 137.5MHz, I can cover all 3 of the active NOAA satellite frequencies and decode them correctly down to audio. (I notice that 2 of the satellites are overhead at the same time occasionally and so I have different threads processing the raw samples for each satellite - each thread samples the appropriate offset from the centre frequency and then decimates and demodulates accordingly.)
This part is all working fine except that the (current) target audio sampling rate is a bit off from 48KHz (actually 47,619Hz).
To get WxToImg to input the audio files I need to resample the audio to get to 11025Hz. However with a 2MHz sampling frequency, the closest I can get reasonably is 10989Hz (2MHz/182 - 182 factors to 2, 7 and 17 which are reasonable decimation factors).
I was thinking that it might be possible to set a sampling frequency of 2,006,550Hz that would then decimate down to exactly the audio sampling rate I'm after (WxToImg is a bit fussy about the sampling rate).
Questions:
1) Is it acceptable to use a sampling rate such as this? I note that the API says it can be between 2MHz and 10MHz but all of the examples given seem to use rates such as 2MHz, 4MHz etc.
2) What side effects is using such a sampling rate likely to have? What other steps should I take to make this work?
Susan
Last edited by AussieSusan on Thu Jan 01, 1970 12:00 am, edited 0 times in total.
Reason: No reason

sdrplay
Posts: 603
Joined: Wed Jan 07, 2015 7:58 am

Re: How flexible is the sampling rate API value?

Postby sdrplay » Wed Oct 18, 2017 12:55 am

The sample rate can be an arbitrary value between 2 and 10MHz

I would be mindful of what IF bandwidth to use though. Signals outside of the IF bandwidth will be attenuated even if they are still within the sample rate you select. The sample rate should be greater or equal to the IF bandwidth you use.

Hope that helps,

Best regards,

SDRplay Support

Reason: No reason


Return to “Code Corner”

Who is online

Users browsing this forum: No registered users and 0 guests