pothosware / SoapyRTLSDR

SoapySDR RTL-SDR Support Module
https://github.com/pothosware/SoapyRTLSDR/wiki
MIT License
124 stars 29 forks source link

Fix E4000 gains #18

Closed cjcliffe closed 8 years ago

cjcliffe commented 8 years ago

From https://github.com/cjcliffe/CubicSDR/issues/169

Fix the gain settings for E4000 tuner.

static const int8_t if_stage1_gain[] = {
-3, 6
};

static const int8_t if_stage23_gain[] = {
0, 3, 6, 9
};

static const int8_t if_stage4_gain[] = {
0, 1, 2, 2
};

static const int8_t if_stage56_gain[] = {
3, 6, 9, 12, 15, 15, 15, 15
};

if_stage23_gain applies to stage 2 and 3, applies to stage 5 and 6

the numbers are dB
cjcliffe commented 8 years ago

Fix committed and tested here; appears to be working as expected but requires a related fix in CubicSDR still to use upper gain limits.