1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2026-06-03 06:24:48 -04:00

Inf/Sup frequency shift scheme change to set bandwidth closer to device center frequency

This commit is contained in:
f4exb
2018-05-10 22:17:39 +02:00
parent 6a5a35285e
commit 4bb749ce65
11 changed files with 306 additions and 269 deletions
+7 -4
View File
@@ -56,11 +56,14 @@ This exercises the decimation chain.
<h4>2.3: Baseband center frequency position relative the center frequency</h4>
Possible values are:
- **Cen**: the decimation operation takes place around the center frequency Fs
- **Inf**: the decimation operation takes place around Fs - Fc.
- **Sup**: the decimation operation takes place around Fs + Fc.
With SR as the sample rate before decimation Fc is calculated as:
- **Cen**: the decimation operation takes place around the BladeRF Rx center frequency
- **Inf**: the decimation operation takes place around the center of the lower half of the BladeRF Rx passband.
- **Sup**: the decimation operation takes place around the center of the upper half of the BladeRF Rx passband.
- if decimation n is 4 or lower: Fc = SR/2^(log2(n)-1). The device center frequency is on the side of the baseband. You need a RF filter bandwidth at least twice the baseband.
- if decimation n is 8 or higher: Fc = SR/n. The device center frequency is half the baseband away from the side of the baseband. You need a RF filter bandwidth at least 3 times the baseband.
<h3>2.4: Sample size</h3>
@@ -274,11 +274,10 @@ bool TestSourceInput::applySettings(const TestSourceSettings& settings, bool for
if (settings.m_log2Decim != 0)
{
if (settings.m_fcPos == TestSourceSettings::FC_POS_INFRA) {
frequencyShift -= (devSampleRate / 4);
} else if (settings.m_fcPos == TestSourceSettings::FC_POS_SUPRA) {
frequencyShift += (devSampleRate / 4);
}
frequencyShift += DeviceSampleSource::calculateFrequencyShift(
settings.m_log2Decim,
(DeviceSampleSource::fcPos_t) settings.m_fcPos,
settings.m_sampleRate);
}
if (m_testSourceThread != 0)