narrow bandpass specifically for wspr

This commit is contained in:
Jakob Ketterl 2019-09-15 12:23:11 +02:00
parent 711bd18d06
commit 7689d1a2e2
2 changed files with 13 additions and 1 deletions

View File

@ -2779,7 +2779,6 @@ function demodulator_digital_replace(subtype)
case "bpsk31": case "bpsk31":
case "rtty": case "rtty":
case "ft8": case "ft8":
case "wspr":
case "jt65": case "jt65":
case "jt9": case "jt9":
case "ft4": case "ft4":
@ -2787,6 +2786,15 @@ function demodulator_digital_replace(subtype)
demodulator_analog_replace('usb', true); demodulator_analog_replace('usb', true);
demodulator_buttons_update(); demodulator_buttons_update();
break; break;
case "wspr":
secondary_demod_start(subtype);
demodulator_analog_replace('usb', true);
// WSPR only samples between 1400 and 1600 Hz
demodulators[0].low_cut = 1350;
demodulators[0].high_cut = 1650;
demodulators[0].set();
demodulator_buttons_update();
break;
case "packet": case "packet":
secondary_demod_start(subtype); secondary_demod_start(subtype);
demodulator_analog_replace('nfm', true); demodulator_analog_replace('nfm', true);

View File

@ -180,6 +180,10 @@ class ServiceHandler(object):
if mode == "packet": if mode == "packet":
d.set_demodulator("nfm") d.set_demodulator("nfm")
d.set_bpf(-4000, 4000) d.set_bpf(-4000, 4000)
elif mode == "wspr":
d.set_demodulator("usb")
# WSPR only samples between 1400 and 1600 Hz
d.set_bpf(1350, 1650)
else: else:
d.set_demodulator("usb") d.set_demodulator("usb")
d.set_bpf(0, 3000) d.set_bpf(0, 3000)