From b706563a94123fd17c80de86167024965c8c854a Mon Sep 17 00:00:00 2001 From: Marat Fayzullin Date: Sat, 16 Dec 2023 21:53:09 -0500 Subject: [PATCH] Added option to show CW dits and dahs, reorganized settings page. --- CHANGELOG.md | 3 +++ csdr/chain/digimodes.py | 8 +++++--- debian/changelog | 3 +++ owrx/config/defaults.py | 3 ++- owrx/controllers/settings/decoding.py | 29 +++++++++++++++------------ owrx/dsp.py | 2 +- 6 files changed, 30 insertions(+), 18 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5f37505a..21c0c4a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ **1.2.43** - Added option to switch between US and EU RDS decoding. +- Added option to show dits and dahs when decoding CW. - Refactored and improved CW, SITOR-B, and CCIR476 decoders. +- Reorganized "Demodulation and Decoding Settings" page. +- Increased CW decoder bandwidth to 100Hz. - Fixed info bubble not updating in Google map. - Fixed resizing RDS display on mobile devices. - Fixed date/time parsing in RDS display. diff --git a/csdr/chain/digimodes.py b/csdr/chain/digimodes.py index 8249d4a0..e0ebcc1f 100644 --- a/csdr/chain/digimodes.py +++ b/csdr/chain/digimodes.py @@ -123,9 +123,11 @@ class RttyDemodulator(SecondaryDemodulator, SecondarySelectorChain): class CwDemodulator(SecondaryDemodulator, SecondarySelectorChain): - def __init__(self, baudRate: float, showCw: bool = False): + def __init__(self, bandWidth: float = 100): + pm = Config.get() self.sampleRate = 12000 - self.showCw = showCw + self.bandWidth = bandWidth + self.showCw = pm["cw_showcw"] workers = [ Agc(Format.COMPLEX_FLOAT), CwDecoder(self.sampleRate, self.showCw), @@ -133,7 +135,7 @@ class CwDemodulator(SecondaryDemodulator, SecondarySelectorChain): super().__init__(workers) def getBandwidth(self): - return 100 + return self.bandWidth def setSampleRate(self, sampleRate: int) -> None: if sampleRate == self.sampleRate: diff --git a/debian/changelog b/debian/changelog index 18585a05..ff8b80ce 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,7 +1,10 @@ openwebrx (1.2.43) bullseye jammy; urgency=low * Added option to switch between US and EU RDS decoding. + * Added option to show dits and dahs when decoding CW. * Refactored and improved CW, SITOR-B, and CCIR476 decoders. + * Reorganized "Demodulation and Decoding Settings" page. + * Increased CW decoder bandwidth to 100Hz. * Fixed info bubble not updating in Google map. * Fixed resizing RDS display on mobile devices. * Fixed date/time parsing in RDS display. diff --git a/owrx/config/defaults.py b/owrx/config/defaults.py index 87342786..a1a4a214 100644 --- a/owrx/config/defaults.py +++ b/owrx/config/defaults.py @@ -208,5 +208,6 @@ defaultConfig = PropertyLayer( fax_postprocess=True, fax_color=False, fax_am=False, - rds_usa=False + rds_usa=False, + cw_showcw=False ).readonly() diff --git a/owrx/controllers/settings/decoding.py b/owrx/controllers/settings/decoding.py index 6a43b59d..5fb94935 100644 --- a/owrx/controllers/settings/decoding.py +++ b/owrx/controllers/settings/decoding.py @@ -19,13 +19,19 @@ class DecodingSettingsController(SettingsFormController): def getSections(self): return [ Section( - "Demodulator settings", + "Miscellaneous", NumberInput( "squelch_auto_margin", "Auto-Squelch threshold", infotext="Offset to be added to the current signal level when using the auto-squelch", append="dB", ), + NumberInput( + "digimodes_fft_size", + "Secondary FFT size", + infotext="Secondary waterfall resolution in digital modes", + append="bins" + ), DropdownInput( "wfm_deemphasis_tau", "Tau setting for WFM (broadcast FM) deemphasis", @@ -37,6 +43,14 @@ class DecodingSettingsController(SettingsFormController): "rds_usa", "Decode USA-specific RDS information from WFM broadcasts", ), + CheckboxInput( + "paging_filter", + "Filter out empty, numeric, or unreadable pager messages", + ), + CheckboxInput( + "cw_showcw", + "Show CW codes (dits / dahs) when decoding CW", + ), ), Section( "Digital voice", @@ -58,17 +72,6 @@ class DecodingSettingsController(SettingsFormController): + "radioid database to show callsigns and names", ), ), - Section( - "Digimodes", - NumberInput("digimodes_fft_size", "Digimodes FFT size", append="bins"), - ), - Section( - "Pager messages", - CheckboxInput( - "paging_filter", - "Filter out empty, numeric, or unreadable pager messages", - ), - ), Section( "Aircraft messages", NumberInput( @@ -103,7 +106,7 @@ class DecodingSettingsController(SettingsFormController): CheckboxInput("fax_am", "Use amplitude modulation"), ), Section( - "Decoding settings", + "WSJT decoders", NumberInput("decoding_queue_workers", "Number of decoding workers"), NumberInput("decoding_queue_length", "Maximum length of decoding job queue"), NumberInput( diff --git a/owrx/dsp.py b/owrx/dsp.py index 56e47d0d..b4ba03d8 100644 --- a/owrx/dsp.py +++ b/owrx/dsp.py @@ -675,7 +675,7 @@ class DspManager(SdrSourceEventClient, ClientDemodulatorSecondaryDspEventClient) return DscDemodulator() elif mod == "cwdecoder": from csdr.chain.digimodes import CwDemodulator - return CwDemodulator(75.0) + return CwDemodulator(100.0) elif mod == "mfrtty170": from csdr.chain.digimodes import MFRttyDemodulator return MFRttyDemodulator(170.0, 45.45, reverse = False)