Committing missing SSTV service changes.

This commit is contained in:
Marat Fayzullin 2023-03-01 19:22:32 -05:00
parent d751dee07e
commit c12a896fea
2 changed files with 11 additions and 7 deletions

View File

@ -114,16 +114,20 @@ class RttyDemodulator(SecondaryDemodulator, SecondarySelectorChain):
self.replace(2, RttyDecoder(sampleRate, 550, int(self.targetWidth), self.baudRate, self.reverse))
class SstvDemodulator(ServiceDemodulator):
class SstvDemodulator(ServiceDemodulator, DialFrequencyReceiver):
def __init__(self, service: bool = False):
self.parser = SstvParser(service=service)
self.sampleRate = 24000
workers = [
Agc(Format.COMPLEX_FLOAT),
SstvDecoder(self.sampleRate),
SstvParser(service=service)
self.parser
]
super().__init__(workers)
def getFixedAudioRate(self) -> int:
return self.sampleRate
def setDialFrequency(self, frequency: int) -> None:
self.parser.setDialFrequency(frequency)

View File

@ -218,11 +218,11 @@ class SstvParser(ThreadModule):
}
# Could not parse input data (yet)
if len(self.data)>1:
logger.debug("%s got %d bytes of data..." % (
("Service" if self.service else "Client"),
len(self.data)
))
# if len(self.data)>1:
# logger.debug("%s got %d bytes of data..." % (
# ("Service" if self.service else "Client"),
# len(self.data)
# ))
return None
except Exception as exptn: