openwebrx/csdr/chain/demodulator.py

28 lines
486 B
Python
Raw Normal View History

2021-07-19 19:04:14 +02:00
from csdr.chain import Chain
2021-08-27 17:34:48 +02:00
from abc import ABC, abstractmethod
2021-07-19 19:04:14 +02:00
2021-08-23 14:25:28 +02:00
class BaseDemodulatorChain(Chain):
def getFixedIfSampleRate(self):
return None
2021-08-01 00:49:20 +02:00
2021-08-23 14:25:28 +02:00
def supportsSquelch(self):
return True
2021-08-27 17:34:48 +02:00
class FixedAudioRateChain(ABC):
@abstractmethod
def getFixedAudioRate(self):
pass
class FixedIfSampleRateChain(ABC):
@abstractmethod
def getFixedIfSampleRate(self):
return self.fixedIfSampleRate
# marker interface
class HdAudio:
pass