From 18dab4e0d300116a5f24f8fcc46cb9672a0cb8b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A1s=20Veres-Szentkir=C3=A1lyi?= Date: Tue, 2 Jul 2013 15:21:33 +0200 Subject: [PATCH] gen_values: initialize local variable 'sample' although in practice, this shouldn't happen -- I tried lowering the sample rate, and even at 10 samples/sec with Martin M1, it worked, and SSTV requires at least 4000 samples/sec (1 sample/sec raises an error though, if you'd like to try) --- pysstv/sstv.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pysstv/sstv.py b/pysstv/sstv.py index b4a676b..5f8d6f3 100644 --- a/pysstv/sstv.py +++ b/pysstv/sstv.py @@ -76,6 +76,7 @@ class SSTV(object): offset = 0 samples = 0 factor = 2 * pi / self.samples_per_sec + sample = 0 for freq, msec in self.gen_freq_bits(): samples += spms * msec tx = int(samples)