mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2026-06-13 19:29:08 -04:00
Minor tweaks and cleanup
- add functions to access SDRPostThread
This commit is contained in:
@@ -59,7 +59,7 @@ void DemodulatorThread::run() {
|
||||
nco_crcf_pll_set_bandwidth(stereoPilot, 0.25f);
|
||||
|
||||
// half band filter used for side-band elimination
|
||||
resamp2_cccf ssbFilt = resamp2_cccf_create(12,-0.25f,60.0f);
|
||||
resamp2_crcf ssbFilt = resamp2_crcf_create(12,-0.25f,60.0f);
|
||||
|
||||
// Automatic IQ gain
|
||||
iqAutoGain = agc_crcf_create();
|
||||
@@ -192,13 +192,13 @@ void DemodulatorThread::run() {
|
||||
switch (demodulatorType.load()) {
|
||||
case DEMOD_TYPE_LSB:
|
||||
for (int i = 0; i < bufSize; i++) { // Reject upper band
|
||||
resamp2_cccf_filter_execute(ssbFilt,(*inputData)[i],&x,&y);
|
||||
resamp2_crcf_filter_execute(ssbFilt,(*inputData)[i],&x,&y);
|
||||
ampmodem_demodulate(demodAM, x, &demodOutputData[i]);
|
||||
}
|
||||
break;
|
||||
case DEMOD_TYPE_USB:
|
||||
for (int i = 0; i < bufSize; i++) { // Reject lower band
|
||||
resamp2_cccf_filter_execute(ssbFilt,(*inputData)[i],&x,&y);
|
||||
resamp2_crcf_filter_execute(ssbFilt,(*inputData)[i],&x,&y);
|
||||
ampmodem_demodulate(demodAM, y, &demodOutputData[i]);
|
||||
}
|
||||
break;
|
||||
@@ -487,7 +487,7 @@ void DemodulatorThread::run() {
|
||||
firhilbf_destroy(firStereoR2C);
|
||||
firhilbf_destroy(firStereoC2R);
|
||||
nco_crcf_destroy(stereoPilot);
|
||||
resamp2_cccf_destroy(ssbFilt);
|
||||
resamp2_crcf_destroy(ssbFilt);
|
||||
|
||||
outputBuffers.purge();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user