fix: Correct SSTV VIS codes and replace Goertzel pixel decoder with Hilbert transform

Fix wrong VIS codes for PD90 (96→99), PD120 (93→95), PD180 (95→97),
PD240 (113→96), and ScottieDX (55→76). This caused PD180 to be detected
as PD90 and PD120 to fail entirely.

Replace batch Goertzel pixel decoding with analytic signal (Hilbert
transform) FM demodulation. The Goertzel approach used 96-sample windows
with ~500 Hz resolution — wider than the 800 Hz pixel frequency range —
making accurate pixel decoding impossible for fast modes like Martin2
and Scottie2. The Hilbert method computes per-sample instantaneous
frequency, matching the approach used by QSSTV and other professional
SSTV decoders.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Smittix
2026-02-19 09:23:15 +00:00
parent d2ab2e404a
commit bf71f2a784
4 changed files with 55 additions and 50 deletions
+5 -5
View File
@@ -189,7 +189,7 @@ SCOTTIE_2 = SSTVMode(
PD_120 = SSTVMode(
name='PD120',
vis_code=93,
vis_code=95,
width=640,
height=496,
color_model=ColorModel.YCRCB_DUAL,
@@ -207,7 +207,7 @@ PD_120 = SSTVMode(
PD_180 = SSTVMode(
name='PD180',
vis_code=95,
vis_code=97,
width=640,
height=496,
color_model=ColorModel.YCRCB_DUAL,
@@ -225,7 +225,7 @@ PD_180 = SSTVMode(
PD_90 = SSTVMode(
name='PD90',
vis_code=96,
vis_code=99,
width=640,
height=496,
color_model=ColorModel.YCRCB_DUAL,
@@ -261,7 +261,7 @@ PD_160 = SSTVMode(
PD_240 = SSTVMode(
name='PD240',
vis_code=113,
vis_code=96,
width=640,
height=496,
color_model=ColorModel.YCRCB_DUAL,
@@ -283,7 +283,7 @@ PD_240 = SSTVMode(
SCOTTIE_DX = SSTVMode(
name='ScottieDX',
vis_code=55,
vis_code=76,
width=320,
height=256,
color_model=ColorModel.RGB,